Command Line Ejections
Nice. I just figured out how to eject my CD/DVD drive on my Linux desktop (Xubuntu) via command line!
First, display your fstab file to see what the drive is named: ’sudo cat /etc/fstab’
Then look for your disc drive. Mine was called ‘cdrom0′.
Once you’ve found it, type ‘eject [name of drive]‘ and watch the magic.
I mapped that command to my keyboard. Gnome, Xfce and KDE all have a an interface to help you map keyboard shortcuts in their system preferences, or you can just edit the config files manually with a little googling. I mapped ‘ALT-Shift-F12′ to run ‘eject cdrom0′. Easy.



July 18th, 2008 at 10:31 pm
You can also close the CD/DVD rom by typing “eject cdrom0 -t”.
Cheers!