LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Untar from a CD (https://www.linuxquestions.org/questions/linux-newbie-8/untar-from-a-cd-423714/)

CJohnM 03-11-2006 12:06 AM

Untar from a CD
 
Is it possible to untar a tar.gz package from a CDROM? Would it just be untar zxvf /cdrom/<DIRECTORY>.tar.gz? I am asking because I'm having problems getting my GUI up and running on Ubuntu and working entirely in the command line. I also don't have a properly configured network, so I can't download stuff. I have a dual boot with XP, from where I run Ubuntu through VMware, so I can make the required packages that way.

Thanks

crAckZ 03-11-2006 12:19 AM

give it a try. if not i just copy (cp) it to my hd

theNbomr 03-11-2006 12:21 AM

No problem at all, as long as you have space where the untarred files will be deposited.

If it is a gzipped tar, like somefile.tar.gx, you would want to first 'cd /the/destination/directory', then

tar zxvf somefile.tar.gz.

The directory where the CDROM is mounted will vary; /mnt/cdrom is one location that some distros use. /media/cdrom seems to be gaining popularity.

--- rod.

CJohnM 03-11-2006 12:55 AM

Yes, I have a /media/cdrom directory. But when I put the CD in it doesn't do anything. Isn't detected, for some reason.

I built my system up from a debian base using an ubuntu cd which I added to my sources list. I have an Intel 865 video card, which has serious problems with X, which is why I can't get a GUI going. What I have on the CD is a patch for this, so it's quite crucial! Frustratingly my network is also asleep, so I'm stuck with this method (I had no network configured during a debian net install, so that's why I was left with just the deb base).

Is there possibly some way to force the cd to mount from the command line?

theNbomr 03-11-2006 01:53 AM

Try
mount /media/cdrom

Failing that,

man mount

--- rod.

CJohnM 03-11-2006 10:39 PM

Tried various options, including -

mount /mnt/cdrom
mount media/cdrom
mount -t iso9660 /dev/hdc /media/cdrom

The last returned the reply -

Code:

mount: block device /dev/hdc is write-protected, mounting read-only
mount: wrong fs type, bad option, bad superblock on /dev/hdc,
      missing codepage or other error
      In some cases useful info is found in syslog - try
      dmesg | tail  or so

The strange thing is I got the same result on Ubuntu through VMware, which I run on XP. I have a desktop icon for the CDROM, though, and I can easily access it there. I've tried all these commands as both root and user, and no luck. I'm going to try a floppy now. If that doesn't work does anyone know if there's a way to access a Linux partition through Windows and transfer files? I seem to remember reading about something like that.

prasanta 03-11-2006 11:53 PM

I think you are trying to mount an audio/media cd. mounting the cd with iso9660 type sometimes doesnot work. Try going with udf fstype.

CJohnM 03-12-2006 12:28 AM

Thanks Prasanta, I'll try that. I've also found this -

http://uranus.it.swin.edu.au/~jn/linux/explore2fs.htm

which I'll also try. Also this -

http://www.it.fht-esslingen.de/~zimm...re/ltools.html

WindowBreaker 03-12-2006 03:39 AM

Try mounting your cd with device file "/dev/scd0".

Code:

mount /dev/scd0 /mnt/cdrom -t iso9660
Sometimes that device file is used instead of or /dev/hdc if using SCSI emulation.

Otherwise, do
Code:

dmesg | grep -i atapi
to see which device file your cdrom was detected on at boot time.

Have you tried mounting other CD's, just to verify the CD itself is not the problem?


All times are GMT -5. The time now is 02:22 PM.