Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Permissions, the group "root", emerge as non root
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
schmeggahead
Guru
Guru


Joined: 25 Feb 2003
Posts: 314
Location: Columbus, Ohio

PostPosted: Sun Dec 21, 2008 4:51 pm    Post subject: Permissions, the group "root", emerge as non root Reply with quote

OK, no matter how long I look at gentoo, I still feel like a beginner. :wink:

For instance, I just found the Documentation section in the kernel directory - so now some of that wizardry of the how to documentation was obtained. :oops:

But I digress, so here's what feels like a couple of newbie questions:

What is a good use of the group "root"?

What can I do with emerge when I am not root?

I spend a great deal of time installing and tweaking my systems which puts me into root more often. Can I do some of this tweaking without being root?

and if there is a doc source or category that covers this, please enlighten the unenlightened. :oops:

Thanks
Back to top
View user's profile Send private message
Sadako
Advocate
Advocate


Joined: 05 Aug 2004
Posts: 3792
Location: sleeping in the bathtub

PostPosted: Sun Dec 21, 2008 6:56 pm    Post subject: Reply with quote

I've never seen the root group used before, and can't really think of any good use for it.
The way I see it, all files on your system must belong to both a user and a group, so it's best to just make all the system files belong to the "root" group, which no user is actually a member of.

If you're a member of the portage group you can use emerge with --pretend and --search, basically anything which doesn't involve altering anything on the system (ie essentially operating portage in "read only").

There is a reason you need to be root to alter system settings, and if a non-root user can alter anything system wide then something is wrong...

Not sure how relevant it is to what you're asking, but if you add "userfetch usersandbox userpriv" to the FEATURES variable within make.conf, then a lot of the work done by portage is done without root privileges.
Check `emerge --info`, some of them may already be set by default.
_________________
"You have to invite me in"
Back to top
View user's profile Send private message
lightvhawk0
Guru
Guru


Joined: 07 Nov 2003
Posts: 388

PostPosted: Sun Dec 21, 2008 7:32 pm    Post subject: Reply with quote

vim .bashrc
Code:
alias emerge="sudo emerge"


You can use sudo as a regular user for the majority of your "tweaking", except for echo commands.
_________________
If God has made us in his image, we have returned him the favor. - Voltaire
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5956

PostPosted: Sun Dec 21, 2008 9:57 pm    Post subject: Reply with quote

Moved from Off the Wall to Networking & Security.
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017
Back to top
View user's profile Send private message
schmeggahead
Guru
Guru


Joined: 25 Feb 2003
Posts: 314
Location: Columbus, Ohio

PostPosted: Thu Dec 25, 2008 8:23 pm    Post subject: Reply with quote

Thanks all for the tips.

I am starting to create an infrastructure to capture the information about each of the machines I bring up on gentoo and it falls into place to use a regular user to capture that information and use it to update the system using the alias for emerge. I also thought to help with convenience, I would create an alias for nanoo as sudo nano to help with editing control files.

Will report back with further infrastructure details.
Back to top
View user's profile Send private message
Slippery Jim
Apprentice
Apprentice


Joined: 08 Jan 2005
Posts: 295

PostPosted: Thu Feb 26, 2009 12:33 am    Post subject: Reply with quote

This might be related a related topic. I've been messing with the ROOT environment variable, to install experimental gentoo trees into a subdirectory of my home directory. So far, I've been doing this as root, because portage won't let me install as a regular user. Since I own my home directory, it seems like I should be able to tell portage to let me do it, but I've never been able to figure out how. make.conf has a FEATURES variable called fakeroot that is supposed to affect the ebuild command, but I can't find anything else that documents it, and it doesn't seem to make a difference to emerge. Any thoughts?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum