Re: [PATCH] change iscsi discovery on suse's initd
Hannes Reinecke wrote: Eli Dorfman wrote: Hi Amir, Mike Christie wrote: Amir Mehler wrote: Amir Mehler wrote: Hello, On open-iscsi, from April 2008 and on, when performing: (on suse) /etc/init.d/open-iscsi start a discovery is done in line 126: iscsiadm -m discovery -t st -p $TARGET_ADDR /dev/null 21 This line, and others, were added by Hannes Reinecke on Apr 09 2008. The problem with this discovery is that it modifies old session parameters of the nodes. Yes, it does with the stock open-iscsi distribution. For SUSE I've added a patch to change the default. Why do we have to run discovery on every open-iscsi start? Discovery process should be initiated by the user on demand. Because. This is (was?) required for static IP addresses, as some switches might take quite some time to update their internal routing tables, during which time any connect() attempt will return -EHOSTUNREACH. And as the kernel code does has no concept of an initial connection establishment it will fail the connection. The kernel does not need this concept. Userspace knows this. You can set: node.session.initial_login_retry_max = X to a higher value to retry all errors X times. I said I can even add in a check for -EHOSTUNREACH where we retry this forever so users do not have to set the above setting. I was not sure if it makes sense to always retry that error for the initial login. It seems like there are cases where we can get that error code and the network is really not going to come back so we may not want to retry forever so maybe settting node.session.initial_login_retry_max high is best. Or if there was a way we could put the init script startup/login in the background after X seconds we could continually retry all errors and not disrupt the startup processs - I do not know how to do that though. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups open-iscsi group. To post to this group, send email to open-iscsi@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/open-iscsi -~--~~~~--~~--~--~---
Re: [PATCH] change iscsi discovery on suse's initd
Eli Dorfman wrote: Hi Amir, Mike Christie wrote: Amir Mehler wrote: Amir Mehler wrote: Hello, On open-iscsi, from April 2008 and on, when performing: (on suse) /etc/init.d/open-iscsi start a discovery is done in line 126: iscsiadm -m discovery -t st -p $TARGET_ADDR /dev/null 21 This line, and others, were added by Hannes Reinecke on Apr 09 2008. The problem with this discovery is that it modifies old session parameters of the nodes. Yes, it does with the stock open-iscsi distribution. For SUSE I've added a patch to change the default. Why do we have to run discovery on every open-iscsi start? Discovery process should be initiated by the user on demand. Because. This is (was?) required for static IP addresses, as some switches might take quite some time to update their internal routing tables, during which time any connect() attempt will return -EHOSTUNREACH. And as the kernel code does has no concept of an initial connection establishment it will fail the connection. So we're doing a discovery first to setup the connection, thus ensuring that the kernel will be able to log into the server properly. Cheers, Hannes -- Dr. Hannes Reinecke zSeries Storage [EMAIL PROTECTED] +49 911 74053 688 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Markus Rex, HRB 16746 (AG Nürnberg) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups open-iscsi group. To post to this group, send email to open-iscsi@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/open-iscsi -~--~~~~--~~--~--~---
Re: [PATCH] change iscsi discovery on suse's initd
Hi Amir, Mike Christie wrote: Amir Mehler wrote: Amir Mehler wrote: Hello, On open-iscsi, from April 2008 and on, when performing: (on suse) /etc/init.d/open-iscsi start a discovery is done in line 126: iscsiadm -m discovery -t st -p $TARGET_ADDR /dev/null 21 This line, and others, were added by Hannes Reinecke on Apr 09 2008. The problem with this discovery is that it modifies old session parameters of the nodes. Yes, it does with the stock open-iscsi distribution. For SUSE I've added a patch to change the default. Why do we have to run discovery on every open-iscsi start? Discovery process should be initiated by the user on demand. Eli. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups open-iscsi group. To post to this group, send email to open-iscsi@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/open-iscsi -~--~~~~--~~--~--~---
Re: [PATCH] change iscsi discovery on suse's initd
Hi Amir, Mike Christie wrote: Amir Mehler wrote: Amir Mehler wrote: Hello, On open-iscsi, from April 2008 and on, when performing: (on suse) /etc/init.d/open-iscsi start a discovery is done in line 126: iscsiadm -m discovery -t st -p $TARGET_ADDR /dev/null 21 This line, and others, were added by Hannes Reinecke on Apr 09 2008. The problem with this discovery is that it modifies old session parameters of the nodes. Yes, it does with the stock open-iscsi distribution. For SUSE I've added a patch to change the default. two important session parameters change: iface.transport_name = tcp (was iser after first discovery) node.conn[0].startup = manual (was automatic after first discovery) I do not understand why Hannes used exactly this kind of discovery. when I replaced the original line with this one it solved the problem I had: iscsi_discovery $TARGET_ADDR /dev/null 21 does this change harm the original purpose of the discovery? No. But I'm not sure if we're distributing the iscsi_discovery script per default. If we do then this should indeed be a valid alternative. if it does please explain, otherwise I would like to suggest the patch below. (maybe we can add something to the iscsi_discovery script to make up for it?) Thank you, Amir. The suse init.d file runs discovery via iscsiadm. This causes changes in existing iscsi node parameters. Using iscsi_discovery solves this problem. Mike, if you can take a look, I would to hear your opinion about this. Thanks, Amir. I do not really touch Hannes script unless I am updating it. I am not even sure if suse distributes iscsi_discovery? I ccd Hannes so he could make the call. However, if you do not want to overwrite existing records you can do iscsiadm -m discovery -t st -p ip:port [-o new | -o delete | -o update ] You can actually pass in multiple operations so if you wanted to just add and delete nodes you can do iscsiadm -m discovery -t st -p ip:port -o new -o delete existing records will not get changed. Yes, I noticed. I've actually added a patch to the SUSE rpm to make this the default. Backwards compability again; some folk complained that calling 'iscsiadm ' (ie without any '-o' option) did indeed overwrite existing nodes, which it didn't do on previous versions. So I've had to add a patch to make this the default. Ah, sometimes you really love backwards compability ... Cheers, Hannes -- Dr. Hannes Reinecke zSeries Storage [EMAIL PROTECTED] +49 911 74053 688 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Markus Rex, HRB 16746 (AG Nürnberg) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups open-iscsi group. To post to this group, send email to open-iscsi@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/open-iscsi -~--~~~~--~~--~--~---
Re: [PATCH] change iscsi discovery on suse's initd
Amir Mehler wrote: Amir Mehler wrote: Hello, On open-iscsi, from April 2008 and on, when performing: (on suse) /etc/init.d/open-iscsi start a discovery is done in line 126: iscsiadm -m discovery -t st -p $TARGET_ADDR /dev/null 21 This line, and others, were added by Hannes Reinecke on Apr 09 2008. The problem with this discovery is that it modifies old session parameters of the nodes. two important session parameters change: iface.transport_name = tcp (was iser after first discovery) node.conn[0].startup = manual (was automatic after first discovery) I do not understand why Hannes used exactly this kind of discovery. when I replaced the original line with this one it solved the problem I had: iscsi_discovery $TARGET_ADDR /dev/null 21 does this change harm the original purpose of the discovery? if it does please explain, otherwise I would like to suggest the patch below. (maybe we can add something to the iscsi_discovery script to make up for it?) Thank you, Amir. The suse init.d file runs discovery via iscsiadm. This causes changes in existing iscsi node parameters. Using iscsi_discovery solves this problem. Mike, if you can take a look, I would to hear your opinion about this. Thanks, Amir. I do not really touch Hannes script unless I am updating it. I am not even sure if suse distributes iscsi_discovery? I ccd Hannes so he could make the call. However, if you do not want to overwrite existing records you can do iscsiadm -m discovery -t st -p ip:port [-o new | -o delete | -o update ] You can actually pass in multiple operations so if you wanted to just add and delete nodes you can do iscsiadm -m discovery -t st -p ip:port -o new -o delete existing records will not get changed. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups open-iscsi group. To post to this group, send email to open-iscsi@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/open-iscsi -~--~~~~--~~--~--~---