Jan 24, 2005 Download demo project - 5.75 KB; Download source - 1.08 KB; Introduction. I was looking for code in C# to open/close the CD drive so I could make a funny program that when run would open the CD drive every five minutes and play with it 'Another cup holder for your tea governor?' If the dd command is used on a disk rather than the cdrom, it will be able to copy previously deleted files which cannot be seen by the cp command from the filesystem interface. But since you are using /dev/cdrom as the input (which doesn't have the same structure as a disk), there are no previously deleted files on the interface, so the commands should work exactly the same. Tech support scams are an industry-wide issue where scammers trick you into paying for unnecessary technical support services. You can help protect yourself from scammers by verifying that the contact is a Microsoft Agent or Microsoft Employee and that the phone number is an official Microsoft global customer service number.
Synopsis
/sbin/MAKEDEV -V
Jan 10, 2013 2. This file is used to mount remote directories locally. This is done automatically when user tries to login by mounting remote directory. The mounting is done by using this hardware file. With out this hardware file we can not do automount in a Linux box. /dev/block folder. This folder is legacy location for your block devices.
If you don't have a /cdrom directory, you may have to make one using mkdir /cdrom. Mount Simply typing mount with no arguments lists the currently mounted filesystems. Mount -t iso9660 CD-device /cdrom For this command, you should substitute the name of your CD-ROM device for CD-device in the above command line.
MAKEDEV is a program that will create the devices in /dev used to interface with driversin the kernel.
Note that programs giving the error 'ENOENT: No such file or directory' normally means that the device file is missing, whereas 'ENODEV: No such device'normally means the kernel does not have the driver configured or loaded.
Options
-v
Be verbose. Print out the actions as they are performed. This is the same output as produced by the -n option.
-i
Ignore errors parsing configuration files.
Customization
Since there is currently no standardization in what names are used for system users andgroups, it is possible that you may need to modify MAKEDEV's configuration files to reflect your site's settings.
Devices
n represents the capacity of that format in K. Thus the standard formats arefdxd360,fdxh1200,fdxD720,fdxH1440, andfdxE2880.
For more information see Alain Knaff's fdutils package.
Devices
fd0* through fd3* are floppy disks on the first controller, and devices fd4* through fd7* arefloppy disks on the second controller.
hd[a-d]
AT hard disks. The device hdx provides access to the whole disk, with the partitions being hdx[0-20]. The four primarypartitions are hdx1 through hdx4, with the logical partitions being numbered from hdx5 thoughhdx20. (A primary partition can be made into an extended partition, which can hold 4 logical partitions). By default, only the devices for4 logical partitions are made. The others can be made by uncommenting them.
Drives hda and hdb are the two on the first controller. If using the new
IDE driver (rather than the old HD driver), then hdc and hdd are the two drives on the secondary controller. These devices can also be used to acess IDECDROMs if using the new IDE driver.
xd[a-d]
XT hard disks. Partitions are the same as IDE disks.
sd[a-z], sd[a-c][a-z], sdd[a-x]
SCSI hard disks. The partitions are similar to the IDE disks, but there is a limit of 11 logical partitions (sdx5 through sdx15). This is toallow there to be 128 SCSI disks.
loop
Loopback disk devices. These allow you to use a regular file as a block device. This means that images of filesystems can be mounted, and used as normal.This creates 16 devices loop0 through loop15.
Tape Devices
st[0-7]
SCSI tapes. This creates the rewinding tape device stx and the non-rewinding tape device nstx.
qic
QIC-80 tapes. The devices created are rmt8, rmt16, tape-d, and tape-reset.
ftape
Floppy driver tapes (QIC-117). There are 4 methods of access depending on the floppy tape drive. For each of access methods 0, 1, 2 and 3, the devicesrftx (rewinding) and nrftx (non-rewinding) are created. For compatability, devices ftape and nftape are symlinks torft0 and nrft0 respectively.
CDROM Devices
scd[0-7]
SCSI CD players.
sonycd
Sony CDU-31A CD player.
mcd
Mitsumi CD player.
cdu535
Sony CDU-535 CD player.
lmscd
LMS/Philips CD player.
sbpcd{,1,2,3}
Sound Blaster CD player. The kernel is capable of supporting 16 CDROMs, each of which is accessed as sbpcd[0-9a-f]. These are assigned in groups of4 to each controller. sbpcd is a symlink to sbpcd0.
Scanner
logiscan
Logitech ScanMan32 & ScanMan 256.
m105scan
Mustek M105 Handscanner.
ac4096
A4Tek Color Handscanner.
Audio
sound
This creates the audio devices used by the sound driver. These include mixer, sequencer, dsp, and audio.
Miscellaneous
sg
Generic SCSI devices. The devices created are sga through sgh and sg0 through sg7. These allow arbitary commands to be sent toany SCSI device. This allows for querying information about the device, or controlling SCSI devices that are not one of disk, tape or CDROM (e.g. scanner,CD-R, CD-RW).
fd
To allow an arbitary program to be fed input from file descriptor x, use /dev/fd/x as the file name. This also creates/dev/stdin, /dev/stdout, and /dev/stderr. (Note, these are just symlinks into /proc/self/fd).
ibcs2
Devices (and symlinks) needed by the IBCS2 emulation.
apm
Devices for power management.
Network Devices
Linux used to have devices in /dev for controlling network devices, but that is no longer the case. To see what network devices are known by the kernel,look in /proc/net/dev.
Other Devices
Note that the list of devices above is not exhaustive. MAKEDEV can create more devices nodes. Its aim is to be able to create everything listed in thedevices.txt file distributed with Linux 2.4.
Configuration
MAKEDEV doesn't actually know anything about devices. It reads all of the information fromfiles stored in /etc/makedev.d. MAKEDEV will read any and all files in the subdirectory, skipping over subdirectories, symbolic links, and device nodes,processing lines in the files like so:
symbolic links
l linkname target A symbolic link pointing to target named linkname will be created.
aliases
a alias value Any commands that create devices for alias will also include devices that would be crated for value.
macros
=macro expansion Indicates a macro which can be referenced as $macro in subsequent configuration statements.
Configuration Conflicts
In the event that the set of configuration files contains multiple rules for agiven device name, MAKEDEV will use all of them. The end result is typically that the last rule given (either by virtue of being listed below all othermatching rules in the same file, or by being listed in a file which is read after all others which contain alternate rules) will apply. MAKEDEV reads the setof configuration files in sorted order, so this misfeature can be exploited dependably.
See Also
How To Use Dev Cdrom C Key
Linux Allocated Devices, maintained by Torben Mathiasen <[email protected]>.
Bugs
Let's hope not. If we're lucky, any problems we'll find will be confined to the configuration files,which were written by examining the devices.txt file. If your system uses udev, conflicts between devices.txt and the in-kernel data which udev uses for namingdevices may crop up. If you find any bugs, please file them in the bug database at http://bugzilla.redhat.com/ against the 'MAKEDEV' component.
Author
How To Use Dev Cdrom Card
How To Use Dev Cdrom Command
Nalin Dahyabhai, based largely on work done by Nick Holloway and Michael K. Johnson.