PDA

View Full Version : Retrieving Information off another HD



razored
27th April 2006, 07:48 PM
My computer broke recently, had some problems with the hardware and too expensive to get it fixed. The problem was not with the hard drive, but with the mother board. Anyway my problem is that I had FC5 and Windows XP installed on it. Now, there is no way to view this information. But i had this spare computer which has FC5 on it and I was wondering how I can get that certain information off my old hard drive. I think this is called "mounting"? Is this possible?

All help appriciated. Someone please help me :(

RedFedora
27th April 2006, 09:01 PM
Put the old hard drivein the working computer (along with the current hard drive).
The new hard drive will probably be named /dev/hdb (usually the main drive
is /dev/hda).
You can then access the paritions of the drive using

mount /dev/hdb1 /directory/to/mount/files
mount /dev/hdb2 /another/directory
mount /dev/hdb3 /yet/anohter/directory

Some of the paritions might not have anything on them. Or
at least nothing usable. This will likely be the case of
virtual partitions and the swap area.

reboot
27th April 2006, 09:01 PM
Ok.
Attach your harddrive to the working FC system and boot into root account, then try these:


#fdisk -l

There you'll find info about current system hard drive, and the attached one, depending of your hard drive it can be /dev/sda or /dev/hda, or /dev/sdb, /dev/hdb....
Let's presume that your attached harddrive is called /dev/hdb, so using the command mentioned above you will know what partitions are on that disk, for windows system, there may be NTFS or FAT, for linux ext3, ext2.

try to mount the partitions to your prepared directory:


#mount /dev/hdb2 /mnt/myolddisk

Remember that this command will work if "/dev/hdb2" partition is linux. Otherwise you shoul write this:


#mount -t vfat /dev/hdb2 /mnt/myolddisk

Hope you find this short help usefull.

You can always try to figure out by yourself using this:


#man mount

or


#man fdisk

Firewing1
27th April 2006, 09:26 PM
Yes - Attach the old HD to your space FC box, and then post output of
fdisk -l
and we can help.
Firewing1

razored
27th April 2006, 10:29 PM
Ok new plan. I just plugged in my old hd, then i booted linux from it. It made a fresh config of Windows X but now, i have to access my Windows Partition which is in /dev/hda1(On the same HD) and it says NFTS next to it, so i'm pretty sure its the Windows partition. Now forget about the 2nd hdd stuff. The information is right on that very hdd, so how do i connect to that and copy my files over?

Another question, i've read your all your mounting instructions, but i am mounting an NFTS partiton. So what command must be used?
mount /from /to
I don't want to risk using that yet, will wait for further instructions.

Firewing1
27th April 2006, 11:04 PM
su -
cd /mnt
mkdir Windows
rpm -Uhv http://rpm.livna.org/livna-release5.rpm
yum install kmod-ntfs
modprobe ntfs
Gets the system prepared correctly (makes the mount directory and installs the NTFS module)
Next,

mount -t ntfs /dev/hda1 /mnt/Windows
If you'd like to copy files over, use
cp -a /mnt/Windows /rootThat will copy the entire drive over to your /root/Windows directory.
Firewing1

razored
27th April 2006, 11:32 PM
When i type in modprobe ntfs it says Module not found... but i closed the terminal window after the yum install kmod-ntfs then opened it and typed in the modprobe thing. Thats when it said module ntfs not found.

I also went a step ahead and typed in mount -t ntfs /dev/hda1 /mnt/Windows, just like before it said error that ntfs diidnt exist.

What can i do?

Firewing1
27th April 2006, 11:47 PM
I take it you in Core 5... You have to stay in the same terminal. (well, really be root.)
Do this:

rpm -q kmod-ntfs
if it shows you it's installed, then run:
yum update kernel
Next, reboot and then type:

su -
modprobe ntfs
mount -t ntfs /dev/hda1 /mnt/Windows
if you want
cp -a /mnt/Windows /root
If you want a GUI environment to copy the files in, then run:
su -
nautilus --no-desktop /mnt/Windows &
Firewing1

razored
28th April 2006, 12:19 AM
Ok it worked! Thank you! But i extracted them all into /var/www/html so i can download off another computer. But i have a question, how come I cannot change the permissions, because of that i cannot download it. How can i fix that?

Firewing1
28th April 2006, 12:33 AM
su -
chmod -R ### /path/
BTW - If you copied it to /var/www/html each file will have to be downloaded seperately. What I'd to is make a .tar archive and put it there, so there are no permission issues and it's a all-in-one download:
su -
mv /var/www/html/Windows /root/Windows
# note: Change /var/www/html/Windows to the correct path if that's not it.
cd /root
tar -cf WindowsFiles.tar /root/Windows
# This may take a WHILE depending on your system. It will also take up as much space as the Windows files did, so make sure you have some disk space ready.
mv WindowsFiles.tar /var/www/html
chmod 644 /var/www/html/WindowsFiles.tar
Now just download "WindowsFiles.tar" from another computer.
Firewing1

foxmuldar
28th April 2006, 01:06 AM
Hey Dude! as you know i have two HD's on my box, and i want to take the HD with winxp out of this box, and just the linux HD, plus a storage HD. I know that you are a very smart man...How can i do this?

Thanks,
foxmuldar,

Firewing1
28th April 2006, 01:10 AM
Well, I don't wanna hijack the starter's thread so I'll make it short - Basically you must remove the WinXP hard drive, make Fedora the master and then put your extra storage one as slave. Start up the computer, and then Fedora should start OK. Pull up a terminal and run:
su -
yum install gparted
gparted
Partition your new HD, configure /etc/fstab to mount it, and you're done :)
Firewing1

foxmuldar
29th April 2006, 04:44 AM
Sorry dude! lately i have been posting in the wrong area, i don't know where to post! Can i partition the storage drive using that windows partitioning program? i forgot the name..:(

imdeemvp
29th April 2006, 08:34 AM
Sorry dude! lately i have been posting in the wrong area, i don't know where to post! Can i partition the storage drive using that windows partitioning program? i forgot the name..:(
You can use fdisk if you are an experienced dos user and or you can use partition magic. My favorite is partition commander which you can download from bittorrent. (http://www.bittorrent.com/detail.myt?infohash=DA1578B792EB54CA0B5CC8F1144CFE FFF9226566&per_page=10&search=partition%20commander&index=1)

foxmuldar
29th April 2006, 01:43 PM
Can i use partition magic in windowsxp to partition the HD? I just partition it in linux format...right?

Thanks for your help...
foxmuldar,

imdeemvp
29th April 2006, 10:52 PM
Can i use partition magic in windowsxp to partition the HD? I just partition it in linux format...right?

Thanks for your help...
foxmuldar,
Yes, you can but you have to boot up from the disk and take it from there. Partition commander is much simpler than partition magic. I strongly recommend it.

foxmuldar
29th April 2006, 11:26 PM
I downloaded Partition Commander, but it is in zip format, and linux can not do anything with it, now what do i do?

Thanks,

razored
30th April 2006, 01:21 AM
yeah, I used Partition Magic to partition my HD for Linux.

imdeemvp
30th April 2006, 04:55 AM
I downloaded Partition Commander, but it is in zip format, and linux can not do anything with it, now what do i do?

Thanks,
Since it is a windows app you have to run it under windoz.....

troyw3412
30th April 2006, 05:28 PM
[QUOTE=Firewing1]

mount -t ntfs /dev/hda1 /mnt/Windows[/code]

Firewing:

Thank you for posting the instructions on mounting NTFS partitions.

I'm a brand-new Linux user (today marks my first week of stumbling around and getting myself acquainted with the operating system and new text commands). I'm an old DOS user before Windows took hold, so I'm no stranger to keyboard commands.

However, I was wondering if there's a way I could append those lines to the system start. Meaning, I'd like to have the drive (with two paritions) mapped each time when the computer starts up.

Thank you again in advance.

Firewing1
30th April 2006, 05:59 PM
Sure - There's a file in /etc (the Linux configuration directory) called "fstab" that controls exactly this.
So, let's edit /etc/fstab:


su -
gedit /etc/fstab
Add to the bottom:

/dev/hda1 /mnt/Windows ntfs owner,users,ro,exec,umask=002,gid=user 0 0
Make user your username, and that way you'll be the owner of the files in it. It will also be there on bootup.
Firewing1

troyw3412
30th April 2006, 10:23 PM
Make user your username, and that way you'll be the owner of the files in it. It will also be there on bootup.
Firewing1

Thank you! That solved another issue I was having. When I would mount the drives, I had to be logged in under 'root'. So, I'd log in, mount the drives, log out, and then go into my account, but each of the folders would be locked. Root was set as the owner, and Konqueror would not allow me to change permissions on multiple files/folders without throwing back an error.

Your suggestion did the trick. I'm able to access all of the files from my old drive! Thank you again, you've been a terriffic help!

Firewing1
1st May 2006, 03:07 AM
No problem, glad I could help :)
If you'd like to see more options, you can type
man mountLook for option that go with "-o" - Those are the ones you can add, comma seperates, to fstab. You'll find that 'gid=' and 'umask=' are in there, too.
Firewing1