Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [root]

The name of the main administrative user commonly used in *nix based systems.

385
votes
7answers
468k views

What is the “You have new mail” message in Linux/UNIX?

Sometimes, when I log into a box and 'su' to root, I get a cute little message saying I have mail (thank GOD it's not AOL). Where is this mail? What does it contain? Who/What sent it? How important ...
288
votes
9answers
287k views

chown is not changing symbolic link

I'm trying to change the user/group of a symbolic link with the command: $ chown -h myuser:mygroup mysymbolic/ But it's not changing. I'm logged in as root. The current user/group is set to root:...
87
votes
2answers
16k views

Why is the most powerful user on a Unix/Linux system called “root?”

Somewhat inspired by this other question on the use of the term “Super User”, why the heck is the most powerful user on a Unix/Linux system called root? Why not admin, sysop, base, king or something ...
55
votes
2answers
6k views

Where did the term “superuser” originate?

Where did the term "superuser" originate? Is it a shortening of "supervisory user", or is it just an indicator of the level of power one such user holds in a system?
52
votes
3answers
125k views

Force logout a user

I When I logged into the machine as root and typed who to see which users are logged in, I found somebody else too logged in as root devuser pts/0 2011-11-18 09:55 (xxx.xxx.xxx.xxx) root ...
45
votes
2answers
65k views

Can I create an SSH user which can access only certain directory?

I have a Virtual Private Server which I can connect to using SSH with my root account, being able to execute any linux command and access all the disk area, obviously. I would like to create another ...
43
votes
5answers
28k views

Sudo vs root; any actual differences?

I'm working with a support member for a product, and he insists that I need to be root to install a series of patches, and that sudo won't work; he doesn't provide a reason but seems very firm in his ...
40
votes
3answers
80k views

Does the root account always have UID/GID 0?

On all the Linux systems I've managed, the root account has a GID and UID of 0. Is this guaranteed, or is it possible that the system will give root a different ID?
33
votes
5answers
89k views

How to check root partition with fsck?

I installed Linux Mint 12 KDE, and I would like to check the root partition for any errors. How do I check the root partition with fsck at boot time?
30
votes
5answers
46k views

How do I run a launchd command as root

I have the following launchctl command as a .plist file. It's loaded and set to run once a day but, it needs to run as root and I'm not sure how to verify this. Also, this cron job basically CDs ...
27
votes
2answers
59k views

Can I make a script always execute as root?

How to make a script execute as root, no matter who executes it? I read about setuid but I'm not sure how to do this. I'm using Linux, Ubuntu 12.04 LTS.
27
votes
6answers
74k views

Where's .bashrc for root?

I know it's not best practice, but on my dev system I login as root. What's the equivalent of the .bashrc file so I can alias some functions? I've found the /etc/bash.bashrc & /etc/bash.bashrc....
26
votes
4answers
44k views

How to determine the user and group of a deamon in Ubuntu?

How can I check the user and group for the nginx daemon in Ubuntu? Or what's the syntax to find the user and group for a deamon running in Ubuntu?
26
votes
4answers
24k views

removing write permission does not prevent root from writing to the file

I just noticed on my Ubuntu machine (ext3 filesystem) that removing write permissions from a file does not keep root from writing to it. Is this a general rule of UNIX file permissions? Or specific ...
25
votes
4answers
2k views

Why is it possible to change the password of an admin user on linux?

A few days ago, a friend of mine, wanted to show me that he can use my linux even if I don't tell him my password. He entered in GRUB, selected the recovery mode option. My first problem is that he ...
25
votes
9answers
184k views

User not in the sudoers file. This incident will be reported

I need to install a package. For that I need root access. However the system says that I am not in sudoers file. When trying to edit one, it complains alike! How am I supposed to add myself to the ...
22
votes
5answers
30k views

How do I make sudo ask for the root password?

When I run sudo as a normal unprivileged user, it asks for my password, not the root password. That's often convenient, but it reduces the amount of information someone would have to have in order to ...
17
votes
2answers
1k views

Is PermitRootLogin based on UID or user name?

The man page states that PermitRootLogin Specifies whether root can log in using ssh(1). However, it is not clear if this check is based on the user name ("root") or the UID (0). What happens if ...
17
votes
3answers
61k views

Creating files and directories with a certain owner (user/group) while sudoing

I need to wget something (results in a compressed file in cwd), then I have to extract it, then do some copy/move/modification stuff and perhaps finally execute an script (from the downloaded archive)....
15
votes
5answers
56k views

Synology DSM - Can't log as root (but works with admin)

After some automatic updates (or being hacked ?) I have many things broken and a huge problem to resolve them since I can't login as root anymore. ssh admin : login success su root : permission ...
15
votes
3answers
17k views

How can I install DropBox without root privileges?

Is it possible to install Dropbox without root privileges in Linux? I've tried to install it at my university, using the sources found here, but I seem to need to enter the root password (which of ...
15
votes
3answers
21k views

UNIX - mount: only root can do that

I need to allow a non-root user to mount/unmount a device. I am a total noob when it comes to UNIX, so please dumb it down for me. I've been looking all over teh interwebz to find an answer and it ...
15
votes
4answers
66k views

Set password for root on virtualbox ubuntu

I loaded ubuntu into virtualbox. It all works well but it occurred to me that I was not asked (or did not setup) a root password. I want to use root on occasion, but I cannot seem to find out how to ...
14
votes
6answers
29k views

What is different between root and sudo?

A root user can have all the privileges. But a normal user can gain access like a root with su or sudo command and their own password. So what's the difference?
13
votes
5answers
20k views

DDoS Virus infection (as a unix service) on a Debian 8 VM Webserver

I maintain a (fully updated) Wordpress for a student team on a Virtual Machine on ~okeanos service for a couple of years. Today, the helpdesk informed me that i am conducting DDoS attacks, which - of ...
13
votes
4answers
15k views

Can't install Parallels Tools on Debian 7.2.0

(Parallels Desktop 9, latest version) As per instructions, I switch to root: $ su - root $ whoami root $ echo $EUID 0 and then execute the installer: $ cd /media/cdrom0 $ ./install and I get this ...
10
votes
3answers
15k views

apt-get update not working: Signing/ Verification errors

When I run apt-get update I get Ign:1 http://dl.google.com/linux/musicmanager/deb stable InRelease Ign:2 http://archive-4.kali.org/kali kali-rolling InRelease Hit:3 http://archive-4....
9
votes
7answers
26k views

How to run a program as root without “sudo”?

I have a certain binary program on OS X that can only be run as root. I'm tired of prepending sudo each time I invoke it and typing the password, and would like it to automatically run as root when I ...
9
votes
3answers
45k views

CentOS 6.5 - bash: service: command not found

So I can't type service on my CentOS 6.5 server. I'm logged in as root. When typing service I get this error: bash: service: command not found I have also tried to type sudo service, but with no ...
9
votes
4answers
16k views

SSH key associated with root directory

In OSX (Linux), how do I get to the SSH keys with my root directory?
9
votes
1answer
2k views

Debian - allow user to be root only for specific commands

We have several Linux boxes running Samba that are used 'locally', eg each branch gets their own Samba box to store and share files. The office managers need to be able to add and remove users for ...
9
votes
7answers
2k views

Why is it bad to run as root?

I've often come across posts on forums or other websites where you see people joking in such a manner about running/logging in as root as if it's something awful and everyone ought to know about it. ...
8
votes
4answers
19k views

Restoring a SD card after using it to root a device

I recently purchased the Nook Touch reading device. I rooted it using the instructions on nookdevs.com Rooting included using win32diskimager to somehow transfer an .img file onto the card. Rooting ...
8
votes
2answers
4k views

sudo command trying to search for hostname

Recently, I have changed the sudoers file and the hostname through /etc/hostname. After changing this files, my sudo command is taking a lot of time. Also, it says sudo unable to resolve host kaagini(...
8
votes
4answers
4k views

Concern over running WireShark as root

I started WireShark on my Ubuntu machine and discovered that there were no interfaces I could listen to. So I launched it as root. This gave me access to all the interfaces, but gave me a warning: ...
7
votes
2answers
3k views

Why is the dreadful 'rm -rf /' even allowed? [closed]

We all know the destructive power of the following command executed as root: rm -rf / Related questions: How far will you get with an 'rm -rf /' command? deleting everything: # rm -rf / I ...
7
votes
4answers
4k views

Ubuntu: Accidentally changed root user to nonexistent shell

I tried to change my user's shell, but used "sudo chsh", and changed the root shell to "bash" instead of "/bin/bash". Now when I try to change it I get "chsh: PAM authentication failed" and it seems ...
7
votes
3answers
9k views

I just ran rm /* accidentally, any fix?

I fell so stupid... I just ran rm /* accidentally, but I meant rm ./* on a cloud server with root access. Now, no one command works. ls, ssh, sftp... none. Is there a way to fix that? (Note: params ...
7
votes
4answers
52k views

How to log in as root in linux shell?

How to login as root in linux shell?
7
votes
2answers
17k views

Are root password changes logged?

Long story short, after a recent company "reorg" the root password on all of our servers was mysteriously changed. I need to figure out first how to regain root access, but second how to figure out ...
7
votes
2answers
2k views

How to open a file in ranger as root?

How do I open a file in the file-manager "ranger" with superuser rights? While ":open_with vim" opens the file as none root with vim, I am looking for something like ":open_with sudo vim", but that ...
7
votes
2answers
2k views

Why should I really disable root ssh login?

I always read I should disable root login for SSH and login with a user which has sudo. But where is the difference between: ssh root@vps and ssh myuser@vps sudo -i I don't have physical access ...
7
votes
3answers
6k views

Adjusting $PATH in /etc/profile does not affect root

I added a directory to PATH in /etc/profile. This works for my user account but not for root. It's easy to add it to my /root/.bashrc but I would like to understand what's wrong. It's a mostly ...
7
votes
2answers
5k views

Specify root dir inside tarball

Is there a way to execute tar cjvf foo.tar.bz2 project-root Such that when the tarball is extracted, it doesn't extract to project-root, but instead extracts to something else? i.e. tar xjvf foo....
7
votes
1answer
4k views

I believe I've deleted MySQL root user, how do I recreate it?

I'm running ISPConfig on CentOS and I don't know how, but I don't seem to have a root mysql user. I can stop mysqld with /etc/init.d/mysqld stop Start it again and skip grant tables mysqld_safe --...
7
votes
3answers
15k views

How do I install python with proper permissions?

So python installed probably fine. Or perhaps it was already on here (I'm using xubuntu 12.10). But I tried to install networkx today using pip: pip install networkx then says I don't have ...
6
votes
2answers
3k views

How can I pass Root Password to a script

I have the root password in one of my scripts and I want to launch another script which requires root permission from this script. How can I use the root password which I have so that I do not have to ...
6
votes
3answers
4k views

Use another user's .vimrc and .vim/

I know that I can :source /path/to/some/.vimrc to load my user's .vimrc when running as root, but how can I use the entire .vim/ directory as well? Is there a startup option for using /home/user/.vim/ ...
6
votes
2answers
1k views

Potential issues with adding /usr/local/[s]bin to root's path?

I've noticed that the root account $PATH does not include /usr/local/bin or /usr/local/sbin by default. Are there any potential issues that could arise from adding those directories to the path? If so,...
6
votes
7answers
23k views

How can I find out which user logged in as root?

We have a couple of servers which are managed by a large group of admins. They usually log in as service users (say hudson) and then switch to root to make some small fix. This means we often can't ...