Bug 658428
| Summary: | [NetApp 6.1 bug] /etc/init.d/iscsi script does not start/stop as per state machine when root is on iSCSI LUN | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | gowrav <gowrav.mahadevaiah> |
| Component: | iscsi-initiator-utils | Assignee: | Andy Grover <agrover> |
| Status: | CLOSED ERRATA | QA Contact: | Storage QE <storage-qe> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 6.0 | CC: | coughlan, fge, mchristi, rpacheco, sarojkp1, xdl-redhat-bugzilla |
| Target Milestone: | rc | Keywords: | OtherQA |
| Target Release: | 6.1 | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: |
Starting or stopping the iSCSI service while accessing the root partition directly through an iSCSI disk could cause iSCSI to become unresponsive and incorrect status information to be reported. Attempting to stop the iSCSI service in this circumstance now warns that iSCSI cannot be shut down while Root is on an iSCSI disk, and all statuses are reported correctly.
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2011-05-19 14:14:53 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
Hi Mike, any updates on this bug? It's on my todo for 6.1. Kernel deadline is Fri, so after that I am going to on work on these type of bugs. All are known issues, so they should get fixed. Hey Gowrav, Do you have your setup handy? If so could you run iscsiadm -m node -T iqn.1992-08.com.netapp:sn.101180506 and attach the output? And you did the iscsi root installation through anaconda, right? You did not do a local install then manually setup iscsi root boot, right? Hi Mike, Yes, I installed the OS on iscsi root via anaconda. Below is the (In reply to comment #6) > Hey Gowrav, > > Do you have your setup handy? If so could you run > > iscsiadm -m node -T iqn.1992-08.com.netapp:sn.101180506 > > and attach the output? > > And you did the iscsi root installation through anaconda, right? You did not do > a local install then manually setup iscsi root boot, right? Hi Mike, Yes, I installed the OS on iscsi root via anaconda. Below is the output of the cmd you asked for. [root@IBMblade-200-202 ~]# iscsiadm -m node -T iqn.1992-08.com.netapp:sn.101180506 # BEGIN RECORD 2.0-87 node.name = iqn.1992-08.com.netapp:sn.101180506 node.tpgt = 1000 node.startup = automatic iface.hwaddress = <empty> iface.ipaddress = <empty> iface.iscsi_ifacename = default iface.net_ifacename = <empty> iface.transport_name = tcp iface.initiatorname = <empty> node.discovery_address = 10.72.201.36 node.discovery_port = 3260 node.discovery_type = send_targets node.session.initial_cmdsn = 0 node.session.initial_login_retry_max = 8 node.session.xmit_thread_priority = -20 node.session.cmds_max = 128 node.session.queue_depth = 32 node.session.auth.authmethod = None node.session.auth.username = <empty> node.session.auth.password = <empty> node.session.auth.username_in = <empty> node.session.auth.password_in = <empty> node.session.timeo.replacement_timeout = 120 node.session.err_timeo.abort_timeout = 15 node.session.err_timeo.lu_reset_timeout = 30 node.session.err_timeo.tgt_reset_timeout = 30 node.session.err_timeo.host_reset_timeout = 60 node.session.iscsi.FastAbort = Yes node.session.iscsi.InitialR2T = No node.session.iscsi.ImmediateData = Yes node.session.iscsi.FirstBurstLength = 262144 node.session.iscsi.MaxBurstLength = 16776192 node.session.iscsi.DefaultTime2Retain = 0 node.session.iscsi.DefaultTime2Wait = 2 node.session.iscsi.MaxConnections = 1 node.session.iscsi.MaxOutstandingR2T = 1 node.session.iscsi.ERL = 0 node.conn[0].address = 10.72.201.36 node.conn[0].port = 3260 node.conn[0].startup = automatic node.conn[0].tcp.window_size = 524288 node.conn[0].tcp.type_of_service = 0 node.conn[0].timeo.logout_timeout = 15 node.conn[0].timeo.login_timeout = 15 node.conn[0].timeo.auth_timeout = 45 node.conn[0].timeo.noop_out_interval = 5 node.conn[0].timeo.noop_out_timeout = 5 node.conn[0].iscsi.MaxXmitDataSegmentLength = 0 node.conn[0].iscsi.MaxRecvDataSegmentLength = 262144 node.conn[0].iscsi.HeaderDigest = None node.conn[0].iscsi.IFMarker = No node.conn[0].iscsi.OFMarker = No # END RECORD # BEGIN RECORD 2.0-872 node.name = iqn.1992-08.com.netapp:sn.101180506 node.tpgt = 1002 node.startup = automatic iface.hwaddress = <empty> iface.ipaddress = <empty> iface.iscsi_ifacename = default iface.net_ifacename = <empty> iface.transport_name = tcp iface.initiatorname = <empty> node.discovery_address = 10.72.201.36 node.discovery_port = 3260 node.discovery_type = send_targets node.session.initial_cmdsn = 0 node.session.initial_login_retry_max = 8 node.session.xmit_thread_priority = -20 node.session.cmds_max = 128 node.session.queue_depth = 32 node.session.auth.authmethod = None node.session.auth.username = <empty> node.session.auth.password = <empty> node.session.auth.username_in = <empty> node.session.auth.password_in = <empty> node.session.timeo.replacement_timeout = 120 node.session.err_timeo.abort_timeout = 15 node.session.err_timeo.lu_reset_timeout = 30 node.session.err_timeo.tgt_reset_timeout = 30 node.session.err_timeo.host_reset_timeout = 60 node.session.iscsi.FastAbort = Yes node.session.iscsi.InitialR2T = No node.session.iscsi.ImmediateData = Yes node.session.iscsi.FirstBurstLength = 262144 node.session.iscsi.MaxBurstLength = 16776192 node.session.iscsi.DefaultTime2Retain = 0 node.session.iscsi.DefaultTime2Wait = 2 node.session.iscsi.MaxConnections = 1 node.session.iscsi.MaxOutstandingR2T = 1 node.session.iscsi.ERL = 0 node.conn[0].address = 192.168.200.36 node.conn[0].port = 3260 node.conn[0].startup = automatic node.conn[0].tcp.window_size = 524288 node.conn[0].tcp.type_of_service = 0 node.conn[0].timeo.logout_timeout = 15 node.conn[0].timeo.login_timeout = 15 node.conn[0].timeo.auth_timeout = 45 node.conn[0].timeo.noop_out_interval = 5 node.conn[0].timeo.noop_out_timeout = 5 node.conn[0].iscsi.MaxXmitDataSegmentLength = 0 node.conn[0].iscsi.MaxRecvDataSegmentLength = 262144 node.conn[0].iscsi.HeaderDigest = None node.conn[0].iscsi.IFMarker = No node.conn[0].iscsi.OFMarker = No # END RECORD This is fixed in iscsi-initiator-utils-6.2.0.872-14.el6. You can download it here http://people.redhat.com/mchristi/iscsi/rhel6.1/iscsi-initiator-utils/ I verified the "iscsi-initiator-utils-6.2.0.872-14.el6.x86_64" rpm patch. All the options (restart, stop, start)are working as expected for "status" option.
1) If the root is on iSCSI multipth'd lun, the iscsi scripts provides correct output stating "Can not shutdown iSCSI. Root is on a iSCSI disk.". This works as expected.
2) When "/etc/init.d/iscsi status" option is used, instead of just giving one line status like -- "iscsid (pid ) is running..."; iscsi scripts is giving a verbose output on the state of all the iscsi sessions and interfaces. I believe such verbose o/p is not required.
[root@IBMblade-200-202 ~]# /etc/init.d/iscsi status
iSCSI Transport Class version 2.0-870
version 2.0-872
Target: iqn.1992-08.com.netapp:sn.101180506
Current Portal: 10.72.201.36:3260,1000
Persistent Portal: 10.72.201.36:3260,1000
**********
Interface:
**********
Iface Name: default
Iface Transport: tcp
Iface Initiatorname: iqn.1994-05.com.domain:lnx200.202
Iface IPaddress: 10.72.200.202
Iface HWaddress: <empty>
Iface Netdev: <empty>
SID: 1
iSCSI Connection State: LOGGED IN
iSCSI Session State: LOGGED_IN
Internal iscsid Session State: NO CHANGE
************************
Negotiated iSCSI params:
************************
HeaderDigest: None
DataDigest: None
MaxRecvDataSegmentLength: 262144
MaxXmitDataSegmentLength: 65536
FirstBurstLength: 65536
MaxBurstLength: 65536
ImmediateData: Yes
InitialR2T: No
MaxOutstandingR2T: 1
************************
Attached SCSI devices:
************************
Host Number: 3 State: running
scsi3 Channel 00 Id 0 Lun: 0
Attached scsi disk sdb State: running
scsi3 Channel 00 Id 0 Lun: 1
Attached scsi disk sdc State: running
scsi3 Channel 00 Id 0 Lun: 2
Attached scsi disk sdd State: running
scsi3 Channel 00 Id 0 Lun: 3
Attached scsi disk sde State: running
Current Portal: 192.168.200.36:3260,1002
Persistent Portal: 192.168.200.36:3260,1002
**********
Interface:
**********
Iface Name: default
Iface Transport: tcp
Iface Initiatorname: iqn.1994-05.com.domain:lnx200.202
Iface IPaddress: 192.168.200.202
Iface HWaddress: <empty>
Iface Netdev: <empty>
SID: 3
iSCSI Connection State: LOGGED IN
iSCSI Session State: LOGGED_IN
Internal iscsid Session State: NO CHANGE
************************
Negotiated iSCSI params:
************************
HeaderDigest: None
DataDigest: None
MaxRecvDataSegmentLength: 262144
MaxXmitDataSegmentLength: 65536
FirstBurstLength: 65536
MaxBurstLength: 65536
ImmediateData: Yes
InitialR2T: No
MaxOutstandingR2T: 1
************************
Attached SCSI devices:
************************
Host Number: 7 State: running
scsi7 Channel 00 Id 0 Lun: 0
Attached scsi disk sdf State: running
scsi7 Channel 00 Id 0 Lun: 1
Attached scsi disk sdg State: running
scsi7 Channel 00 Id 0 Lun: 2
Attached scsi disk sdh State: running
scsi7 Channel 00 Id 0 Lun: 3
Attached scsi disk sdi State: running
Target: iqn.1992-08.com.netapp:sn.101180456
Current Portal: 10.72.201.37:3260,1000
Persistent Portal: 10.72.201.37:3260,1000
**********
Interface:
**********
Iface Name: default
Iface Transport: tcp
Iface Initiatorname: iqn.1994-05.com.domain:lnx200.202
Iface IPaddress: 10.72.200.202
Iface HWaddress: <empty>
Iface Netdev: <empty>
SID: 2
iSCSI Connection State: LOGGED IN
iSCSI Session State: LOGGED_IN
Internal iscsid Session State: NO CHANGE
************************
Negotiated iSCSI params:
************************
HeaderDigest: None
DataDigest: None
MaxRecvDataSegmentLength: 262144
MaxXmitDataSegmentLength: 65536
FirstBurstLength: 65536
MaxBurstLength: 65536
ImmediateData: Yes
InitialR2T: No
MaxOutstandingR2T: 1
************************
Attached SCSI devices:
************************
Host Number: 6 State: running
Current Portal: 192.168.200.37:3260,1002
Persistent Portal: 192.168.200.37:3260,1002
**********
Interface:
**********
Iface Name: default
Iface Transport: tcp
Iface Initiatorname: iqn.1994-05.com.domain:lnx200.202
Iface IPaddress: 192.168.200.202
Iface HWaddress: <empty>
Iface Netdev: <empty>
SID: 4
iSCSI Connection State: LOGGED IN
iSCSI Session State: LOGGED_IN
Internal iscsid Session State: NO CHANGE
************************
Negotiated iSCSI params:
************************
HeaderDigest: None
DataDigest: None
MaxRecvDataSegmentLength: 262144
MaxXmitDataSegmentLength: 65536
FirstBurstLength: 65536
MaxBurstLength: 65536
ImmediateData: Yes
InitialR2T: No
MaxOutstandingR2T: 1
************************
Attached SCSI devices:
************************
Host Number: 8 State: running
The "/etc/init.d/iscsi status" output mentioned in Comment 10, can be manually got by executing the command "iscsiadm -m session -P 3". I'm not sure if the "status" output is designed to print verbose output about iscsi session. Can the output be just reduced to print a single line stating if the iscsi daemon is running or stopped (as done in RHEL 5 series)? (In reply to comment #11) > The "/etc/init.d/iscsi status" output mentioned in Comment 10, can be manually > got by executing the command "iscsiadm -m session -P 3". > > I'm not sure if the "status" output is designed to print verbose output about > iscsi session. Can the output be just reduced to print a single line stating if > the iscsi daemon is running or stopped (as done in RHEL 5 series)? No. I guess more people wanted the verbose info. If you wanted to know about iscsid status you can do service iscsid status. >
> No. I guess more people wanted the verbose info.
>
> If you wanted to know about iscsid status you can do
>
> service iscsid status.
Then, in that case we can close this bug as fixed.
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
New Contents:
Starting or stopping the iSCSI service while accessing the root partition directly through an iSCSI disk could cause iSCSI to become unresponsive and incorrect status information to be reported. Attempting to stop the iSCSI service in this circumstance now warns that iSCSI cannot be shut down while Root is on an iSCSI disk, and all statuses are reported correctly.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2011-0733.html After successful installation of iscsi-initiator-utils package in Red Hat Enterprise 6.0, the service is not started. I could not start the service in manually also. Could please guide "What is the issues?". I have tried below method for starting iscsi service.
1). service iscsi restart/start/reload
service iscsid restart/start/reload
2). service iscsi force-start
service iscsid force-start
3). chkconfig iscsi on
chkconfig iscsid on
But still I could not start the service. Could you please replay?
|
Description of problem: In RHEL 6 GA OS, the /etc/init.d/iscsi script does not start/stop/restart as expected. The OS root is installed on iSCSI multipathed LUN, and all the iSCSI session have been configured to start "on boot". Below are different scenarios. 1) After boot, all the iSCSI sessions are established and the all LUNs are visible. But when we check for iscsi status, it shows as 'stopped'. Whereas it should have started during boot time. # iscsiadm -m session tcp: [1] 10.72.201.36:3260,1000 iqn.1992-08.com.netapp:sn.101180506 tcp: [2] 10.72.201.37:3260,1000 iqn.1992-08.com.netapp:sn.101180456 tcp: [3] 192.168.200.37:3260,1002 iqn.1992-08.com.netapp:sn.101180456 tcp: [4] 192.168.200.36:3260,1002 iqn.1992-08.com.netapp:sn.101180506 # /etc/init.d/iscsi status iscsi is stopped 2) When I try to "start" the iscsi scripts, it fails to start due to a check condition in the script. # /etc/init.d/iscsi start Starting iscsi: iscsiadm: Could not login to [iface: default, target: iqn.1992-08.com.netapp:sn.101180456, portal: 10.72.201.37,3260]. iscsiadm: initiator reported error (15 - already exists) iscsiadm: Could not login to [iface: default, target: iqn.1992-08.com.netapp:sn.101180456, portal: 192.168.200.37,3260]. iscsiadm: initiator reported error (15 - already exists) iscsiadm: Could not login to [iface: default, target: iqn.1992-08.com.netapp:sn.101180506, portal: 10.72.201.36,3260]. iscsiadm: initiator reported error (15 - already exists) iscsiadm: Could not login to [iface: default, target: iqn.1992-08.com.netapp:sn.101180506, portal: 192.168.200.36,3260]. iscsiadm: initiator reported error (15 - already exists) [FAILED] iscsi is not starting since the check condition fails in the following lines. Seems like PIPESTATUS[0] is not returning correct status. if [ ${PIPESTATUS[0]} -ne 0 -o ${PIPESTATUS[1]} -eq 0 ]; then failure $"Starting $prog" echo return 1 fi Ideally, "iscsi" should start at boot time when all session are established and especially root is on a iSCSI LUN. If its not started on boot time, iscsi should atleast start when it's started manually. This scenario is observed to work fine in RHEL 5 series. 3) If I try to 'restart' the "/etc/init.d/iscsi" script (after trying step-2), the host stops responding and i'm unable to execute any command thereafter. Here my root is on a iSCSI LUN. # /etc/init.d/iscsi restart Stopping iscsi: /etc/init.d/iscsi: line 80: rm: command not found Message from syslogd@IBMblade-200-202 at Nov 29 17:21:01 ... kernel:journal commit I/O error # clear -bash: /usr/bin/clear: No such file or directory 4) When I try to 'stop' the iscsi scripts when the root is on a iSCSI LUN, it's observed that iSCSI daemon stops by logging off all the iscsi sessions and host hangs. Ideally, the iSCSI daemon should NOT stop giving a message that "Root is on a iSCSI LUN and iSCSI cannot be stopped". But there is no such check condition in "/etc/init.d/iscsi" script. Such a check condition is present in RHEL 5 series. Version-Release number of selected component (if applicable): Kernel: 2.6.32-71.el6.x86_64 iSCSI: iscsi-initiator-utils-6.2.0.872-10.el6.x86_64 Device Mapper: device-mapper-1.02.53-8.el6.x86_64 Multipath: device-mapper-multipath-0.4.9-31.el6.x86_64 How reproducible: Always Steps to Reproduce: 1. Install RHEL 6.0 OS with root on a iSCSI multipathed LUN. 2. Configure all the iSCSI session to start with "on boot". 3. Reboot the host and check if all the iSCSI sessions have been established (iscsiadm -m session). 4. Make sure that /etc/init.d/iscsid daemon is running. 4. Run /etc/init.d/iscsi script with various options -- status, start, restart, stop. Actual results: When root is installed on iSCSI multipathed LUN, after the host reboot we see that all the iscsi sessions are established, but the iscsi status is show as "iscsi is stopped". When we try to start it manually, iscsi fails to start. When we try to stop/restart, all the iscsi sessions are logged off and host hangs. Expected results: When the OS is installed on iSCSI multipathed LUN, the iscsi script should start automatically at boot time and the status should be "running". And, when the iscsi is attempted to stop, there should be a message displayed that "iSCSI cannot be stopped since root is on iSCSI LUN", and iscsi sessions should be logged off, i.e., daemon should not be stopped. Additional info: