Bug 169129 - remove tape during error handling -> "illegal state transition"
Summary: remove tape during error handling -> "illegal state transition"
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: kernel
Version: 4.0
Hardware: i686
OS: Linux
medium
low
Target Milestone: rc
: ---
Assignee: Doug Ledford
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks: RHEL4u8_relnotes
TreeView+ depends on / blocked
 
Reported: 2005-09-23 14:05 UTC by nate.dailey
Modified: 2014-06-10 14:50 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-05-18 19:28:52 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2009:1024 0 normal SHIPPED_LIVE Important: Red Hat Enterprise Linux 4.8 kernel security and bug fix update 2009-05-18 14:57:26 UTC

Description nate.dailey 2005-09-23 14:05:05 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.6) Gecko/20050317 Firefox/1.0.2

Description of problem:
I hit this problem running with the modified scsi tape driver from bug #169083.

I pulled the cable to a tape drive with IOs in progress. After scsi error handling kicked in (but before it had completed), I removed the tape drive via "echo scsi remove-single-device ... > /proc/scsi/scsi". When error handling completed, I saw:

"Illegal state transition deleted->offline"

There were no ill effects... just the scary message. Waiting until error handling completed before removing the tape did not result in the message appearing.

Although I hit this with tape, I don't see why it couldn't have happened with another device type.

It looks like this is really just a logging verbosity issue... a similar problem was reported on the linux-scsi mailing list & a fix was provided:

http://marc.theaimsgroup.com/?l=linux-scsi&m=110274055510387&w=2

Here's a patch against RHEL4 U2:

--- scsi_lib.c.orig     2005-09-22 16:53:50.000000000 -0400
+++ scsi_lib.c  2005-09-22 16:56:35.000000000 -0400
@@ -1698,11 +1698,12 @@ scsi_device_set_state(struct scsi_device
        return 0;

  illegal:
-       dev_printk(KERN_ERR, &sdev->sdev_gendev,
-                  "Illegal state transition %s->%s\n",
-                  scsi_device_state_name(oldstate),
-                  scsi_device_state_name(state));
-       WARN_ON(1);
+       SCSI_LOG_ERROR_RECOVERY(1,
+                               dev_printk(KERN_ERR, &sdev->sdev_gendev,
+                                          "Illegal state transition %s->%s\n",
+                                          scsi_device_state_name(oldstate),
+                                          scsi_device_state_name(state))
+                               );
        return -EINVAL;
 }
 EXPORT_SYMBOL(scsi_device_set_state);



Version-Release number of selected component (if applicable):
kernel-smp-2.6.9-17.EL

How reproducible:
Sometimes

Steps to Reproduce:
1. Use the modified tape driver from bug #169083... otherwise other problems will probably show up before this one does
2. Start up IO to a tape drive
3. Pull the cable to the drive
4. When SCSI error handling kicks in, remove the tape via remove-single-device

Actual Results:  /var/log/messages shows "Illegal state transition deleted->offline" for the device

Expected Results:  The message isn't important, so it should be hidden

Additional info:

Comment 1 RHEL Program Management 2008-10-02 20:06:46 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 2 Vivek Goyal 2008-10-21 19:07:52 UTC
Committed in 78.15.EL . RPMS are available at http://people.redhat.com/vgoyal/rhel4/

Comment 6 Chris Ward 2009-03-27 14:18:12 UTC
~~ Attention Partners! Snap 1 Released ~~
RHEL 4.8 Snapshot 1 has been released on partners.redhat.com. There should
be a fix present, which addresses this bug. NOTE: there is only a short time
left to test, please test and report back results on this bug
at your earliest convenience.

If you encounter any issues, please set the bug back to the ASSIGNED state and
describe the issues you encountered. If you have found a NEW bug, clone this
bug and describe the issues you encountered. Further questions can be
directed to your Red Hat Partner Manager.

If you have VERIFIED the bug fix. Please select your PartnerID from the
Verified field above. Please leave a comment with your test results details.
Include which arches tested, package version and any applicable logs.

 - Red Hat QE Partner Management

Comment 7 Chris Ward 2009-04-16 16:07:58 UTC
~~ Attention! Snap 4 Released ~~
RHEL 4.8 Snapshot 4 has been released on partners.redhat.com. There should
be a fix present that addresses this bug. NOTE: there is only a short time
left to test, please test and report back results on this bug ASAP.

The latest kernel build can be obtained here:
http://people.redhat.com/vgoyal/rhel4/

If you encounter any issues, please set the bug back to the ASSIGNED state and
describe the issues you encountered. If you have found a NEW bug, clone this
bug and describe the issues you encountered. Further questions can be
directed to your Red Hat Partner Manager.

If you have VERIFIED the bug fix. Please select your PartnerID from the
Verified field above. Please leave a comment with your test results details.
Include which arches tested, package version and any applicable logs.

Comment 8 nate.dailey 2009-04-16 16:57:24 UTC
Marking this verified by Stratus. I'm not set up to test RHEL 4.8, but I
verified the fix was present in the source RPM and the sources I built from it.

Comment 10 errata-xmlrpc 2009-05-18 19:28:52 UTC
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/RHSA-2009-1024.html

Comment 11 Doug Ledford 2014-06-10 14:50:53 UTC
Clearing stale needinfo on CLOSED bug.


Note You need to log in before you can comment on or make changes to this bug.