Results 1 to 9 of 9
|
Enjoy an ad free experience by logging in. Not a member yet? Register.
|
|
-
11-07-2006 #1
- Join Date
- Oct 2006
- Posts
- 30
how to build a power user in mandriva 2007 ? a user with root access...
thank you for reading my post.
how i can build a power user in mandriva , i mean a user that can copy / delete / edit files in other folders like /etc , /var and .....
my user can not edit even a conf file and i should use root login or use su to perform those tasks which i think is a tiduse task .
is there any way to make my current user a root or power user ?
I tried and add all groups that was avaiable in user administration GUI application to my user but it has no effect.
thanks
-
11-07-2006 #2
Well, using "su" is exactly what you are supposed to do. If you give a normal user all privileges, then its fairly easy to make mistakes that could serious damage your Linux installation. Anyway you could look into using sudo or putting yourself into the wheel group (although personally I wouldn't recommend this since it can cause security issues).
-
11-07-2006 #3
- Join Date
- Nov 2006
- Posts
- 45
Disclaimer:
If you screw up your system not my fault. The system is designed not to allow a normal user to add/modify/remove system files. It is designed that way for a purpose and you should learn to use it in that manner.
Answer:
Manually change your UID to 0 which is root. Or just login as root all the time since that's what you want anyways.
-
11-07-2006 #4
- Join Date
- Oct 2006
- Posts
- 30
Thank you all for your reply.
can you tell me how i can change my UID ?@Number33
Please tell me the steps as i am new to linux.
Thanks
-
11-07-2006 #5
- Join Date
- Nov 2006
- Posts
- 45
Hesitant....
Originally Posted by legolas
From a terminal do the following:
Method 1:
1) su -
2) edit /etc/passwd (use vi or whatever you prefer)
3) Change the UID of your user. The 3rd field is uid the 4th is gid. change them both to 0
4) Save the file
5) Re-login as your user now with root power
Method 2:
Use usermod to change your uid
1) su -
2) execute "usermod -o -u 0 -g 0 <username>
Disclaimer:
I do not agree with the reasoning of this task, but it may turn out to be a learning experience for someone.... after they have to re-load their system.
-
11-07-2006 #6
I really wouldn't do that. The correct answer is do not grant someone root access. Even in the Windows world this is frowned upon by any experience administrators. What you need to do is define what it is they need to be able to do, and specifically grant those permissions. At the expense of just sounding stubborn, it is a really bad idea to have root access when not needed. Root on a Unix system is a lot more access than say an administrator account on Windows.
If you really are set on doing this you may as well just log in as root, as attempting anything else is effectively the same.Last edited by bigtomrodney; 11-07-2006 at 07:54 PM.
-
11-08-2006 #7
- Join Date
- Oct 2006
- Posts
- 30
Hi
thank you for the solutions.
I tried the second solution and it said :
[root@SAL10000 legolas]# usermod -o -u 0 -g 0 legolas
Usage: usermod [-u uid [-o]] [-g group] [[-G group,...] [-a]]
[-d home [-m]] [-s shell] [-c comment] [-l new_name]
[-f inactive] [-e expire] [-p passwd] [-L|-U] name
I tried and changed your command to :
[root@SAL10000 legolas]# usermod -u 0 -g 0 legolas
usermod: uid 0 is not unique
and it return the above error , can you please tell me how to fix it ?
thanks
-
11-08-2006 #8
- Join Date
- Nov 2006
- Posts
- 45
man usermod
-
11-08-2006 #9
The problem isn't your usage of the command, it's the fact that you already have a user with UID 0, it's root. If you want another user to be root with all the will in the world all you will do is remove root and replace it with another user who will then be root. This is pretty futile, if you want a user to have root privelage just let them log in as root. To give them root privelage is opening your system to all sorts of risk from both a security and stability point of view.
As I mentioned already, what you should be doing is deciding what the user needs, and granting permission for those actions.