LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   atapi cd burner setup walkthrough? anywhere?? (https://www.linuxquestions.org/questions/slackware-14/atapi-cd-burner-setup-walkthrough-anywhere-111275/)

mipia 11-01-2003 08:10 PM

atapi cd burner setup walkthrough? anywhere??
 
Ive been looking for a nice simple concise walkthought to get my burner working. Just something plain n simple that would start with "first thing is to setup scsi emulation, here's how..."
and end with something like "now just insert your data or music or blank cd and your on your way!"

I looked in my running linux book, couldnt find anything, I googled and found bits n pieces of problem solutions with many debian n redhat users.

All I want is to get the drive working!!! I did a lsmod and got this:

ide-scsi 9424 0

so maybe its up n going

I did a cdrecord dev=ATAPI -scanbus (saw it on a newsgroup post some where)

Cdrecord 2.00.3 (i686-pc-linux-gnu) Copyright (C) 1995-2002 Jörg Schilling
scsidev: 'ATAPI'
devname: 'ATAPI'
scsibus: -2 target: -2 lun: -2
Warning: Using ATA Packet interface.
Warning: The related libscg interface code is in pre alpha.
Warning: There may be fatal problems.
Using libscg version 'schily-0.7'
scsibus0:
0,0,0 0) 'SONY ' 'CD-RW CRX230E ' 'QYS1' Removable CD-ROM
0,1,0 1) *
0,2,0 2) *
0,3,0 3) *
0,4,0 4) *
0,5,0 5) *
0,6,0 6) *
0,7,0 7) *

and of course a simple cdrecord -scanbus:

Cdrecord 2.00.3 (i686-pc-linux-gnu) Copyright (C) 1995-2002 Jörg Schilling
Linux sg driver version: 3.1.25
Using libscg version 'schily-0.7'
scsibus0:
0,0,0 0) 'SONY ' 'CD-RW CRX230E ' 'QYS1' Removable CD-ROM
0,1,0 1) *
0,2,0 2) *
0,3,0 3) *
0,4,0 4) *
0,5,0 5) *
0,6,0 6) *
0,7,0 7) *

and here is my fstab:

/dev/hda2 swap swap defaults 0 0
/dev/hda4 / reiserfs defaults 1 1
/dev/hda1 /winc vfat user,umask=000 1 0
/dev/hda5 /files vfat user,umask=000 1 0
/dev/cdrom /mnt/cdrom iso9660 noauto,user,rw 0 0
/dev/fd0 /mnt/floppy auto noauto,user 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0

one thing I am wondering is if the /dev/cdrom needs to be changed to something else??

I also added this to lilo:
append="hdc=ide-scsi max_scsi_lun=1"

Like I said, I followed what advice I could find completely blind, not really knowing what does what.

If there is anything I still need to add or do, please let me know.

jailbait 11-01-2003 08:32 PM

"f there is anything I still need to add or do, please let me know."

/dev/cdrom should be a symbolic link to /dev/scd0 if you have not already done so and you need to make sure that the permissions on /dev/scd0 and /dev/cdrom are the way that you want them to be.


___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html

Steve Stites

mipia 11-01-2003 09:33 PM

thats what I thought LOL ( about the sym link)
that, sadly, is something I dont know how to do..
ln -s /dev/cdrom /dev/scd0?? <-- is that right?
as far as the permissions, I would like for root and users to be able to access the device. I figure since it is a stand-alone system with myself being the only user, it would make sense.
with doing that would it just be a matter of doing a chmod? or something I have to edit in the fstab?

stevenhasty 11-01-2003 09:57 PM

symlink the other way around:
ln -s /source /dest
ln -s /dev/scd0 /dev/cdrom

make sure to rm -f /dev/cdrom first

about the perms, I usually set up a group called 'cdrom' and add root and myself to it.
then
chgrp cdrom /dev/scd0
chmod g+rw /dev/scd0

mipia 11-01-2003 11:54 PM

thank you so much for your help. I havent gone and done what you reccomended quite yet, but thank you for the reply.

mipia 11-02-2003 12:03 AM

I havent gotten as far as creating the group for the cdrw yet, but one other question. In the fstab, do i need to then change /dev/cdrom to /dev/scd0 so it would look like:

/dev/scd0 /mnt/cdrom iso9660 noauto,user,rw 0 0

thanks

I really need to read up on how to properly setup my fstab config LOL ;)

lucho 11-02-2003 12:28 AM

I hadn't burn a CD for a while now, and when I tried today I found that it didn't work anymore. Soooo, after some digging and searching through the web I got mine to work. I got my kernel 2.4.22-xfs with all scsi support modular, and the first thing I noticed is that by modprobe ide-scsi I didn't get any devices in /proc/scsi ... I still don't get it, why cdrecord -scanbus fails to find any scsi device even though ide-scsi is loaded. The funny thing is it doesn't seem to matter. Apparently cdrecord doesn't need that module loaded if you use cdrecord dev=ATAPI. Anyway, apart from that, I created a script that I've used to burn a couple of CD's today, so I figure that I will post it in case it's of any use to anybody (I never liked XCDRoast or whatever it is called). Oh, by the way, this is for DATA CD's. So here it goes:

me@penguin:~$ cat bin/burn-cd.sh
#!/bin/bash
# Define the name of the CDRW, as reported by cdrecord -scanbus
CDRW_NAME="DVD-ROM SD-R1002"
# The directory to burn to the CD is to be passed as a command-line parameter
DIR=$1
# Check that you are running as root
if [ "`whoami`" != "root" ]
then
echo "This script has to be run by root. Sorry ..."
exit -1
fi
if [ "0$DIR" == "0" ]
then
echo "Usage: burn-cd.sh <name of directory to burn to CD>"
exit -1
fi
# Try to find the directory
if [ -d $DIR ]
then
echo "Found directory to burn: $DIR. Computing size ..."
IMAGESIZE=`mkisofs -R -q -print-size $DIR`
echo "Size of image : $IMAGESIZE sectors"
else
echo "Couldn't find the directory to burn: $DIR"
exit -1
fi
# Make sure that the image isn't too big or too small
if [ 0$IMAGESIZE -le 48 ]
then
echo "Cowardly refusing to burn such a small CD ($IMAGESIZE sectors)"
exit -1
fi
if [ 0$IMAGESIZE -gt 358400 ]
then
echo "Size of the ISO image greater than 700MB"
exit -1
fi
# scan for the CD-RW
echo "Please wait while I look for the CD RW ..."
SCSIDEV=`cdrecord dev=ATAPI -scanbus | grep "$CDRW_NAME" | gawk '{match($0,"[0-9],[0-9],[0-9]",tmp);print tmp[0]}'`
if [ "0$SCSIDEV" == "0" ]
then
echo "Couldn't find the SCSI device for the CD RW $CDRW_NAME"
exit -1
fi
# and now burn the CD
echo "Found! Now we will start burning the CD ..."
mkisofs -r $DIR | cdrecord dev=ATAPI:$SCSIDEV tsize=${IMAGESIZE}s -data -
echo " *** DONE ***"

mipia 11-02-2003 03:13 AM

Okay, I got everything setup to a point. I did a dmesg and noticed this:

kmod: failed to exec /sbin/modprobe -s -k scsi_hostadapter, errno = 2
kmod: failed to exec /sbin/modprobe -s -k scsi_hostadapter, errno = 2
kmod: failed to exec /sbin/modprobe -s -k scsi_hostadapter, errno = 2

J.W. 11-03-2003 01:00 PM

This is what worked for me:

1. Verify this line is in /etc/lilo.conf: append="hdc=ide-scsi"

2. Verify this line is in /etc/rc.d/rc.modules and is uncommented: /sbin/modprobe ide-scsi

3. As root, run: cat /proc/scsi/scsi (The CD-RW should be listed)

4. Edit /etc/fstab, adding this line: /dev/scd0 /mnt/scd0 iso9660 noauto,users 0 0

5. Run the following as root:
mkdir /mnt/scd0
cd /dev
rm cdrom
ln -s /dev/scd0 /dev/cdrom
chmod 666 /dev/scd0

6. To make various CD programs available universally, run:
chmod u+s /usr/bin/cdrecord
chmod u+s /usr/bin/mkisofs
chmod u+s /usr/bin/cdparanoia

-- J.W.

nitzer_slack 11-04-2003 02:36 PM

what if i accidentally 'rm'd /dev/scd0 ? =\

jailbait 11-04-2003 03:00 PM

"what if i accidentally 'rm'd /dev/scd0 ? =\"

Then you should recreate /dev/scd0 using the mknod command. See man mknod for the details.


___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html

Steve Stites


All times are GMT -5. The time now is 05:53 PM.