How do I mount External Hard Drive and what command to backup Home Folder to it ?
Hello:
On ubuntu 10.10 notebook edition, that won't boot due to /sbin/init being damaged, how would I mount the External Hard Drive and then what command would I use to backup my Home Folder to External Hard Drive , using live CD? I am hoping to salvage my Home Folder and then do a Re-install of my ubuntu 10.10 notebook edition. Using Live CD when I go to my home folder, I can see all the partitions on the old system and their size, but how would I back up the Home Folder to the external HD? mansour |
The external hard drive should be auto-mounted by the live cd.
To mount the partition in which resides your home folder, the command line is your friend: 1) first you have to create the directory that you'll use as mount point: Code:
sudo mkdir /media/mypartition Code:
sudo mount /dev/sda1 /media/mypartition For example: Code:
cp -R /media/mypartition/home/yourusername /path/to/external/hard/drive Code:
$ cd /media/mypartition/home/yourusername |
Quote:
Ok, I performed all the above commnads in the terminal. But it didn't work. I couldn't copy to mypartition directroy. I suspect has to do with the fact that my External Usb Drive is an NTFS file system? mansour |
Exactly, what happens? performing the commands results in error messages?
(ps don't forget to unmount with the umount command) |
Quote:
Code:
mansour |
Quote:
I would suggest that if you are doing this from an Ubuntu CD, you run the sudo fdisk -l(lower case Letter L in the command) and post that drive/partition information here. If your external is auto-mounted it probably is in the /media directory with a UUID number. You will need to create a mount point for your external partition if you are going to use a terminal to copy to it. Post the fdisk output. |
Try doing the following:
- Boot your laptop with the LiveCD - Once you are at the desktop, connect your external hard drive to your laptop - Start a Terminal window In the following order: - Type lsusb - Type su (this should get you root access) - Type fdisk -l - Type mount - Type cat /etc/fstab Post the results of those commands. Update: I tried sudo on my fresh Slackware v13.37 install when logged in as a regular user (non-root and non-super user) and it gave me an error message stating that my regular user account is not in the sudoers file. However, su just asks for the root password if I boot into Slackware. If I boot a Knoppix v6.7.1 LiveCD su doesn't require a password for root. I suspect the Ubuntu LiveCD may not require a password for su. If sudo doesn't work try su. |
OP is using ubuntu and for root access he should be using 'sudo' to start his command lines. With the live cd he will not be asked for a password.
yancek is right and all we need is the uuid and the following should solve all. Quote:
|
Quote:
mkdir /mnt/extdrive mount /dev/sdb1 /mnt/extdrive # check that /dev/sdb1 is mounted mount mkdir /mnt/tmphome # you need to get the right partition to mount the home directories mount /dev/sda???? /mnt/tmphome # check that tmphome is mounted mount cp -a /mnt/tmphome /mnt/extdrive This is for if /home is on its own partition. If it isn't, your cp command should be more like this: cp -a /mnt/tmphome/home /mnt/extdrive |
Quote:
|
Quote:
|
Quote:
So this is the output of that command: Code:
mansour |
Quote:
Code:
mansour |
The problem now is, which of the seven Linux partitions contains your home directory? You can eliminate sda1 as it is too small to be anything but a boot partition. sda2 is your Extended partition which contains no data and sda10 is swap. Do you have a separate /home partition or is it in your / partition? Why all these partitions if you only have Ubuntu? or do you?
The /etc/fstab file you posted is from the Live Cd and doesn't give any useful information. Do you know where your /home directory is? on a separate partition? the / partition? do you know which partition that might be? If not you will probably have to try creating a mount point for each, mount each partition until you find your /home directory. Repeat this process for each partition until you find it, partitions 5 - 11 (excepting 10 - swap) unless you know which partition it is?? sudo mkdir /mnt/sda5 sudo mount -t ext4 /dev/sda5 /mnt/sda5 After doing the above, you can navigate to the /mnt/sda5 partition to see if your /home is there: ls /mnt/sda5 You could also open nautilus file manager, sudo nautilus. |
Quote:
This was our first school assignment, to create so many partitions manually, so to learn how manual partitioning works in Linux. I have two other Linux machine as part of a small network, which I let Linux do the partitioning for me. It was very simple. One is Ubuntu server 10.04 , the other is ubuntu 10.04 desktop. So my /Home partition is the one which is 13 GB in size. (/dev/sda11 ) (It includes /root and /mansour ) When I go to Places ==> Home ==> I see all the partitions in the left pane. The 13 GB partition is /Home. I can mount them all by right clicking on them and then choosing mount from the menu. Code:
Code:
/dev/sdb1 is my USB Hard Drive.( 1 TB and is NTFS) OK, I see a file was transfered to my USB HD called FreeAgentGoNext.ico That's the name of my HD backup software. I safely removed it from my notebook and put it on the ubuntu 10.04 desktop machine. How would I be able to read them there though? I mean FreeAgentGoNext.ico, what would I do to transfer this to the /home folder of ubuntu desktop machine? Please help here. Mansour |
All times are GMT -5. The time now is 09:32 PM. |