On 2017-06-19 09:47, Fabian Grünbichler wrote:

I was thinking more about logical races, along the lines of the

- no existing session
- activate volume A
A- get_active_luns (note: this will already create an empty session)
A- freenas_get_lun_number
- concurrent activate volume B
B- get_active_luns (this will reuse session, but there are no active
LUNs at the moment)
A- get_sid
A- os_request to iscsiadm
A- sleep 1 (or udevadm ...)
B- get_sid
A- deactivate_luns (but with info from before B was activated)
B- os_request to iscisadm
B- sleep 1 (or udevadm ...)
B- deactivate_luns (but with info from before A was activated)

so now only B is activated, but no error was returned. or am I missing
something? (note that this was just the first that came to my mind, and
the whole code is very side-effecty, so I am pretty sure there are other
similar interactions)

You might have a point here. I will investigate further.

Michael Rasmussen

Get my public GnuPG keys:
michael <at> rasmussen <dot> cc
mir <at> datanom <dot> net
mir <at> miras <dot> org


This mail was virus scanned and spam checked before delivery.
This mail is also DKIM signed. See header dkim-signature.

pve-devel mailing list

Reply via email to