LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
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 06-10-2009, 04:53 PM   #1
prometheusracer
Member
 
Registered: Dec 2006
Location: Southampton, UK
Distribution: Mint 7, running on a 1.6GHz centrino duo, 2048MB, 80GB, NVidia 7300 512MB laptop
Posts: 30

Rep: Reputation: 15
Partitions don't mount properly for a user, but a remount by root fixes things.


A strange problem this...

I've got an 80G internal drive, and one 160G and one 1T external drives split into a few partitions - The internal carries a windows partition and / , the 160G external carries /home/<username> (yep, not just /home - I sometimes need the machine when the external drives aren't connected - its a laptop, so I've got a 'mobile' user who's home is in the internal drive), and the 1T external carries several partitions that are mounted inside /home/<user>. Some of these are fat, some are ext3. fstab lists the /home/<user> mount just after / and swap (before the other partitions)

The problem - Booting up the machine, and logging on to my <user>, no errors are produced, everything seems fine, and the external drives are shown as mounted. Unfortunately, opening the drives (or rather, their mount points) in nautilus, the terminal, or anything just shows a completely empty folder. Writeable to, but with no contents. (each partition does contain significant amounts of data - music, photos, films etc). Trying to dismount the partitions fails with the message 'the partition is not mounted'. Gparted sees the partitions as mounted, but fails to dismount with the same message. 'sudo umount <dev...>' fails too.

However, logging in as root, I can dismount the drives, remount them, and all is fine - returning to <user>, the partitions/mount points have the data in them.

All the external partitions are being affected, including my $home. This causes interesting problems with .files and settings...

Any ideas?
 
Old 06-11-2009, 10:25 AM   #2
headrift
Member
 
Registered: Sep 2005
Distribution: Gentoo, Sabayon, Puppy, Arch
Posts: 165

Rep: Reputation: 29
My suggestion to you is, rather than mounting things under /home/<user> mount the partitions under /mnt/<stuff> and then have symlinks in /home/<user> -- the partitions in /mnt could have the "users" option in fstab, as well as "noauto".

Then, when you log in, put some script into .bashrc to check for the external drives and mount them if present... as <user>.

Yes, it's more complicated, but that's what I'd do. *shrug*

...all that said, you might be able to keep it the way it is by just adding the "users" to your fstab options for those partitions.

[edit]

Are you saying that /home/<user> and /home/<username> are different partitions? That would make mounting /home/<username> more interesting.

Last edited by headrift; 06-11-2009 at 10:31 AM. Reason: Original post re-read
 
Old 06-11-2009, 11:42 AM   #3
prometheusracer
Member
 
Registered: Dec 2006
Location: Southampton, UK
Distribution: Mint 7, running on a 1.6GHz centrino duo, 2048MB, 80GB, NVidia 7300 512MB laptop
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by headrift View Post
My suggestion to you is, rather than mounting things under /home/<user> mount the partitions under /mnt/<stuff> and then have symlinks in /home/<user> -- the partitions in /mnt could have the "users" option in fstab, as well as "noauto".
Yeah, but its messy :P ...and besides, my $home isn't mounting properly either.

Quote:
Originally Posted by headrift View Post
Then, when you log in, put some script into .bashrc to check for the external drives and mount them if present... as <user>.
I can't remount the drives as me, even using sudo. I have to actually log in as root and do it.

Quote:
Originally Posted by headrift View Post
...all that said, you might be able to keep it the way it is by just adding the "users" to your fstab options for those partitions.
Yup, 'users' is there. I'm really not sure what's going on.

Quote:
Originally Posted by headrift View Post
Are you saying that /home/<user> and /home/<username> are different partitions? That would make mounting /home/<username> more interesting.
Ah, yeah. <username> should be <user> there. Sorry.

Tell you what, here's my fstab, if that helps visualise my setup:
Code:
# <file system> 				<mount point>   	<type>  	<options>       				<dump>  <pass>
proc            				/proc           	proc    	defaults        				0       0
# / was on /dev/sda5 during installation
UUID=ff2f56bd-a554-41dd-96cb-25291bf567a5 	/               	ext4    	relatime,errors=remount-ro 			0       1
# /home was on /dev/sda6 during installation	
UUID=e6c9b7f5-e435-4d31-9369-d84ee7b3d7fd 	/home	          	ext4    	relatime        				0       0
# swap was on /dev/sda2 during installation
UUID=39bf46ec-9a3d-41b0-b9f3-e63bcb3fb0b3 	none            	swap    	sw              				0       0
#oldhome
UUID=6738a758-7ae1-4862-8d6b-a475f79c8633	/home/matt		ext3		users,auto,relatime,exec			0	0
#cd-rom
/dev/scd0       				/media/cdrom0   	udf,iso9660 	users,noauto,exec,utf8 				0       0
# /dev/sdb2
UUID=ba1ef585-9161-43b8-bf09-722f38194849 	/Scenery        	ext3    	users,auto,relatime,exec        		0       0
# /dev/sdc6
UUID=6df45b15-641a-4b74-a661-52407bffa793 	/home/matt/External 	ext3    	users,auto,relatime,exec       			0       0
# /dev/sdc3
UUID=4926-A0DC  				/home/matt/Films 	vfat    	users,auto,utf8,umask=0000,gid=46 		0       0
# /dev/sdc2
UUID=4926-A0D9  				/home/matt/Music 	vfat    	users,auto,utf8,umask=0000,gid=46 		0       0
# /dev/sdc1
UUID=4926-A0D7  				/home/matt/Pictures 	vfat    	users,auto,utf8,umask=0000,gid=46 		0       0
# /dev/sdc5
UUID=3cf834e7-010b-4372-bd4c-cd53af7df71f 	/home/matt/Videos 	ext3    	users,auto,relatime        			0       0
# /dev/sda1
UUID=58B40B19B40AF970 				/windows        	ntfs    	users,auto,defaults,umask=007,gid=46 		0       0
#X Plane
/home/matt/External/ISOs/avd-xp9.iso		/mnt/xplane		udf,iso9660	users,auto,loop,exec,utf8			0	0
Edit: In fact, why the fudge does /windows and /scenery mount, but none of the others?! (heh, and that xplane.iso) Is there anything filesystem-error-wise that'll make things appear to mount but not actually mount? Without errors? pfft. I unno.

Last edited by prometheusracer; 06-11-2009 at 11:44 AM. Reason: further mindfcukery
 
Old 06-11-2009, 03:02 PM   #4
headrift
Member
 
Registered: Sep 2005
Distribution: Gentoo, Sabayon, Puppy, Arch
Posts: 165

Rep: Reputation: 29
Oookay.

So /home/matt isn't mounting right. Gotcha.

...that's what it sounds like, anyway. Something up the chain from ~/External isn't happening, but /home is. So, it's /home/matt. I'd say that for some reason the external drives are being attached before /home/matt is done mounting, meaning your externals are mounted, but "under" what gets mounted later, making it look to the system that they're mounted, even though they're "orphaned".

I'd try changing the five partitions after /home/matt to "noauto" and then do what I said with a bit of script in .bashrc -- should be easy enough, I can put up the lines of script if you need me to.

Oh, and you realize you have mounts running three levels deep there, right? And my suggestion is messy?
 
Old 06-11-2009, 03:48 PM   #5
prometheusracer
Member
 
Registered: Dec 2006
Location: Southampton, UK
Distribution: Mint 7, running on a 1.6GHz centrino duo, 2048MB, 80GB, NVidia 7300 512MB laptop
Posts: 30

Original Poster
Rep: Reputation: 15
Yeah, that's what I thought at first. Well, it threw up errors that ~/External....~/Videos weren't mounting (no mount points, but /home/matt was there, just empty). I created the mount points in that partition anyway, so they'd mount to those even if /home/matt didn't mount... unno.

I tried the noauto flags, and changed the mountpoints to somewhere directly under / , but they still failed in the same way. (I didn't put the commands in .bashrc, just ran them from the terminal. Should be the same, shouldn't it?)

Yeah, well, when its working, it looks clean :P


Edit:

Ah ha! In /var/log/messages, I've got:

Code:
Jun 11 20:50:53 mattop kernel: [   82.722568] EXT3-fs warning (device sdc1): dx_probe: dx entry: limit != root limit
Jun 11 20:50:53 mattop kernel: [   82.722575] EXT3-fs warning (device sdc1): dx_probe: Corrupt dir inode 2, running e2fsck is recommended.
repeated many many times for sdc1 only. Hmmm... so that's probably not the issue then... meh, fsck it is anyways.

Last edited by prometheusracer; 06-11-2009 at 03:56 PM.
 
  


Reply



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
How to give not-root user ability to mount devices to any mount point??? jdupre Linux - General 8 02-04-2012 10:03 AM
Where to mount multiple root partitions? dacotre Linux - Newbie 20 08-01-2007 12:27 PM
How to properly mount NTFS partitions please help!!! Roni_G Ubuntu 11 06-06-2007 04:15 PM
help please: mount -t smbfs -a fails as normal user, as root, doesn't mount anything thevic Linux - Networking 11 04-09-2007 03:09 AM
mount and r/w partitions in non-root Alfexy Slackware 2 10-21-2004 03:49 PM

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

All times are GMT -5. The time now is 08:11 PM.

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