Page 1 of 1

[SOLVED] Harddrive Access As Root Only. Help!

Posted: Tue Sep 29, 2009 5:06 am
by jaqian
I have a dual boot system winXp & Mint7. I needed more space so I reduced the windows drive and took 30gig, formated as ext2. All grand except it seems I need to be in root to copy files to it.

Any idea how I can change this?

Cheers,
Rob

Re: Harddrive Access As Root Only. Help!

Posted: Tue Sep 29, 2009 5:51 am
by Husse
Show us your /etc/fstab

Re: Harddrive Access As Root Only. Help!

Posted: Tue Sep 29, 2009 6:35 am
by jaqian
Husse wrote:Show us your /etc/fstab
Here you go...

Code: Select all

# /etc/fstab: static file system information.
#
# Use 'vol_id --uuid' 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>
proc            /proc           proc    defaults        0       0
# / was on /dev/sda5 during installation UUID=6c29b7f2-cfcc-4af4-9c03-9d18cbaac384 /               ext3    relatime,errors=remount-ro 0       1
# swap was on /dev/sda6 during installation UUID=b2bc0f25-2178-4566-9a4b-1901055afc43 none            swap    sw              0       0 /dev/scd0       /media/cdrom0   udf,iso9660 user,noauto,exec,utf8 0       0

Re: Harddrive Access As Root Only. Help!

Posted: Tue Sep 29, 2009 7:55 am
by Husse
What kind of disk is it? Internal - external?
How do you copy?
I thought it was a partition on an internal disk but I can't see any trace of it in fstab
The only partition mentioned is sda5

Re: Harddrive Access As Root Only. Help!

Posted: Tue Sep 29, 2009 10:46 am
by jaqian
Its a partition on the windows C: drive. I know theres nothing on the fstab. It should show the existing Linux partition (think its ext3), the swap file and the new ext2 partition.

Re: Harddrive Access As Root Only. Help!

Posted: Wed Sep 30, 2009 4:14 am
by jaqian
On the Ubuntu forum someone told me to try:

Code: Select all

sudo chown -R myusername:myusername /media/sda3
I tried this using /dev/sda3 instead of /media as thats what partition editer says it is mounted at but it didn't work. Any suggestions where I go from here?

Re: Harddrive Access As Root Only. Help!

Posted: Wed Sep 30, 2009 6:10 pm
by Husse
Do you have more than one hard drive?

Re: Harddrive Access As Root Only. Help!

Posted: Wed Sep 30, 2009 6:52 pm
by jaqian
Husse wrote:Do you have more than one hard drive?
No its only one drive. They say a picture is worth a thousand words so this screenshot might explain it better...
Image

Re: Harddrive Access As Root Only. Help!

Posted: Thu Oct 01, 2009 6:26 am
by Husse
The partition ins not mentioned in fstab, but it can be mounted anyway
The first time you double click on it you will be asked for your password (sudo sort of) and you can tell the system that you don't want to use a password in the future
It is now not mounted by the "normal mount command"
Another way to do it to use fstab to mount the partition
As you are going to use it for your data you can mount it in home
Like this
Create a folder in /home/your_name/ called Data (or whatever you want)
Edit fstab

Code: Select all

/dev/sda3		/home/your_name/Data 	ext2	default	0	2
Edit must be done as root

Code: Select all

gksu gedit /etc/fstab
It will now appear as a normal folder in home

Re: Harddrive Access As Root Only. Help!

Posted: Fri Oct 02, 2009 1:31 pm
by jaqian
Thanks but it didn't work. I might just delete this partition and expand the existing Linux partition to take up its space.

Re: Harddrive Access As Root Only. Help!

Posted: Sat Oct 03, 2009 9:20 am
by Husse
The solution in my previous answer puts the partition in home and home is owned by you
There are no permissions for a partition as such, it will get the permissions of the folder it is mounted in - plus what the mount command says
Instead of default (hmm - maybe it should be defaults) use owner

Re: Harddrive Access As Root Only. Help!

Posted: Thu Oct 15, 2009 5:08 am
by jaqian
I re-installed mint as I had a few annoying problems so this is all sorted now.