LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Mounting a second HDD to recover data. (http://www.linuxquestions.org/questions/linux-newbie-8/mounting-a-second-hdd-to-recover-data-802431/)

seabro 04-16-2010 12:12 PM

Mounting a second HDD to recover data.
 
Hi,

I wanted to get some data off a second disk, let me tell you what I did. (that didn't work).

The data I am looking for is under /etc/ on the second disk.

I looked in /dev for /dev/hda or hdb but there was nothing.

I found:
/dev/sda
/dev/sda1
/dev/sda2
/dev/sdb
/dev/sdb1
/dev/sdb2

So I guessed /dev/sdb /dev/sdb1 /dev/sdb2 was the second disk.

So I did:
mkdir /tmp/olddisksdb
mkdir /tmp/olddisksdb1
mkdir /tmp/olddisksdb2

Then I did
mount /dev/sdb /tmp/olddisksdb and got mount: you must specify the filesystem type
mount /dev/sdb1 /tmp/olddisksdb1 and got no feedback (good?)
mount /dev/sdb2 /tmp/olddisksdb2 and got mount: you must specify the filesystem type

If I do:
ls /tmp/olddisksdb - I get nothing.
ls /tmp/olddisksdb2 - I get nothing
ls /tmp/olddisksdb1 - I get:

config-2.6.18-128.el5 symvers-2.6.18-128.el5.gz
config-2.6.18-164.9.1.el5 symvers-2.6.18-164.9.1.el5.gz
grub System.map-2.6.18-128.el5
initrd-2.6.18-128.el5.img System.map-2.6.18-164.9.1.el5
initrd-2.6.18-164.9.1.el5.img vmlinuz-2.6.18-128.el5
lost+found vmlinuz-2.6.18-164.9.1.el5
message

This is a CentOS box, any help greatly appreciated.


Seabro

brucehinrichs 04-16-2010 12:15 PM

What is the output of fdisk -la?

unSpawn 04-16-2010 12:45 PM

Quote:

Originally Posted by seabro (Post 3937816)
mount /dev/sdb /tmp/olddisksdb and got mount: you must specify the filesystem type
mount /dev/sdb1 /tmp/olddisksdb1 and got no feedback (good?)
mount /dev/sdb2 /tmp/olddisksdb2 and got mount: you must specify the filesystem type

If I do:
ls /tmp/olddisksdb - I get nothing.
ls /tmp/olddisksdb2 - I get nothing
ls /tmp/olddisksdb1 - I get:

config-2.6.18-128.el5 symvers-2.6.18-128.el5.gz

/dev/sdb is the WHOLE disk: that gets you nothing because it shouldn't be mounted that way and that's OK. Note if 'fdisk -la' does not work just use 'fdisk -l /dev/sdb' or 'partx -l /dev/sdb'. What's interesting is the partition type of primary /dev/sdb2. Is it LVM by any chance?

seabro 04-16-2010 03:43 PM

Quote:

Originally Posted by brucehinrichs (Post 3937818)
What is the output of fdisk -la?

Thanks for your help guys.

[root@Asterix ~]# fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 60801 488279610 8e Linux LVM

Disk /dev/sdb: 80.0 GB, 80000000000 bytes
255 heads, 63 sectors/track, 9726 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 13 104391 83 Linux
/dev/sdb2 14 9726 78019672+ 8e Linux LVM
[root@Asterix ~]#

brucehinrichs 04-16-2010 04:03 PM

Quote:

/dev/sdb2 14 9726 78019672+ 8e Linux LVM
Points for unSpawn for the correct answer!

@seabro: Check out this link, I think it will explain it for you. Post back with any further questions. :)

seabro 04-17-2010 03:06 AM

Thank you very much fellas, all sorted now. :-)

brucehinrichs 04-17-2010 02:30 PM

Glad to hear it! Now please mark the thread as [SOLVED]. ;)


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