LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-02-2002, 06:22 AM   #1
evil_lafta
LQ Newbie
 
Registered: Dec 2002
Location: nigeria
Distribution: slackware 8.1
Posts: 12

Rep: Reputation: 0
root privileges and permissions


i found out that whenever i 'su', i can't run my own apps unless i exit. for instance if i wanted to gedit a config file, after i 'su' and run gedit i get:

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Gtk-WARNING **: cannot open display: :0.0

i use slackware 8.1/win2k.

Also, i have a fat partition which i use to swap files between linux and windows. as a normal user i can't copy to or edit files in my fat partition unless i'm root. i tried chmod but the permissions did not change!
i would like to be able to have read-write access to my fat as a normal user just like i did when running mandrake 7.x
 
Old 12-02-2002, 07:20 AM   #2
Excalibur
Senior Member
 
Registered: Jun 2002
Location: Northern VA, USA
Distribution: Ubuntu
Posts: 1,180

Rep: Reputation: 46
Not being able to run/edit, etc. another users files or programs would be considered normal in Linux because of security.

To mount your FAT partition for everybody to read/write/delete you have to tell the system when the file system is mounted to allow it. Use a mask to set the access bits. Try to modify your fstab mount entry point to include the option something like below:

/dev/hda3 /fat vfat users,noauto,umask=000 0 0

Change above what you need for your system of course. But the main new item is the umask setting.

Cheers!

Last edited by Excalibur; 12-02-2002 at 07:22 AM.
 
Old 12-02-2002, 07:32 AM   #3
pesho_p
Member
 
Registered: Oct 2002
Location: 42° 42' N, 23° 19' E
Distribution: Slackware 8.1
Posts: 77

Rep: Reputation: 15
Quote:
i found out that whenever i 'su', i can't run my own apps unless i exit. for instance if i wanted to gedit a config file, after i 'su' and run gedit i get:

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Gtk-WARNING **: cannot open display: :0.0
Try "$ su -" instead of just "$ su"

Quote:
Also, i have a fat partition which i use to swap files between linux and windows. as a normal user i can't copy to or edit files in my fat partition unless i'm root. i tried chmod but the permissions did not change!
i would like to be able to have read-write access to my fat as a normal user just like i did when running mandrake 7.x
Add something similar to your /etc/fstab:
#filesystem mount-point fs-type options dump fsck-order
/dev/hdaX /mnt/dos vfat defaults,rw,user 0 0

Replace "user" with "users" if you want to allow anyone to unmount the partition. If you don't want this live it this way ("user").
For more info "$ man 5 fstab"
 
Old 12-02-2002, 07:51 AM   #4
vladkrack
Member
 
Registered: Oct 2002
Location: Curitiba - Brazil
Distribution: Conectiva
Posts: 334

Rep: Reputation: 30
Re: root privileges and permissions

Quote:
Originally posted by evil_lafta
[B]i found out that whenever i 'su', i can't run my own apps unless i exit. for instance if i wanted to gedit a config file, after i 'su' and run gedit i get:

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Gtk-WARNING **: cannot open display: :0.0
The message says that don't have permisson to open your X display, so before exec the command, you will need with your user give access to your X:

# xhost +

and to direct your variable as root:

# export DISPLAY=:0

Hope that helps ...
 
Old 01-25-2003, 03:11 PM   #5
sRock258
LQ Newbie
 
Registered: Jan 2003
Posts: 1

Rep: Reputation: 0
I found this thread pretty helpfull, but did not completely fix my problem. I am mounting a vfat partition to share files between zp and redhat 8.0. I could not allow non-root users to write to this partition. I tried both methods proposed by vladkrack and pesho_p respectibly. Both methods allowed write access for non-root users, but I can not change the user or group of this partition. So the user is still listed as root, but my user does have write access.

My fstab entry is this:

/dev/hdf1 /home/Sean/media vfat defaults,rw,users 0 0

Thanks for any help.

Sean
 
Old 01-25-2003, 03:32 PM   #6
Darin
Senior Member
 
Registered: Jan 2003
Location: Portland, OR USA
Distribution: Slackware, SLAX, Gentoo, RH/Fedora
Posts: 1,024

Rep: Reputation: 45
Quote:
Originally posted by Excalibur
...But the main new item is the umask setting.
 
Old 01-27-2003, 06:22 AM   #7
evil_lafta
LQ Newbie
 
Registered: Dec 2002
Location: nigeria
Distribution: slackware 8.1
Posts: 12

Original Poster
Rep: Reputation: 0
yeah. add umask=000 to the vfat line
 
Old 08-20-2003, 09:37 PM   #8
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Rep: Reputation: 15
you might also try mounting the drive manually with

# mount -o umask=0000 /dev/hda1 /home/Sean/media
 
  


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
USB HD Needs Root Privileges rrrssssss Linux - Hardware 3 11-13-2005 04:08 PM
Root privileges for user ar1 Linux - Security 2 01-07-2005 09:33 PM
How to mount without root privileges? ni0wn Slackware 3 09-15-2004 05:03 PM
User with root privileges ShakyJake Linux - Newbie 2 06-18-2004 12:12 PM
Xine and root privileges markus1982 Linux - Software 1 08-18-2003 03:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 08:15 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