LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 01-17-2013, 07:12 PM   #1
Fada
Member
 
Registered: Jan 2013
Posts: 43

Rep: Reputation: Disabled
Mounting an external hard drive in Zorin OS


I've been using Linux systems for a while, but still call myself a newbie Before deciding to post the question here I had spend hours reading other posts and solutions, but still can't fix my problem.
My laptop broke, I got another one, but I want to try and recover the important files from the old hard-drive. I am not sure it is good, but I think it is. I will explain why. I bought an external hard-drive enclosure and when I plug it in (with my old hard-drive inside) it shows it on my computer, but I can not excess it. I get this message:
"Error mounting: mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so"
I tried to connect it to a desktop which has windows on it. I opened the Disk management and it indicates the drive as healthy. That gives me hope. I tried so many things and nothing seem to work. Please if you have any suggestions, let me know. I am willing to try many approaches. The only thing is I want to try to recover them while it is safe enough, so I don't risk to lose my files. Any replies will be appreciated. Thank you!
 
Old 01-17-2013, 07:30 PM   #2
yancek
Senior Member
 
Registered: Apr 2008
Distribution: PCLinux, Ubuntu, Slackware
Posts: 4,473

Rep: Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694
How did you try to mount it? From a terminal? Exactly what command did you use? What filesystem type was on sdb1? You can get that information with the command: df -T /dev/sdb1
 
Old 01-17-2013, 07:56 PM   #3
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Yes I use the Terminal and tried many commands. Sometimes it says permission denied even if I am signed as a root
When I use df that's what I get
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda1 296757080 4386784 277295840 2% /
none 1882912 312 1882600 1% /dev
none 1891064 920 1890144 1% /dev/shm
none 1891064 192 1890872 1% /var/run
none 1891064 0 1891064 0% /var/lock
none 1891064 0 1891064 0% /lib/init/rw
To try your command I have to be in root I guess. I will try and let you know. Thanks
 
Old 01-17-2013, 07:59 PM   #4
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
That's what I get when I use your command
Filesystem Type 1K-blocks Used Available Use% Mounted on
none devtmpfs 1882912 312 1882600 1% /dev
P.S. The external is attached and was attached even before I started the laptop. I think sda is my laptop drive and sdb is my external drive. I checked the partitions without the external and then with the external.

Last edited by Fada; 01-17-2013 at 08:08 PM.
 
Old 01-18-2013, 08:00 AM   #5
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora
Posts: 2,437

Rep: Reputation: 434Reputation: 434Reputation: 434Reputation: 434Reputation: 434
hello Fada, as root run the following commands and copy/paste the results here. please use the code flags to make life easier to read:

with the external enclosure connected and powered on
Code:
# fdisk -l
do that without mounting the drive. then try to mount the drive. what was the OS on the old laptop? do you know the file system type?

Code:
# mount -t ext2 /dev/path/to/external /mnt/path/to/mount/point
Quote:
"Error mounting: mount: wrong fs type, bad option, bad superblock on /dev/sdb1
this could mean the drive is dead. we will not know until we get more information.
 
Old 01-18-2013, 08:49 AM   #6
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
error

Last edited by Fada; 01-18-2013 at 09:00 AM.
 
Old 01-18-2013, 08:57 AM   #7
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Hi Lleb,

Here is the result:

# fdisk -l without the external

Code:
Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000e6247

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       37534   301489152   83  Linux
/dev/sda2           37534       38914    11079681    5  Extended
/dev/sda5           37534       38914    11079680   82  Linux swap / Solaris
with external attached

Code:
Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000e6247

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       37534   301489152   83  Linux
/dev/sda2           37534       38914    11079681    5  Extended
/dev/sda5           37534       38914    11079680   82  Linux swap / Solaris

Disk /dev/sdb: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00091280

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1       29700   238557184   83  Linux
/dev/sdb2           29700       30402     5639169    5  Extended
/dev/sdb5           29700       30402     5639168   82  Linux swap / Solaris
Then the next command without the external drive plugged in
Code:
~# mount -t ext2 /dev/path/to/external /mnt/path/to/mount/pointmount: mount point /mnt/path/to/mount/point does not exist
and with it

Code:
~# mount -t ext2 /dev/path/to/external /mnt/path/to/mount/pointmount: mount point /mnt/path/to/mount/point does not exist
Same thing. The old laptop had Zorin OS as well. I am not sure about the file system. Sorry. Thank you for your help!

P.S. I think the fyle system type is ext4 according to this:

Code:
 Filesystem    Type   1K-blocks      Used Available Use% Mounted on
/dev/sda1     ext4   296757080   4402780 277279844   2% /
none      devtmpfs     1882912       292   1882620   1% /dev
none         tmpfs     1891064       412   1890652   1% /dev/shm
none         tmpfs     1891064       188   1890876   1% /var/run
none         tmpfs     1891064         0   1891064   0% /var/lock
none         tmpfs     1891064         0   1891064   0% /lib/init/rw

Last edited by Fada; 01-18-2013 at 09:04 AM.
 
Old 01-18-2013, 09:08 AM   #8
yancek
Senior Member
 
Registered: Apr 2008
Distribution: PCLinux, Ubuntu, Slackware
Posts: 4,473

Rep: Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694
Your output shows sdb1 is a Linux partition but doesn't show the filesystem type, ext3, ext4, etc. I don't need to be root to run this command on my system, doubt you would. It does need to be an uppercase T so this should do it:

Code:
df -T /dev/sdb1
The above command changed to /dev/sda5 on my computer shows the output below, note the 'ext4' under the Type column.

Code:
Filesystem    Type    Size  Used Avail Use% Mounted on
/dev/sda5     ext4     19G  8.8G  9.3G  49% /mnt/ubuntu
You took the post by lleb above too literally. What you need to do first is create a mount point on your currently running Linux for sdb1. The simplest thing to do is create the directory:
Code:
 sudo mkdir /mnt/sdb1
After doing that and getting the filesystem type from the df -T command, run the mount command:
Code:
sudo mount -t ext4 /dev/sdb1 /mnt/sdb1
The mount command above assumes 'ext4' as Type, so if you get something else you will obviously need to change that part of your command. If you get no error, open your filemanager and go to the /mnt/sdb1 directory to view files.

If you get an error, post the exact error.

Last edited by yancek; 01-18-2013 at 09:12 AM.
 
Old 01-18-2013, 09:55 AM   #9
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Hi Yancek,
I do take everything literally

Earlier I used this command:
~$ mount
Code:
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/fada/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=fada)
Now after reading you I used this command:
Code:
~$ df -T /dev/sdb1
df: `/dev/sdb1': Permission denied
df: no file systems processed
Another one gave me an error:
Code:
~$ sudo mkdir /mnt/sdb1
~$ sudo mount -t ext4 /dev/sdb1 /mnt/sdb1
mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so
Thank you!
 
Old 01-18-2013, 08:03 PM   #10
yancek
Senior Member
 
Registered: Apr 2008
Distribution: PCLinux, Ubuntu, Slackware
Posts: 4,473

Rep: Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694
Quote:
~$ df -T /dev/sdb1
df: `/dev/sdb1': Permission denied
df: no file systems processed
Looks like you do need root permissions so just do: sudo df -T /dev/sdb1

Try the mount command with sudo: sudo mount

Your earlier output from mount only shows one partition: sda1?
 
Old 01-18-2013, 08:37 PM   #11
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Here it is :
Code:
Filesystem    Type   1K-blocks      Used Available Use% Mounted on
none      devtmpfs     1882912       312   1882600   1% /dev
~$ sudo mount
Code:
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/fada/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=fada)
And yes in my previous output from mount there was only sda1.
Anything else I could try?
Thanks a lot for your time!

Last edited by Fada; 01-18-2013 at 09:35 PM.
 
Old 01-19-2013, 12:32 AM   #12
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
I managed to get the File system type at last:
Code:
Filesystem    Type   1K-blocks      Used Available Use% Mounted on
/dev/sdb1    tmpfs     1891064         0   1891064   0% /mnt/sdb1
I don't know if it will be of any help.
I am still playing around, trying not to lose hope

~$ mount
Code:
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/fada/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=fada)
/dev/sdb1 on /mnt/sdb1 type tmpfs (rw)
/dev/sdb1 on /mnt/sdb1 type tmpfs (rw)
/dev/sdb1 on /media type tmpfs (rw)
/dev/sdb1 on /media type tmpfs (rw)

Last edited by Fada; 01-19-2013 at 12:40 AM.
 
Old 01-19-2013, 08:33 PM   #13
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Please help

I need HELP! Please someone. I think I completely screwed up the whole system. Now the sdb1 took the place of sda


~$ mount
Code:
/dev/sdb1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/fada/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=)
/dev/sdb1 on /mnt type ext4 (rw)

Last edited by Fada; 01-19-2013 at 09:13 PM.
 
Old 01-19-2013, 09:55 PM   #14
suicidaleggroll
Senior Member
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 2,603

Rep: Reputation: 940Reputation: 940Reputation: 940Reputation: 940Reputation: 940Reputation: 940Reputation: 940Reputation: 940
yancek - you can not run df in the way you keep instructing on an unmounted partition.
Code:
# df -T /dev/sdc1
Filesystem     Type     1K-blocks  Used Available Use% Mounted on
devtmpfs       devtmpfs   4083560    44   4083516   1% /dev
# mount /dev/sdc1
# df -T /dev/sdc1
Filesystem     Type  1K-blocks       Used  Available Use% Mounted on
/dev/sdc1      ext4 3845700616 2222337152 1623283464  58% /media/backups
The df output on an unmounted partition is of no use to the OP. This link has some information about getting the fileystem type of an umounted partition:
http://serverfault.com/questions/190...mounted-drives
cfdisk may be able to do it as well, however it shouldn't be necessary for the OP. I have been using Linux for many years, and I can't recall a single time I've had to specify the filesystem type on the mount command. In my experience, if mount can't autodetect the filesystem type, then it's not going to be able to mount it anyway.



OP - What have you been doing? Please post EXACTLY the commands you've been running to get where you are now. You appear to have been doing some dangerous operations on your system.

Last edited by suicidaleggroll; 01-19-2013 at 10:27 PM.
 
Old 01-19-2013, 11:14 PM   #15
Fada
Member
 
Registered: Jan 2013
Posts: 43

Original Poster
Rep: Reputation: Disabled
Suicidaleggroll thank you very much for taking your time to check my problem.
Unfortunately I wouldn't be able to say now what exactly I've been doing. I tried all the commands the 2 members here suggested. Then since I didn't have any reply for some time and I was desperate to try to recover my files or just give it up (it had taken so much of my time already) I tried many other ways. Used any advice I thought had anything to do with my situation on this and other websites. I feel I went too far.
Is there any way to check what went wrong or at least what is going on on my system? I am not worried about my laptop system since I have nothing on it I need. I can reinstall the system any time. I worry about the files on the external drive. I am ready to bury them though

Thanks again!

Last edited by Fada; 01-19-2013 at 11:25 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
External Hard Drive not Mounting beetleman64 Linux - Hardware 1 05-15-2010 10:02 AM
Mounting my external hard drive... Azzath Linux - Hardware 8 02-26-2005 03:27 AM
mounting an external hard drive adin Linux - Hardware 1 01-04-2005 04:18 AM
external hard drive mounting blahJake Debian 3 04-02-2004 06:30 PM
Mounting external hard drive gadgetboy Linux - Newbie 3 02-02-2003 08:29 AM


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

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration