--
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-iscsi+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-iscsi/cc3ad021-753a-4ac4-9e6f-93e8da1e19bbn%40googlegroups.com.
Hello, Assuming that devmapper is running and MPIO properly configured you want to connect to the same volume/target from different interfaces.ÂHowever in your case you aren't specifying the same interface. "default" but they are on the same subnet. Which typically will only use the default NIC for that subnet.Â
What iSCSI target are you using? Â Regards,Don
On Tue, Jun 30, 2020 at 9:00 AM Amit Bawer <aba...@redhat.com> wrote:
[Sorry if this message is duplicated, haven't seen it is published in the group]
--Hi,Have couple of question regarding iscsiadm version 6.2.0.878-2:1) Is it safe to have concurrent logins to the same target from different interfaces?That is, running the following commands in parallel:iscsiadm -m node -T iqn.2003-01.org.vm-18-198.iqn2 -I default -p 10.35.18.121:3260,1 -liscsiadm -m node -T iqn.2003-01.org.vm-18-198.iqn2 -I default -p 10.35.18.166:3260,1 -l2) Is there a particular reason for the default values of node.conn[0].timeo.login_timeout and node.session.initial_login_retry_max?According to comment in iscsid.conf it would spend 120 seconds in case of an unreachable interface login:# The default node.session.initial_login_retry_max is 8 and
# node.conn[0].timeo.login_timeout is 15 so we have:
#
# node.conn[0].timeo.login_timeout * node.session.initial_login_retry_max =
# Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â 120 secondsThanks,Amit
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-iscsi+unsubscribe@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to open-iscsi+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-iscsi/cc3ad021-753a-4ac4-9e6f-93e8da1e19bbn%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-iscsi+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-iscsi/bf75d5e8-f4ed-4a16-86a8-ab78d0cac1cco%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to open-iscsi+...@googlegroups.com.
Another point i'd like to ask about is iSER fallback that we have:Currently we check during connection flow if 'iser' is set on iscsi_default_ifaces in our configuration.If yes, it is first checked if its working on server side by attemptingiscsiadm -m node -T target -I iser -p portal -liscsiadm -m node -T target -I iser -p portal -uIf the login/logout worked it is kept as 'iser' instead of 'default' interface setup, otherwise it fallbacks to 'default'.This is used later for the actual node login.The thing is that this check can also waste valuable time when the portal is down, is there a way to fallback in the iscsiadm command itself, or prefer a specific interface type when trying all/parallel logins for same target+portal but with different interfaces types?
Thank you for your answers,The motivation behind the original question is for reducing the waiting time for different iscsi connections loginsin case some of the portals are down.
We have a limitation on our RHEV system where all logins to listed iscsi targets should finish within 180 seconds in total.In our current implementation we serialize the iscsiadm node logins one after the other,each is for specific target and portal. In such scheme, each login would wait 120 seconds in case a portal is down(default 15 seconds login timeout * 8 login retries), so if we have 2 or more connections down, we spend at least 240 secondswhich exceeds our 180 seconds time limit and the entire operation is considered to be failed (RHEV-wise).
Testing [1] different login schemes is summarized in the following table (logins to 2 targets with 2 portals each).It seems that either login-all nodes after creating them, as suggested in previous answer here, compares in total time spentwith doing specific node logins concurrently (i.e. running iscsiadm -m node -T target -p portal -I interface -l in parallel pereach target-portal), for both cases of all portals being online and when one portal is down:Login scheme                        Online Portals            Active Sessions      Total Login Time (seconds)
---------------------------------------------------------------------------------------------------------------------------------------------------------
   All at once                           2/2                                4                              2.1
   All at once                       1/2                    2                              120.2
   Serial target-portal             2/2                               4                               8.5
   Serial target-portal             1/2                               2                               243.5
   Concurrent target-portal    2/2                              4                               2.1
   Concurrent target-portal   1/2                               2                              120.1
Using concurrent target-portal logins seems to be preferable in our perspective as it allows to connect only to thespecified target and portals without the risk of intermixing with other potential iscsi targets.
The node creation part is kept serial in all tests here and we have seen it may result in the iscsi DB issues if run in parallel.But using only node logins in parallel doesn't seems to have issues for at least 1000 tries of out tests.
The question to be asked here is it advisable by open-iscsi?I know I have been answered already that iscsiadm is racy, but does it applies to node logins as well?
The other option is to use one login-all call without parallelism, but that would have other implications on our system to consider.
Your answers would be helpful once again.
Thanks,
- Amit
On Monday, July 27, 2020 at 10:38:05 AM UTC-7, Amit Bawer wrote:Thank you for your answers,The motivation behind the original question is for reducing the waiting time for different iscsi connections loginsin case some of the portals are down.
We have a limitation on our RHEV system where all logins to listed iscsi targets should finish within 180 seconds in total.In our current implementation we serialize the iscsiadm node logins one after the other,each is for specific target and portal. In such scheme, each login would wait 120 seconds in case a portal is down(default 15 seconds login timeout * 8 login retries), so if we have 2 or more connections down, we spend at least 240 secondswhich exceeds our 180 seconds time limit and the entire operation is considered to be failed (RHEV-wise).Of course these times are tunable, as the README distributed with open-iscsi suggests. But each setting has a trade-off. For example, if you shorten the timeout, you may miss connecting to a target that is just temporarily unreachable.Testing [1] different login schemes is summarized in the following table (logins to 2 targets with 2 portals each).It seems that either login-all nodes after creating them, as suggested in previous answer here, compares in total time spentwith doing specific node logins concurrently (i.e. running iscsiadm -m node -T target -p portal -I interface -l in parallel pereach target-portal), for both cases of all portals being online and when one portal is down:Login scheme                        Online Portals            Active Sessions      Total Login Time (seconds)
---------------------------------------------------------------------------------------------------------------------------------------------------------
   All at once                           2/2                                4                              2.1
   All at once                       1/2                    2                              120.2
   Serial target-portal             2/2                               4                               8.5
   Serial target-portal             1/2                               2                               243.5
   Concurrent target-portal    2/2                              4                               2.1
   Concurrent target-portal   1/2                               2                              120.1So it looks like "All at once" is as fast as concurrent? I must be missing something. Maybe I'm misunderstanding what "all at once" means?
Using concurrent target-portal logins seems to be preferable in our perspective as it allows to connect only to thespecified target and portals without the risk of intermixing with other potential iscsi targets.Okay, maybe that explains it. You don't trust the "all" option? You are, after all, in charge of the node database. But of course that's your choice.
The node creation part is kept serial in all tests here and we have seen it may result in the iscsi DB issues if run in parallel.But using only node logins in parallel doesn't seems to have issues for at least 1000 tries of out tests.In general the heavy lifting here is done by the kernel, which has proper multi-thread locking. And I believe iscsiadm has a single lock to the kernel communication socket, so that doesn't get messed up. So I wouldn't go as far as guaranteeing that this will work, but I agree it certainly seems to reliably work.The question to be asked here is it advisable by open-iscsi?I know I have been answered already that iscsiadm is racy, but does it applies to node logins as well?I guess I answered that. I wouldn't advise against it, but I also wouldn't call best practice in general.The other option is to use one login-all call without parallelism, but that would have other implications on our system to consider.Such as?
Your answers would be helpful once again.
Thanks,
- AmitYou might be interested in a new feature I'm considering adding to iscsiadm to do asynchronous logins. In other words, the iscsiadm could, when asked to login to one or more targets, would send the login request to the targets, then return success immediately. It is then up to the end-user (you in this case) to poll for when the target actually shows up.
...
The other option is to use one login-all call without parallelism, but that would have other implications on our system to consider.Such as?As mentioned above, unless there is a way to specify a list of targets and portals for a single login (all) command.
Your answers would be helpful once again.
Thanks,
- AmitYou might be interested in a new feature I'm considering adding to iscsiadm to do asynchronous logins. In other words, the iscsiadm could, when asked to login to one or more targets, would send the login request to the targets, then return success immediately. It is then up to the end-user (you in this case) to poll for when the target actually shows up.This sounds very interesting, but probably will be available to us only on later RHEL releases, if chosen to be delivered downstream.At present it seems we can only use the login-all way or logins in a dedicated threads per target-portal.
...
On Sunday, August 9, 2020 at 11:08:50 AM UTC-7, Amit Bawer wrote:...The other option is to use one login-all call without parallelism, but that would have other implications on our system to consider.Such as?As mentioned above, unless there is a way to specify a list of targets and portals for a single login (all) command.
Your answers would be helpful once again.
Thanks,
- AmitYou might be interested in a new feature I'm considering adding to iscsiadm to do asynchronous logins. In other words, the iscsiadm could, when asked to login to one or more targets, would send the login request to the targets, then return success immediately. It is then up to the end-user (you in this case) to poll for when the target actually shows up.This sounds very interesting, but probably will be available to us only on later RHEL releases, if chosen to be delivered downstream.At present it seems we can only use the login-all way or logins in a dedicated threads per target-portal....So you can only use RH-released packages?
That's fine with me, but I'm asking you to test a new feature and see if it fixes your problems. If it helped, I would add up here in this repo, and redhat would get it by default when they updated, which they do regularly, as does my company (SUSE).
Just as a "side" point, I wouldn't attack your problem by manually listing nodes to login to.It does seem as if you assume you are the only iscsi user on the system. In that case, you have complete control of the node database. Assuming your targets do not change, you can set up your node database once and never have to discover iscsi targets again. Of course if targets change, you can update your node database, but only as needed, i.e. full discovery shouldn't be needed each time you start up, unless targets are really changing all the time in your environment.
If you do discovery and have nodes in your node database you don't like, just remove them.
Another point about your scheme: you are setting each node's 'startup' to 'manual', but manual is the default, and since you seem to own the open-iscsi code on this system, you can ensure the default is manual. Perhaps because this is a test?
So, again, I ask you if you will test the async login code? It's really not much extra work -- just a "git clone" and a "make install" (mostly). If not, the async feature may make it into iscsiadm any way, some time soon, but I'd really prefer other testers for this feature before that.
I believe the best way to check for the async session to complete is to look for results. Does a new disc show up? That sort of high-level algorithm will be the best, because it waits for what you actually care about.If you'd like to wait until iscsiadm says the session is complete, that seems like it'd be possible to, but be advised there is a finite amount of time between when (1) the session connects, (2) iscsiadm will show the session as valid, and (3) when udev and friends in the operating system instantiate the disc.
By the way, how are you simulating one target is down? Just curious.
Lastly, yes, I could add code to iscsiadm to make "iscsiadm -m node -T <iqn> ... --login --no_wait" work. Would you be willing to test it (in a branch) if I did?