Bug 569377 - CDROM install unable to eject disc - storage: error ejecting cdrom sr0: (5, 'Input/output error')
Summary: CDROM install unable to eject disc - storage: error ejecting cdrom sr0: (5, '...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: anaconda
Version: 13
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Peter Jones
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: https://fedoraproject.org/wiki/Common...
Depends On:
Blocks: F13Beta, F13BetaBlocker
TreeView+ depends on / blocked
 
Reported: 2010-03-01 13:34 UTC by James Laska
Modified: 2013-09-02 06:45 UTC (History)
3 users (show)

Fixed In Version: anaconda-13.37-1.fc13
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-03-27 04:53:50 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
/tmp/*log.tgz (70.93 KB, application/x-gzip)
2010-03-01 13:34 UTC, James Laska
no flags Details

Description James Laska 2010-03-01 13:34:26 UTC
Created attachment 397067 [details]
/tmp/*log.tgz

Description of problem:


Version-Release number of selected component (if applicable):
 * anaconda-13.32

How reproducible:
 * 1 out of 1 attempts on *bare* metal (not virt)

Steps to Reproduce:
1. Follow instructions at https://fedoraproject.org/wiki/QA/TestCases/InstallSourceCdrom

 
Actual results:

[anaconda.log]
08:38:20,984 INFO anaconda: switching from media #1 to #2 for Packages/system-config-lvm-1.1.12-2.fc13.noarch.rpm
08:38:25,894 DEBUG anaconda: isys.py:umount()- going to unmount /mnt/source, removeDir = False

[storage.log]
08:38:25,893 DEBUG storage: found OpticalDevice instance (0x7f9d03611790) --
  name = sr0  status = True  parents = []
  kids = 0
  id = 4
  uuid = None  format = <storage.formats.fs.Iso9660FS object at 0x7f9d03611810>  size = 691.609375
  major = 11  minor = 0  exists = True
  sysfs path = /devices/pci0000:00/0000:00:06.0/host0/target0:0:0/0:0:0:0/block/sr0  partedDevice = <parted.device.Device object at 0x7f9d03611850>
  target size = 0  path = /dev/sr0
  format args = []
08:38:26,000 DEBUG storage:                     OpticalDevice.eject: sr0 ; status: True ;
08:38:26,005 DEBUG storage:                      OpticalDevice.teardown: sr0 ; status: True ;
08:38:26,112 WARNING storage: error ejecting cdrom sr0: (5, 'Input/output error')

Expected results:

Ejected disc

Additional info:
 * See attached log files

-rw-r--r-- root/root     31466 2010-03-01 08:39 tmp/X.log
-rw-r--r-- root/root     13278 2010-03-01 08:38 tmp/anaconda.log
-rw-r--r-- root/root     57716 2010-03-01 08:38 tmp/program.log
-rw-r--r-- root/root    183168 2010-03-01 08:38 tmp/storage.log
-rw-r--r-- root/root     80675 2010-03-01 08:39 tmp/syslog
-rw-r--r-- root/root    136712 2010-03-01 08:22 tmp/yum.log

Comment 1 James Laska 2010-03-01 13:35:53 UTC
= Additional information =

From tty2, I can successfully eject the disc by typing: 

# eject /dev/cdrom

Comment 2 James Laska 2010-03-01 13:39:47 UTC
= Tested workaround =
1) change to tty2
2) type: eject /dev/cdrom
3) insert next disc
4) type: mount -o ro /dev/cdrom /mnt/source
5) Return to tty6
6) Select OK to proceed with install

NOTE: step#4 was required, for some reason anaconda wouldn't continue the install unless I manually mounted the next ISO

Comment 3 Chris Lumens 2010-03-01 23:03:22 UTC
What about if you flip to tty2 and instead:

PYTHONPATH=/usr/lib/anaconda python
>>> import _isys
>>> import os
>>> fd = os.open("/dev/sr0", os.RD_ONLY|os.NONBLOCK)
>>> _isys.ejectcdrom(fd)

Comment 4 James Laska 2010-03-02 14:02:58 UTC
Figures, when retesting ... the problem did not occur.  I'll continue testing ...

Comment 5 James Laska 2010-03-02 14:54:53 UTC
Reproduced, the problem surfaces only when you mediacheck the disc in loader.  The suggestion in comment#3 does not resolve the issue.

>>> _isys.ejectcdrom(fd) 
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
SystemError: (5, 'Input/output error')

Comment 6 Chris Lumens 2010-03-02 15:04:03 UTC
Well, the point of the suggestion in comment #3 was to isolate that it was the same code anaconda's using that causes the problem without involving all of anaconda.

Comment 7 James Laska 2010-03-02 15:29:04 UTC
Moving to F13Beta per point#3 of the Beta release criteria (https://fedoraproject.org/wiki/Fedora_13_Beta_Release_Criteria#Beta_Release_Requirements)

Comment 8 James Laska 2010-03-02 15:33:15 UTC
Documented known issue and workaround for Alpha users at https://fedoraproject.org/wiki/Common_F13_bugs#failure-to-eject-cdrom

Comment 9 Hans de Goede 2010-03-08 10:48:00 UTC
James,

I've taken a quick look at what the eject command does differently,
Can you try some python code on tty2 again, but this time this one:

PYTHONPATH=/usr/lib/anaconda python
>>> import _isys
>>> import os
>>> fd = os.open("/dev/sr0", os.O_RDWR|os.O_NONBLOCK)
>>> _isys.ejectcdrom(fd)    

And can you also run eject in verbose mode:
eject -v /dev/sr0

Thanks,

Hans

Comment 10 Chris Lumens 2010-03-09 14:15:27 UTC
Hans - I already asked him to do that.  Please see comment #3 and comment #5.

Comment 11 Hans de Goede 2010-03-15 13:13:05 UTC
(In reply to comment #10)
> Hans - I already asked him to do that.  Please see comment #3 and comment #5.    

Chris,

Look closer:
1) My python code has other open flags (the same as the eject binary uses)
2) The eject command I gave has a "-v"

James,

Could you please provide the info I requested in comment #9. Note that it would be good to have the output of both when booted with and without mediacheck.

Thanks,

Hans

Comment 12 James Laska 2010-03-15 15:05:13 UTC
(In reply to comment #11)
> (In reply to comment #10)
> > Hans - I already asked him to do that.  Please see comment #3 and comment #5.    
> 
> Chris,
> 
> Look closer:
> 1) My python code has other open flags (the same as the eject binary uses)
> 2) The eject command I gave has a "-v"
> 
> James,
> 
> Could you please provide the info I requested in comment #9. Note that it would
> be good to have the output of both when booted with and without mediacheck.

Due to further hal-ectomy changes during the F-13-Alpha release process, the bits released as F-13-Alpha no longer have the 'eject' binary available.

I have copied the /usr/sbin/eject binary from the F13 eject package and run it on the system.

= with mediacheck =

# eject -v -v -v /dev/cdrom 
/tmp/eject: device name is `/dev/cdrom'
/tmp/eject: expanded name is `/dev/cdrom'
/tmp/eject: `/dev/cdrom' is a link to `/dev/sr0'
/tmp/eject: `/dev/sr0' is mounted at `/mnt/source'
/tmp/eject: checking if device "/dev/sr0" has a removable or hotpluggable flag
/tmp/eject: unmounting device `/dev/sr0' from `/mnt/source'
/tmp/eject: `/dev/sr0' is not a multipartition device
/tmp/eject: trying to eject `/dev/sr0' using CD-ROM eject command
/tmp/eject: CD-ROM eject command failed
/tmp/eject: trying to eject `/dev/sr0' using SCSI commands
/tmp/eject: SCSI eject succeeded


= without mediacheck =

# eject -v -v -v /dev/cdrom 
/tmp/eject: device name is `/dev/cdrom'
/tmp/eject: expanded name is `/dev/cdrom'
/tmp/eject: `/dev/cdrom' is a link to `/dev/sr0'
/tmp/eject: `/dev/sr0' is not mounted
/tmp/eject: unable to open /etc/fstab: No such file or directory
/tmp/eject: checking if device "/dev/sr0" has a removable or hotpluggable flag
/tmp/eject: `/dev/sr0' is not a multipartition device
/tmp/eject: trying to eject `/dev/sr0' using CD-ROM eject command
/tmp/eject: CD-ROM eject command succeeded

Comment 13 Hans de Goede 2010-03-16 10:21:41 UTC
Moving this over to pjones as discussed on irc.

Comment 14 James Laska 2010-03-25 13:15:16 UTC
Retested and confirmed the reported behavior remains present in F-13-Beta-TC1

Comment 15 Fedora Update System 2010-03-27 03:26:14 UTC
anaconda-13.37-1.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/anaconda-13.37-1.fc13

Comment 16 Fedora Update System 2010-03-27 04:53:00 UTC
anaconda-13.37-1.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.


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