LinuxQuestions.org
Register a domain and help support LQ
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 06-14-2002, 10:31 AM   #16
toob
LQ Newbie
 
Registered: Jun 2002
Distribution: Red Hat 8
Posts: 25

Original Poster
Rep: Reputation: 15

Okay, I have no problem using the mount command in the startup when logged in as root. But when logged in with my regular ID, when I used the same command in the startup, I get this error when trying to transfer files: "Cannot create target file "/mnt/hdb7/fabric_brown1c.png" Permission denied (13)"
Is there some command I need to put in addition to the mount command in the startup that gives it temporary root permissions or something? Because even after I added this startup command to mount the drive and then logged out and back in again, I still get that error (but only in my regular ID -- it works fine in root).
 
Old 06-14-2002, 11:41 AM   #17
Sfin
Member
 
Registered: Apr 2002
Location: Michigan
Distribution: Slackware 8.0
Posts: 197

Rep: Reputation: 30
I am assuming when you say in your post that you got the partition to automount at startup, that you mean that you edited the

/etc/fstab

file and added a line there to have the parition mount on startup.

Well when you mount a paritition on startup, the default owner of it will be root, so you won't have the right to write to that partition. There are two ways that I know of to be able to write to the fat partition.

1) add a umask value at the end of the fstab line that mounts you window partition:

ex.

/dev/hda7 /mnt/hda7 defaults,umask=0000 0 0

that will change the permission of the mount to

rwxrwxrwx

so now everyone has access to write and read to the partition, when it is automounted.

2) Here we change the owner of the partition. so the same line we used above, just add a uid=<your uid, which is a number> or a gid=<gid number>.

/dev/hda7 /mnt/hda7 defaults,uid=<your user id> 0 0

your uid can be found in the /etc/passwd file.

ex.
Sfin:x:1001:100:Sfin:/home/Sfin:/bin/bash
|_UID

the 1001 is your UID. The 100 is your GID

Last edited by Sfin; 06-14-2002 at 11:42 AM.
 
Old 06-15-2002, 12:18 PM   #18
toob
LQ Newbie
 
Registered: Jun 2002
Distribution: Red Hat 8
Posts: 25

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by Sfin
[B]I am assuming when you say in your post that you got the partition to automount at startup, that you mean that you edited the

/etc/fstab

file and added a line there to have the parition mount on startup.
Hi Sfin,

I actually used Gnome's Control Center (I'm still quite addicted to GUIs) and added the automount command in the Startup section in there.

I located my uid and added it to my automount command -- logged in not as root but as my regular user self -- so it looks like this:

mount /dev/hdb7 -t vfat /mnt/hdb7 defaults,uid=500

But I still get the "cannot create target file. . . permission denied" error.

Now, the UID 500 was the number listed -- should it be 50 and not 500? I see you eliminated the last '1' from 1001 to make your UID 100.
 
Old 06-16-2002, 05:23 PM   #19
Sfin
Member
 
Registered: Apr 2002
Location: Michigan
Distribution: Slackware 8.0
Posts: 197

Rep: Reputation: 30
The 100 that I listed was my GID, and 1001 was my UID.

check the properties of the /mnt/hda7, and see if it actually set you as the owner.

What you posted should work, but try ading a umask=0000 after the uid=500, and see if that helps.

Also it might be a better idea to add the line that I had in my first post to your /etc/fstab file, because that is how you should automount partitions.

Last edited by Sfin; 06-16-2002 at 05:26 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
Windows/Linux Fat32 Share partition problem Halsafar Linux - General 1 09-23-2005 08:17 PM
How can I create a Fat32 Windows share partition on my RH9 install(dual boot w/XP) andrewc Linux - Newbie 1 07-21-2004 09:28 AM
How can I share a fat32 partition? fabre Mandriva 7 06-10-2004 04:16 AM
Want to share a fat32 partition over a LAN el_pajaro! Linux - Networking 5 02-06-2004 03:02 PM
Win2K sees linux, no access to share suselinux Linux - Networking 3 09-06-2001 03:19 PM


All times are GMT -5. The time now is 02:29 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration