当前位置:操作系统 > Unix/Linux >>

Turbolinux8workstation设置samsungDVD/CDRWcombo驱动器

参考文件:

  1.CD-Writing Mini HOWTO

  [url]http://www.linuxgazette.com/issue57/stoddard.html[/url]

  2.CD-Writing HOWTO

  [url]http://wt.xpilot.org/publications/linux/howtos/cd-writing/html/[/url]

  基本情况:

  samsung sm-316b DVD/CDRW光驱为IDE接口,12x DVD,40x CD-ROM, 16x CD-R, 我把它安装在hdd

  下面所有操作必需是root

  应该事先安装好cdrecord 和 mkisofs(均在/usr/bin/)

  首先,如果不使用刻盘功能,它的设置和普通的CD-ROM没有什么两样,即插即用,只要

  #ln -sf /dev/dvd /dev/hdd

  #mkdir /mnt/dvd

  另外,在/etc/fstab中增加一行:

  /dev/dvd /mnt/dvd iso9660 noauto,owner,ro 0 0

  即可.

  这里集中在刻盘功能的实现(应该可以适用于其他的IDE接口刻录机).

  第一步:测试内核及系统中是否具有所需的各种模块,

  运行这个脚本文件,test.sh

  #sh test.sh

  一堆提示之后,如果最下几行是:

  Cdrecord 1.10 (i686-pc-linux-gnu) Copyright (C) 1995-2001 Jorg Schilling

  Linux sg driver version: 3.1.22

  Using libscg version 'schily-0.5'

  scsibus0:

  0,0,0 0) 'SAMSUNG ' 'CDRW/DVD SM-316B' 'E304' 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) *

  说明所需的各个模块内核里面或系统里面都有,已经找到了我的combo.

  如果出现错误信息,说明需要安装所需模块或重新编译内核 :-(

  幸好我没遇到这种情况.

  第二步:修改配置文件,确保各模块下次在启动时自动装载

  1.修改/etc/lilo.conf(我用的是lilo,没用过grub,用grub的兄弟可以参照这里的道理修改)

  在root=之前一行插入

  append="hdd=ide-scsi" (如果不是安装在hdd上,改成相应的盘符)

  保存修改,运行lilo进行更新

  #lilo

  2.修改/etc/modules.conf

  在最后加入下面几行

  alias scd0 srmod

  alias scsi_hostadapter ide-scsi

  options ide-cd ignore=hdd

  3.修改盘符链接(针对我这种combo的修改,一般的刻录机不用设置与dvd有关的项)

  #ln -sf /dev/scd0 /dev/dvd

  #ln -sf /dev/scd0 /dev/cdrom

  #mkdir /mnt/cdrom

  #mkdir /mnt/dvd

  文件/etc/fstab中有关的行,如有必要也相应修改,例如改成:

  /dev/dvd /mnt/dvd iso9660 noauto,owner,ro 0 0

  /dev/cdrom /mnt/cdrom iso9660 noauto,owner,ro 0 0

  第三步,重新启动,启动后输入命令:

  #cdrecord -scanbus

  如果出现

  Cdrecord 1.10 (i686-pc-linux-gnu) Copyright (C) 1995-2001 Jorg Schilling

  Linux sg driver version: 3.1.22

  Using libscg version 'schily-0.5'

  scsibus0:

  0,0,0 0) 'SAMSUNG ' 'CDRW/DVD SM-316B' 'E304' 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) *

  说明设置成功. :-)

  最后,快速测试:

  #mkisofs -r -o image.iso /home/windrose/ (将用户目录下所有文件制成刻录镜像文件image.iso)

  #cdrecord -v speed=16 dev=0,0,0 -data image.iso

  test.sh

  test `whoami` = 'root' || echo "You must be root to execute the commands."

  cdrecord -scanbus > /dev/null

  if ! (pidof kerneld || test -f "/proc/sys/kernel/modprobe"); then

  echo "Neither kerneld nor kmod are running to automatically load modules".

  fi

  report_no_autoload() {

  echo "Ensure the module $1 is loaded automatically next time."

  }

  if test ! -f "/proc/scsi/scsi"; then

  report_no_autoload scsi_mod && insmod scsi_mod

  fi

  if ! grep "^........ sg_" /proc/ksyms > /dev/null; then

  report_no_autoload sg && insmod sg

  fi

  if ! grep "^........ sr_" /proc/ksyms > /dev/null; then

  report_no_autoload sr_mod && insmod sr_mod

  fi

  if ! grep "^........ loop_" /proc/ksyms > /dev/null; then

  report_no_autoload loop && insmod loop

  fi

  if ! grep iso9660 /proc/filesystems > /dev/null; then

  report_no_autoload iso9660 && insmod iso9660

  fi

  echo "The following is only needed for IDE/ATAPI CD-writers."

  if ! grep ide-scsi /proc/ide/drivers > /dev/null; then

  report_no_autoload ide-scsi && insmod ide-scsi

  fi

  cdrecord -scanbus
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,