LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   How to mount a 1TB USB external HD on Knoppix (live CD)?? (https://www.linuxquestions.org/questions/linux-hardware-18/how-to-mount-a-1tb-usb-external-hd-on-knoppix-live-cd-851856/)

d3249 12-22-2010 01:11 PM

How to mount a 1TB USB external HD on Knoppix (live CD)??
 
Hi

This is my story.

A friend of mine had a (horrible) accident with her laptop, to the point she will buy a new one. But she would like to recover as many information as possible.

So I get my knoppix live CD (wich has saved me before).

This is my problem.

My friend borrowed a 1TB USB external HD, and knoppix doesn't mount it.

I've tried fdisk -l and I get

Code:

[this is not a copy&paste, so it may be wrong]

Device Boot        Start  End        Blocks            Id  System
/dev/sdb1            1    2666306    [a big number]    ee  GPT

I went to google and it mentioned gparted.

With it I see there's actually 3 partitions (sdb1, sdb2 and sdb3), and the last one has a NTFS file system, but I only see the first on /dev/

On the other hand, it is said that live CD doesn't support this kind of HD, some others said centos does.

any help?

honeybadger 12-22-2010 01:51 PM

Some suggestions check dmesg and see if you find anything about usb eg. 'dmesg | grep usb'. See if you can run 'lsusb'. All this will tell you if you have the usb drive detected.
Next try to mount the partitions eg. 'mount /dev/sdb1 /mnt' cd to /mnt and see if there is any info that you want to save. Do the same for sdb2 and sdb3.
As far as the ntfs partition is concerned we need to get the right sdb number. Try partx or qtparted or simillar tool. You would get a lot of info with this tool to help you rescue data.
Hope this helps.

d3249 12-22-2010 02:11 PM

Thanks for the quick response.

The USB is detected.

The basic mount comand doesn't work.

The result of ls /dev/sd* is

Code:

/dev/sda /dev/sda1 /dev/sdb /dev/sdb1
But gparted shows the 3 partions (sdb1, sdb2 and sdb3) the first two with UNKNOWN filesystem and the 3th is NTFS

thorkelljarl 12-22-2010 02:18 PM

KNOPPIX is not the only possibility...

You can use almost any live-cd to copy files, and any newer live-cd should normally mount and read/write that HDD as long as there is a valid partition table. Are you using a KNOPPIX later than 6.2? As far as you report, using "fdisk -l" the partition table doesn't seem to have what one would expect for ordinary partitions. Is it used for a backup program or something similar? If you can't access one of the partitions and can't modify the partitions, you might need to get a hold of some other HDD to transfer the files to.

If I have to do something like this I like to use PCLinuxOS for the KDE desktop, but Mint with Gnome is as easy to work with. Trying with another live-cd would isolate the problem to the live-cd or to the USB HDD.

d3249 12-22-2010 02:28 PM

I'm using Knoppix 6 with kernel 2.6.32.6

As far as I know (I'm still google-ing) the problem is that "large" HDD (>= 1TB) use GUID Partition Table (the "famous" GPT) and most of live-cd's don't support this "format" (I think it's not even a file sytem).

For instance, in my netbook (Debian squeeze/sid) it's just like any other USB memory/HDD, just "plug and play".

d3249 12-22-2010 02:34 PM

this is what I'm talking about

Quote:

The kernel support for GPT may not have been compiled into the kernel on the Live CD. I would hazard a guess that most Live CDs may not include it.

By default Redhat Enterprise Linux / CentOS comes with GPT kernel support. However, if you are using Debian or Ubuntu Linux, you need to recompile the kernel. Set CONFIG_EFI_PARTITION to y to compile this feature.
full post: http://forums.techguy.org/linux-unix...tion-hard.html

thorkelljarl 12-22-2010 07:55 PM

There is a live...

I found there are live-cds of CentOS, if you think it will work. CentOS can be installed as persistent on a USB flash drive and then modified to include more packages than on the live-cd as downloaded.

http://mirror.centos.org/centos/5/isos/

http://wiki.centos.org/Manuals/Relea...entOSLiveCD5.5

honeybadger 12-23-2010 12:42 PM

Can you mount the ntfs partition? The command is 'mount /dev/sdb1 /mnt'. Then cd /mnt and 'ls' :). Else you can open the /mnt in gui even. If you can manage to save your data we have the issue resolved.
One more thing you can do when here is run 'df -h' and see how big the ntfs is. If it is around 980GB that is fine.
I have an internal harddrive of 20GB on my pc but then when I create partitions (due to rounding up of cylinders and all that - I really do not get all that) I have an 'useable' partition of around 18GB. Now if I was to run a specialised tool like partedmagic or something like that I am sure the 2GB would show up as either unformatted space or unknown partition.
Hope this helps.

d3249 12-23-2010 03:44 PM

Thaks to everyone.

At this point I've finished (on the end I get another external HDD and then, on my own netbook, passed all the data to the first one).

I'm not in urgency anymore, but I'll try the CentOS on the pendrive... after holidays. I'll let you know.


Happy holidays

d3249 12-24-2010 10:31 AM

I couldn't wait.

The good news
Now I know how to put any distro in a usb pendrive (try unetbootin).

The bad news
CentOS (CentOS-5.5-i386-LiveCD-Release2) was useless with my problem, it doesn't even support NTFS out of the box.


happy holidays (again)

thorkelljarl 12-24-2010 12:39 PM

Maybe not out of the box...

The reason that I suggested CentOS as a persistent USB installation was that you can boot CentOS on the USB flash, enable the CentOS repositories and download any additional packages that you need. CentOS may have a kernel that reads a GPT HDD, but that does not mean that that is sufficient in itself to do such a job. That depends on what is included in the live-cd download that RedHat/CentOS has put together.

As large HDDs become the norm, GPT will become common, and until more live-cds have a GPT enabled kernel as standard, RedHat/CentOS seems to be is one of the few live linuxes available to deal with it

Luck and X-mas

d3249 12-24-2010 06:00 PM

Thanks thorkelljarl

Now I have the HDD running.

Here the steps.

I'm under Debian Squeeze/Sid with modified repositories, so I'm not sure on which one the packages are.

1.- Download CentOS Live image --> http://isoredirect.centos.org/centos/5/isos/i386/

2.- Install UNetbootin

Code:

aptitude install unetbootin
3.- Create the live USB.

- Use a >= 1GB pendrive
- Create it from the ISO you downloaded. There is a CentOS on the first option, but it's just an installer.

[EDIT 1]
Thanks to the documentation provided by thorkelljarl in the next post I have a persistent Live USB.

This is the mini-howto

Assumptions: This procedure needs a package I've only found in CentOS. I don't know of any equivalent for other distros. So I assume you are on CentOS.

1'.- create a new repo

Code:

nano /etc/yum.repos.d/CentOS-Livecd.repo
with this content

Code:

# Name: CentOS LiveCD repository
[livecd]
name = CentOS $releasever - LiveCD
baseurl = http://www.nanotechnologies.qc.ca/propos/linux/centos-live/$basearch/live
enabled=1
protect=0
gpgkey = http://www.nanotechnologies.qc.ca/propos/linux/RPM-GPG-KEY-PGuay2010

Important Note: If you are using the yum-priorities plugin you need to set this repo to the same you have for CentOS-Base.repo in order to have access to the right versions of syslinux and anaconda.

2'.- Import the GPG key

Code:

rpm --import http://www.nanotechnologies.qc.ca/propos/linux/RPM-GPG-KEY-PGuay2010
3'.- update yum and install the packages
Code:

yum update

yum install livecd-tools syslinux anaconda-runtime

4'.- Create the bootable pendrive
the command is as follows

livecd-iso-to-disk --overlay-size-mb <size> <ISO path> <device path>

For me it would be
Code:

livecd-iso-to-disk --overlay-size-mb 1024 CentOS.iso /dev/sdb1
Note: This takes a while. In my particular case it took over 15 min.

Now you can follow with step 4 (of the original guide).

[END EDIT 1]

Now you have your bootable pendrive.

4.- Boot with it.

5.- Modify the repositories. You need to add the Al Server Repo
Code:

nano /etc/yum.repos.d/Al-Server.repo
put this
Code:

[AL-Server]
name=AL Server para Enterprise Linux $releasever
mirrorlist=http://www.alcancelibre.org/al/el$releasever/al-server
gpgcheck=1
gpgkey=http://www.alcancelibre.org/al/AL-RPM-KEY

and update the package list
Code:

yum update
[Edit 2]
The RPMForge repository is another way (and maybe safer, since I got to it from CentOS documentation) to get the ntfs-3g package.

I.- download the rpm package
Code:

wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.i386.rpm
II.- get the GPG key

Code:

rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt
III.- Verify the package you have downloaded

Code:

rpm -K rpmforge-release-0.5.2-2.el5.rf.*.rpm
IV.- Install the repo and update

Code:

rpm -i rpmforge-release-0.5.2-2.el5.rf.*.rpm
yum update

[End Edit 2]

6.- Install ntfs-3g
Code:

yum install ntfs-3g
7.- Just connect your HDD

At this point I don't know how to make a Change Persistent Live USB, so you need to install ntfs-3g each time (with the corresponding internet connection).When I figure out how to fix that I'll update this post.

As I promised, the post is updated.

Thanks again

thorkelljarl 12-25-2010 01:56 PM

CentOS documents...

https://projects.centos.org/trac/livecd/wiki/ImageFlash

After you post back, might you not consider including how to create a live-USB flash from Linux, exchanging English for Spanish where it occurs, and then proposing your efforts to LQ as a sticky or howto? You might save a lot of effort by people needing to use a live linux and meeting a GPT formatted HDD for the first time.


All times are GMT -5. The time now is 02:09 AM.