If I reboot my laptop (with a toshiba dvd drive) after doing some things with the livecd or minimal-install cd,I am not able to eject the cdrom.I can only boot the cd again. The only way to boot the systen from harddisk, is to completely switch of the laptop.
As far as I know, there is nothing that the init scripts or kernel do that would prevent you from ejecting the CD-ROM after a reboot. Perhaps this is just a weird quirk with your laptop? Do older Gentoo CDs do this, too? What about other Linux CDs like Knoppix?
Yes, migth be a problem with the cdrom of my laptop, because the cdrom doesn't get unmounted or something like that. Older gentoo cds do this too I think. With knoppix there is no problem, caused by this "eject - close the cdrom drive and hit enter to reboot"-thing. So it would be nice if you implement something to eject the cd before reboot or poweroff the computer. This would eliminate this issue and would also be a nice feature.
OK. I'm changing this to a feature request.
Well, here it is, 2011, and I'll pop in and ask for the same feature. A new Asus laptop I got today won't eject the CD upon reboot so I cannot get to Windows to check that my Gentoo install is not messing up the Windows stuff. I have to go into BIOS, change boot orders, then exit BIOS, enter Windows, eject the CD, etc. It would be nice to have a way to eject the CD on reboot, even if it was just an option, etc.
How is a cd/dvd rom ejected from the command line? If I know that I might be able to implement something.
I'm not a programmer so I don't know the details but the program cdrecord can do it from the command line using the -eject option. Maybe there's some clues there. Very different animal - audio CDs which aren't mounted, but maybe it will help to look
The eject command allows to eject a CD from the command line. The question is whether it'll work with the mounted CD and whether it'll be able to determine the correct CD drive or instead if we can correctly do it and pass to eject the device name.
I just emerged eject here and found out a couple of things: - When you eject a cd, the eject program will first unmount the cd. - The default device it unmounts is /dev/cdrom, and if that isn't always correct, it is possible to pass a device to it on the command line. Jorge, what do you think? I'm thinking this could be implemented farely easily as an init.d script that would be part of the livecd-tools package.
(In reply to comment #8) > I just emerged eject here and found out a couple of things: > > - When you eject a cd, the eject program will first unmount the cd. Will that work if we try to call eject when the CD is still mounted? Will that work if we call it after we unmount the partitions in the shutdown init level? > - The default device it unmounts is /dev/cdrom, and if that isn't > always correct, it is possible to pass a device to it on the > command line. Right. If /dev/cdrom doesn't work, are we sure we know the device name to handle to eject? > Jorge, what do you think? I'm thinking this could be implemented farely > easily as an init.d script that would be part of the livecd-tools > package. That is what I was thinking about, if the above 2 are not an issue.
Another thing to consider for this feature is remote installs. If someone is doing a remote install, do we still want the cd to auto eject?
As we (me, William and Raúl) were talking just now on #gentoo-dev, probably the safest option would be to have the shutdown process asking the user to press a key if he wants to eject the CD. After X seconds without user action the system would continue the reboot without ejecting the CD.
(In reply to comment #10) > Another thing to consider for this feature is remote installs. If > someone is doing a remote install, do we still want the cd to auto > eject? on the LiveDVD if no user action is taken then it boots the local disk. This is done within isolinux using. ONTIMEOUT localhost # this is so the livedvd doesn't boot up again on a remote install. label localhost # creates the localhost menu which boots the first hard drive and hides it from view localboot -1 MENU HIDE
Created attachment 277541 [details] isolinux.cfg Before I lose it, I'm attaching the complete isolinux.cfg likewhoa gave me that's being used in the liveDVD.
Created attachment 277549 [details] 0001-boot-from-local-hd-if-no-response-to-boot-menu.patch This is a patch to catalyst based on likewhoa's suggestion. Let me know what you think.
I just thought of a concern about this patch. It requires intervention at the place where the cd is being booted to make sure the cd boots. If you do not respond to the boot menu the hard drive gets booted. Jorge, is this what we want?
Thinking about this, you can disregard my last comment, because someone has to be at the server to start an ssh server to begin with.
Looking at this further, it looks like the posix read command doesn't support a timeout like bash's read command does, so I do not know of a way to delay for a specific amount of time during shutdown to allow the user to specify whether they want us to eject the cd.
I've applied the patch locally to catalyst and the built CDs only boot from the CD if the user presses a key. I'll leave this bug open until we have working stages (doing the automatic login) and the OP and others can comment if this route is an acceptable alternative to this bug original request.
Hi - dunno if I'm the OP at this point. I guess I was for 2011. :-) First - thanks for working on this. Second - I'm not sure how to access your solution without burning a CD. Is there an iso file you could post that I could try out?
(In reply to comment #19) > Hi - dunno if I'm the OP at this point. I guess I was for 2011. :-) > > First - thanks for working on this. Second - I'm not sure how to access your > solution without burning a CD. Is there an iso file you could post that I could > try out? Not yet. I got a ISO working here, but I need to update some packages in the tree before we get official ISOs working. I'll upload my testing ISO when I finally get my new vserver working.
If anyone wants to test it, I've uploaded the ISO to my server: http://www.jmbsvicetto.name/releases/
We finally have this working on the install CDs - booting from the disk unless a key is pressed during boot. I'm inclined to close this bug as fixed. Does any of you feel like what we did is not enough and that being able to eject the CD is a "required" feature?
No objections, so I'm closing this as fixed.