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


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

- 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.

--
Hilsen/Regards
Michael Rasmussen

Get my public GnuPG keys:
michael <at> rasmussen <dot> cc
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xD3C9A00E
mir <at> datanom <dot> net
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xE501F51C
mir <at> miras <dot> org
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xE3E80917
--------------------------------------------------------------

----

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

_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to