LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-09-2014, 06:44 PM   #1
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Rep: Reputation: 0
Cannot mount External Hard Drive - fstab error


error reads:
Error mounting system-managed device /dev/sdb2: Command-line `mount "/media/scottaudio/G-DRIVE"' exited with non-zero exit status 1: [mntent]: line 12 in /etc/fstab is bad
mount: can't find /media/scottaudio/G-DRIVE in /etc/fstab or /etc/mtab


I have tried gparted and storage service manager, I still cannot make this work. I do not know enough about fstab and don't want to further ruin this drive. Pls help.
 
Old 09-09-2014, 08:09 PM   #2
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora/Pop!_OS
Posts: 2,983

Rep: Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551
use code flags and copy/paste your fstab so we can look to see exactly how you are trying to mount the drive.

also what is the filesystem type, and as this is an external drive you should probably consider using UUID instead of /dev/sdb2 in your case.

Keeping in mind that as an external drive, im guessing USB, that every time you plug the drive in there is a very high possibility that the drive letter will roll.

so /dev/sdb2 today, next maybe /dev/sdc2, the next time maybe /dev/sdd2, etc... where UUID is always the same as it is tied to the partition+filesystem.

http://liquidat.wordpress.com/2007/1...of-hard-disks/

look there for more info.
 
Old 09-09-2014, 08:29 PM   #3
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
It is a usb connected external drive, G Drive by G Technology. And it is changing the name each time it gets used. I tried to format it to FAT32 but now it says it's a msdos format drive in gparted. Here is the fstab.

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=454bd120-b103-4d09-aebd-091d6be95288 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=7a0b7872-6ea5-496d-94f9-a13f32b69a8a none swap sw 0 0
/dev/sdb2 /media/scottaudio/G-DRIVE mobile USB hfsplus defaults 0 0
/dev/sdb1 /media/sdb1 vfat defaults 0 0
/dev/sdb2 /media/sdb2 vfat uid=root,owner,users 0 0
 
Old 09-09-2014, 09:46 PM   #4
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,780
Blog Entries: 28

Rep: Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318
Quote:
/dev/sdb2 /media/scottaudio/G-DRIVE mobile USB hfsplus defaults 0 0
/dev/sdb1 /media/sdb1 vfat defaults 0 0
/dev/sdb2 /media/sdb2 vfat uid=root,owner,users 0 0
It looks as if you have two listings for /dev/sdb2 pointing to different locations in /media. I'm not sure whether that caused the error message, but it could definitely be a problem.

You might want to look into identifying devices by UUID.

http://www.cyberciti.biz/faq/linux-f...-update-fstab/

Last edited by frankbell; 09-09-2014 at 09:48 PM.
 
Old 09-09-2014, 10:08 PM   #5
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243

Rep: Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672
Two separate entries for the same partition are definitely going to cause problems. You also need to decide or find out what the actual filesystem is, one entry shows Apple hfsplus and the other vfat.
 
Old 09-10-2014, 12:09 AM   #6
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
it shows the gdrive to be fat32 file system now and is letting me use it which is good, the error is gone, but I don't understand what happened. There is also a new drive listed as sdb1 that will not allow me to acess it or unmount it from the system, it is giving me the same error as the gdrive was and says I don't have permission, am not the "owner". sdb1 is not listed at all in gparted, it doesnt even show it exists as a stand alone drive or as a partition of any other drive.

Is it normal to have "linux swap" drive partitions and "extended" partitions with every drive you try to add via usb? It automatically adds them, I don't do that and they show up on their own. My boot drive is listed as ext4, sda1, then there are added partitions as sda2 extended, and sda5 linux swap all associated with my boot drive.

I think maybe I should wipe and reinstall, this is a new system with nothing on it yet. This is a mess and I'm too new to know the fixes. I don't want my boot drive and the rest of any external drives to always be jumbled up like this. Some external drives show up just fine, no problems, while others like this gdrive have to reformatted and renamed, etc. Not sure what to do.
 
Old 09-10-2014, 08:59 AM   #7
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243

Rep: Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672
Quote:
There is also a new drive listed as sdb1 that will not allow me to acess it or unmount it from the system, it is giving me the same error as the gdrive was and says I don't have permission, am not the "owner
A new drive listed where? If you have a partition on an external drive, you would normally need to change permissions so that a regular user would have read/write permissions on it. Root/sudo should have permissions.

Quote:
Is it normal to have "linux swap" drive partitions and "extended" partitions with every drive you try to add via usb?
No. Reading the second part of that paragraph I'm not clear if you are talking about the primary disk drive where your operating system is installed or some external drive? If you are installing on a drive and use some auto method of installing without making the selections yourself, then this would be the standard. Create an ext4 filesystem for the / (root) partition then an Extended partition with a swap partition as a logical partition within it. That seems to be what you have.

Do you have two physical hard drives attached and if so, what is on them? Posting the actual output of: sudo fdisk -l(Lower case Letter L in the command) might help clarify what is going on.
 
Old 09-10-2014, 12:40 PM   #8
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
this is what it says:

Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00052dc4

Device Boot Start End Blocks Id System
/dev/sda1 * 2048 617166847 308582400 83 Linux
/dev/sda2 617168894 625141759 3986433 5 Extended
Partition 2 does not start on physical sector boundary.
/dev/sda5 617168896 625141759 3986432 82 Linux swap / Solaris

WARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sdb: 1000.2 GB, 1000204140544 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953523712 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sdb1 1 1953523711 976761855+ ee GPT
-----------------------------------------------------------------------------------------------------------------------

/dev/sda1 should be my primary boot drive (320gig). Gparted says:
/dev/sda1 ext4 - mount point / - size 294gig
3.8 gig extended
3.8 gig linux swap.

1tb external drive. This drive shows to have:
200mib on partition /dev/sdb1 fat32 - mount point /media/sdb1
930gig on partition /dev/sdb2 fat32 - mount point /media/sdb2
128mib on partition unallocated - file system unallocated - no mount point

All I have is a fresh install of Zorin 64bit and a few movies on my drives, I've already back them up to another external drive that works fine. The 1tb drive is what is giving me problems and I'm not sure my boot frive is set up properly now either.
 
Old 09-10-2014, 04:47 PM   #9
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243

Rep: Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672
If Zorin is the only operating system you have, why would you have a 930GB vfat partition?
What is the exact command you use to try to mount that partition?
 
Old 09-11-2014, 02:31 AM   #10
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
the 930g drive is an external storage drive. my internal boot drive is a 320g drive.
 
Old 09-11-2014, 09:11 AM   #11
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243

Rep: Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672
Quote:
the 930g drive is an external storage drive. my internal boot drive is a 320g drive
I see that but, the question I was asking is why you are using the old windows filesystem 'VFAT' if Linux Zorin is your only OS. Just curious as I don't see that as part of the problem. You do have a GPT partition table on the second disk but not the first but I don't use GPT so have no idea if that would be part of the problem. You could check with GParted and post the output it shows for sdb as the message above states, fdisk doesn't support GPT so may no be accurate. Also, you still haven't posted how, what command you use to try to mount. I just reviewed your earlier posts and as I understand it now, it is the second entry from your earlier post in fstab that is causing the problem, is that correct?

Last edited by yancek; 09-11-2014 at 09:12 AM.
 
Old 09-12-2014, 02:43 AM   #12
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
you are correct. also i didn't know when i was formatting the external hdd that i was using the wrong file system type but now it wont let me reformat. im not using any command line just gparted since im new and still learning. i dont know what the right file system type is for a linux system when formatting a hdd. is there a way to reformat to the correct file type and fix it?
 
Old 09-12-2014, 10:11 AM   #13
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243

Rep: Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672Reputation: 2672
Quote:
There is also a new drive listed as sdb1 that will not allow me to acess it or unmount it from the system
The statement above from one of your earlier posts indicates you are mixing terminology. In Linux sdb would be the drive meaning the physical hard drive and sdb1 would be a partition with a filesystem on that hard drive which could take up the entire drive or just part of it. In windows it seems that the terms drive/partition/volume are used interchangeabley, at least drive and partition.

If you are talking about sdb1, the vfat partition on the external, if you re-format it you will lose any data on it but according to one of your earlier posts, you don't have anything on it yet so that should not be a problem. If that's the case, open GParted and click on /dev/sdb1 in the main window to highlight it, then click on the Partition tab at the top of the window. The only option you should see that is not greyed out would be "unmount", so click it. That done, with sdb1 still highlighted click on the Partition tab again, and in the drop down menu mouse down to Format as and you will see a number of options. The default for Zorin is ext4, select that or choose another and then click the Apply tab at the top, it is a check mark icon which may or may not say Apply beneath. You will probably get a couple of "Are you sure" windows in this process. Make sure you get /dev/sdb1.
 
Old 09-16-2014, 01:31 PM   #14
scottaudio
LQ Newbie
 
Registered: Dec 2008
Posts: 16

Original Poster
Rep: Reputation: 0
I have to say that messing around with a bunch of different external hard drives in this system is a nightmare. For some gparted works fine with but not for others. I think that the G-Technology drive I was trying to use was the culprit mostly, but the only reason I say that is because it is formatted for a mac not a pc.

I backed everything up and reinstalled Zorin. I reformatted the gdrive to ntfs using a windows pc. That is all the changes I made. Now Zorin recognizes that drive and I have root,read/write permissions. All other drives are also recognized, even if they are all formatted differently. I thought I could format all my different external hard drives to the same format so I could use them all as root user with all permissions but different drives act differently and I couldn't do that. I'm glad it's all working now but I have to admit I feel a bit ripped off for not being able to work through this and get everything programmed right. This is not the solution I was hoping for but the same end result. thx for all your help everyone
 
Old 09-18-2014, 07:38 AM   #15
vinbob
Member
 
Registered: May 2005
Location: Fareham, UK
Distribution: HP-UX 11i, Fedora, Ubuntu, Debian, RHEL, OEL, CentOS
Posts: 75

Rep: Reputation: 17
I'm surprised that no-one has pointed out this line in your fstab;

Code:
 /dev/sdb2 /media/scottaudio/G-DRIVE mobile USB hfsplus defaults 0 0
Looks like you're trying to mount /dev/sdb2 to a directory with spaces in the name "/media/scottaudio/G-DRIVE mobile USB", this is your problem.
The next word "mobile" after "G-DRIVE" is being read as the filesystem type and so on. You may be able get round that by wrapping quotes around your mountpoint path but I doubt it. Don't have spaces in your directory names, it's just dirty.

Create an appropriate mountpoint, something like /media/usbdrive and mount your device to that.
Then you would have a fstab entry such as;

Code:
 /dev/sdb2 /media/usbdrive hfsplus defaults 0 0

Last edited by vinbob; 09-18-2014 at 07:41 AM.
 
  


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
[SOLVED] mount Iomega external hard drive on debian squeeze, how to use mount command Foxbat1155 Linux - Hardware 15 02-21-2012 05:55 PM
[SOLVED] enable users to mount external usb hard drives w/o changing fstab someshpr Linux - General 7 03-15-2011 12:26 PM
detects but doesnt mount external hard drive : Weird system error in Konquerer emma_m Linux - Hardware 1 12-02-2009 02:27 PM
mounting external hard drive in /etc/fstab Micro420 Linux - Newbie 1 11-07-2006 06:12 AM
fstab hard drive mount eastj1974 Linux - Newbie 2 07-05-2003 03:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:54 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration