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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
09-09-2014, 06:44 PM
|
#1
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Rep:
|
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.
|
|
|
09-09-2014, 08:09 PM
|
#2
|
Senior Member
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora/Pop!_OS
Posts: 2,983
|
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.
|
|
|
09-09-2014, 08:29 PM
|
#3
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
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
|
|
|
09-09-2014, 09:46 PM
|
#4
|
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
|
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.
|
|
|
09-09-2014, 10:08 PM
|
#5
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243
|
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.
|
|
|
09-10-2014, 12:09 AM
|
#6
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
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.
|
|
|
09-10-2014, 08:59 AM
|
#7
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243
|
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.
|
|
|
09-10-2014, 12:40 PM
|
#8
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
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.
|
|
|
09-10-2014, 04:47 PM
|
#9
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243
|
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?
|
|
|
09-11-2014, 02:31 AM
|
#10
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
the 930g drive is an external storage drive. my internal boot drive is a 320g drive.
|
|
|
09-11-2014, 09:11 AM
|
#11
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243
|
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.
|
|
|
09-12-2014, 02:43 AM
|
#12
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
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?
|
|
|
09-12-2014, 10:11 AM
|
#13
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,243
|
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.
|
|
|
09-16-2014, 01:31 PM
|
#14
|
LQ Newbie
Registered: Dec 2008
Posts: 16
Original Poster
Rep:
|
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
|
|
|
09-18-2014, 07:38 AM
|
#15
|
Member
Registered: May 2005
Location: Fareham, UK
Distribution: HP-UX 11i, Fedora, Ubuntu, Debian, RHEL, OEL, CentOS
Posts: 75
Rep:
|
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.
|
|
|
All times are GMT -5. The time now is 08:54 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|