Setting up CDROM and CD-RW

How to get your cdrom and cd-rw drive working in Vector linux

First off let me just say that any config file you edit should be backed up first.
You can use any of the 2 panel file managers to do this or the command line.
you have to be root or super user, to edit or back up any config file.
The command line method would go some thing like this, log in as super user by typing su in a console.

cp /etc/lilo.conf /home/paul/lilo.conf (of course in place of paul use the name of your home directory)

Ok now for the how-too.
For me the cdrom did not work after I finished installing the latest version of vl-4.0.
It is just a symlink problem, so it is easy to fix.
First I will cover just a read only cdrom, then a read-write one.

Open a terminal and su to log in as superuser.
Then type the following command

dmesg | grep CDROM

The output should look like this

hdc: NEC CD-ROM DRIVE:282, ATAPI CD/DVD-ROM drive
hdd: R/RW 4x4x24, ATAPI CD/DVD-ROM drive
hdc: ATAPI 8X CD-ROM drive, 128kB Cache, DMA
Uniform CD-ROM driver Revision: 3.12
hdd: ATAPI 24X CD-ROM CD-R/RW drive, 2048kB Cache, DMA

So in my case I have two cdrom drives, and the first one is hdc :NEC CD-ROM DRIVE.
What we are looking for is the hdc part, this is the device in the /dev directory we
are going to symlink too. Now still logged in as root change directory to /dev directory by entering the
following command

cd /dev

Now remove the bad symlink with the following command

rm -f cdrom

Now using the information we gathered about my cdrom we create a symlink to the cdrom with the following command.

ln -s hdc cdrom

If your cdrom device is hdd then you would use that instead. Exit su by typing exit and close the terminal, and your done. To mount it in xfce, icewm and fluxbox you can just click on the cdrom icon. To unmount it in xfce, icewm or fluxbox right click at the bottom of the icon and then in the drop down menu uncheck mount.

For KDE right click on the desktop then in the drop down menu select--Create New CD/DVD-ROM Device. One the dialog box opens click on the Device tab and then use the arrow next to the device input window to select /dev/cdrom an click on the read only box.

Now you'll have a icon on your kde desktop for the cdrom. Click on the icon to mount the cdrom, right click and select unmount in the drop down menu to unmount the cdrom


To mount from the command line just open a terminal and type
mount /mnt/cdrom
to unmount from command line
umount /mnt/cdrom


Ok now for the cd-rw, with the current kernel you have to emulate a scsi drive to get the burner working.
I emulate both the cd-rw and the cdrom as scsi so the burner software works with both.
In my case if you look at the output of
dmesg | grep CDROM
you see that my cdrom is hdc ,and my cd-rw is hdd. I set them both up to emulate a scsi drive so the burner
software can read the cdrom and the cd-rw, but it up to you on yours.

First of you have to edit your lilo or grub config files.

for lilo

the file is called lilo.conf and it in the /etc directory
you can use your favorite editor to edit it, or use the following command,
again logged in as root or su.
mcedit /etc/lilo.conf
add this line under the read only line

append="hdc=ide-scsi"

hit the F2 key to save it and F10 to exit midnight commander
so the tail end of my lilo.conf file looks like this


image = /boot/vmlinuz
root =/dev/hda1
label = linux
read only
append="hdc=ide-scsi"
append="hdd=ide-scsi"

then still as root run the following command

/sbin/lilo

for grub
mcedit /boot/grub/menu.lst
add the following

hdc=scsi
at the end or the kernel line
hit the F2 key to save it and F10 to exit midnight commander
so mine looks like this

title VectorLinux
root (hd0,1)
kernel /boot/vmlinux root=/dev/hda2 ro hdc=scsi hdd=scsi

quick note the grub configure file is menu.lst with an L not a 1, took me a while to figure that one out one night.


Now we have to edit our /etc/fstab file so
again logged in as root or su enter

mcedit /etc/fstab
and change the line that says
/dev/cdrom /mnt/cdrom iso9660 defaults,noauto,user 0 0
to
/dev/scd0 /mnt/cdrom iso9660 defaults,noauto,ro,user 0 0
and add a new line
/dev/scd1 /mnt/cdwritter iso9660 defaults,noauto,ro,user 0 0
then
exit
and close the terminal

So now that we have edited grub and lilo , and fstab all we have to do is link to the new device's
which will now be scd0 and scd1.
Again log in as root or su, open a console and change directory to /dev with following command

cd /dev
rm -f cdrom
ln -s scd0 cdrom
ln -s scd1 cdwriter
exit

close the terminal and reboot.

Thats it! you have to change your icon in kde to use /dev/scd0 instead of /dev/cdrom and add a new one for the burner since you have done that already it should be easy.