[Udpcast] predialog doesn't run? eject trouble!
alain at knaff.lu
Sun Jan 6 20:18:53 CET 2008
> But there is an error:
> When launching
> cd /proc/ide
> I see
> /proc/ide: bad directory
> And script stops.
> If I comment line used to eject CD, it is OK.
> My script runs.
> Maybe it would be possible to do something
> using /proc/sys/dev/cdrom/info or /proc/sys/dev/cdrom/autoeject
> # grep "drive name" /proc/sys/dev/cdrom/info
> drive name: hdc
> # grep "drive name" /proc/sys/dev/cdrom/info | sed -e "s/ //g"
> Troubles with redirections?
> I would like to do something like:
> # grep "drive name" /proc/sys/dev/cdrom/info | tr "\t" " " | sed -e "s/ //g" |
> cut -d ":" -f2
Indeed, in order to save space, I compiled the kernel without /proc/ide
bool "legacy /proc/ide/ support"
depends on IDE && PROC_FS
This option enables support for the various files in
/proc/ide. In Linux 2.6 this has been superseded by
files in sysfs but many legacy applications rely on this.
If unsure say Y.
As you noted, you can still achieve the same functionality using /sys
One way would for instance be the following command:
fgrep -l cdrom /sys/block/*/device/media |
To be run with today's version, in order to avoid the
More information about the Udpcast