How To Mount CD Rom Linux Shell Command


How To Mount CD Rom Linux Shell Command
  Forums Index
      » Linux Forums
        » » How To Mount CD Rom Linux Shell Command



How To Mount CD Rom Linux Shell Command
Post Description:
Post Tags: how, to, mount, cd, rom, linux, shell, command, linux, linux support, linux questions, linux server, programming, assistance, questions, answers, tech, it, unix
This Post Has Been Viewed 15999 Times Since Thu Aug 24, 2006 7:01 pm Posted By hostman with 5 replies
How To Mount CD Rom Linux Shell Command
20080925__usb-crdrom.jpgToday I will show you how to mount the CD Rom from the shell. i wanted to mounth this external dvd rom i bought at the electronic store. it works fine with mircrosoft windows xp and vista. but when i connect it to my web server which has fedora red hat linux on it i cant find it because it does not automatically mount it. so i tried it on my linux/unix desktop and it works. i see that it automatically mounts the drive. however, on my web server, there is not GUI, so im basically have to do it the old fashion way by the shell command. i use these commands to mount the cd drive and be able to copy files i have on my disks. this is very helpful if i have some applications i want to transfer. mounting an external USB drive is much easier than having an internal drive because i can exchange it between computers and its safer because i can share it with many computer. linux has also the option to run it as a cd server. wow, yeah, i love linux, it has so many capabilities. but as a linux admin, you have to know how to send comands and be familiar with them. and the mount command is such example where you need to know what commands to send when you are mounting a drive. once you have it mounted, you can navigate just like any other directory. so here we go

send the mount command:
mount /dev/cdrom


Thats all! to see the files in your cdrom disk, just executed the following command:

cd /media/cdrom


For Red Hat Enterprise Edition Version 3 use this:
cd /mnt/cdrom



once you are in the cdrom directory, typ ls to list all the files in your cd

very easy huh!

note: I was using Redhat/Fedora for this example.

if you would like to help me, i would like to know what brand and model of USB drive you are using, this way we all will be able to learn from each other, the more information you can provide, the more people like you will be able to find this post so that they can also learn how to put and install an external usb drive in their computer.

thank you


Leave Your Comments
* Your Name

  * Your Email Address (Will Not Be Published)

* Your Comments


Add Picture To Comments
Yes No             upload
Receive Replies on my Comments
(An email will be sent to you when someone replies to your comments)

     




Comments and replies About How To Mount CD Rom Linux Shell Command






:: 1 :: #97 - Reply By alberto On Tue Jan 16, 2007 6:36 am
i tried your method and i kept getting an error. I send the command you say here, but when i send the command in the linux shell, i get an error saying that /mnt/cdrom directory of file doesn't exist. I read one of your other posts here where it explains how to mount an external USB hard drive in linux thought the command shell. So i was able to figure out how to properly mount my CDROM Drive in my linux computer.

The first thing i did was logged in as root in my server, then i had to create a directory to which to mount the cdrom to. This part i didn't understand about linux. when am actually mounting a device, am actually putting all the content into whichever direcoty i wish to mount the device to.

For example, lets say i want to mount my cd drom right, so this is what i have to do:

1. opend your cdrom drive and put the cd inside and close the drive, the login as root
2. create a directory to which i am going to mount the device to. in this example, i will use create a directory in /mnt called cdrom, the command to do this, is this one:
     Code:
mkdir /mnt/cdrom

3. once i have created the /mnt/cdrom directory, i am going to mount my cdrom to the /mnt/cdrom directory, but first i want to make sure that the cdrom is listed in my devices so i will send this comand:
     Code:
ls /dev/
when i send this command i get this:
     Code:
[root@ns1 ~]# ls /dev
adsp fd0u360 lp0 ram12 stderr tty25 tty46 ttyS0
agpgart fd0u720 MAKEDEV ram13 stdin tty26 tty47 ttyS1
apm_bios fd0u800 mapper ram14 stdout tty27 tty48 ttyS2
audio fd0u820 md0 ram15 systty tty28 tty49 ttyS3
bus fd0u830 mem ram2 tty tty29 tty5 urandom
console floppy-fd0 mixer ram3 tty0 tty3 tty50 vcs
core full net ram4 tty1 tty30 tty51 vcs1
cdrom gpmctl null ram5 tty10 tty31 tty52 vcs2
disk hda nvram ram6 tty11 tty32 tty53 vcs3
dm-1 hda1 par0 ram7 tty12 tty33 tty54 vcs4
dmfm hda2 parport0 ram8 tty13 tty34 tty55 vcs5
dsp initctl parport1 ram9 tty14 tty35 tty56 vcs6
fd input parport2 ramdisk tty15 tty36 tty57 vcsa
fd0 kmsg parport3 random tty16 tty37 tty58 vcsa1
fd0u1040 log port root tty17 tty38 tty59 vcsa2
fd0u1120 loop0 ppp rtc tty18 tty39 tty6 vcsa3
fd0u1440 loop1 ptmx sda tty19 tty4 tty60 vcsa4
fd0u1680 loop2 pts sda1 tty2 tty40 tty61 vcsa5
fd0u1722 loop3 ram sequencer tty20 tty41 tty62 vcsa6
fd0u1743 loop4 ram0 sequencer2 tty21 tty42 tty63 VolGroup00
fd0u1760 loop5 ram1 sg0 tty22 tty43 tty7 X0R
fd0u1840 loop6 ram10 shm tty23 tty44 tty8 zero
fd0u1920 loop7 ram11 snd tty24 tty45 tty9

As you can see from the list, i have a device called "cdrom" so i want to moun this device to the directory i created earlier called "cdrom" so to do that i send this command:
     Code:
mount -t auto /dev/cdrom /mnt/cdrom


IMPORTANT: don't remove the cd inside the cdom until you have properly unmounted the device, to unmount the cdrom device from our directory we created earlier (/mnt/cdrom) send this command:


     Code:
umount /mnt/cdrom


Done, thats it, - thanks for the guys at www.webune for their support on this.
:: 2 :: #51123 - Reply By satish On Mon Apr 21, 2008 10:12 pm
Reply How To Mount CD Rom Linux Shell Command
it's so kooolllllllllll
:: 3 :: #51256 - Reply By ambedkhar On Tue Apr 22, 2008 9:22 pm
i did above all thing in my redhotlinux operating system.but whenever i mount cd rom its not install any software(ex:audio,realplayer)why its happend.i dont know tell me the reason.
:: 4 :: #57715 - Reply By rameshkumar On Fri Jun 13, 2008 11:27 pm
hi this ramesh i want to learn basic linux comments
:: 5 :: #70293 - Reply By Sandeep On Fri Sep 12, 2008 10:21 am
i am not able to mount the cdrom. it is giving the following error giving the command
mount /dev/cdrom

it shows mount: can't find /dev/cdrom in /etc/fstab or /etc/mtab