Raspberry Pi--root user and sudo

Source: Internet
Author: User


The Linux operating system is a multi-user operating system that accepts multiple users to log on and use a single computer.

To protect the computer (and other users ' privacy). Users are limited in what they can do.


Most users agree to execute most of the programs on the computer and edit and save files stored in their own home folder. The general user does not agree to edit other users ' files and some system files.

However, there is a special user on the Linux system called Superuser, which often makes username root. This super user has no restrictions on the computer. Almost able to do all things.


Sudo


You typically do not log on to the computer as the root user, but you can use the sudo command to gain superuser privileges. Let's say you're logged in as a normal user, using a PI user for your login to the Raspberry Pi. You can add the sudo command before the program you want to execute to execute the program as the root user.


For example, if you want to install additional software on a Raspberry Pi, you usually need to use the apt-get tool. In order to update the list of available software, you need to include the sudo command prefix before the agt-get command:sudo apt-get update.


See a lot of other apt command information.


You can also use the sudo su command to execute a Super User shell terminal. Once the command is executed as Superuser, there is nothing to prevent the system from damaging the error. The equivalent of shutting down the security on the machine. Although this makes it easier to access things inside the system, the risk of damage is greater.

It is recommended that you execute commands as Superuser only when you need superuser privileges. Quit the Super User Shell terminal in a timely manner without the need for superuser privileges.


Who CAN use SUDO? (who can use sudo)


Assume that no matter what user can add sudo before the command. Security will be compromised. Therefore, only the user with the specified ability to use sudo to get the permissions of the computer administrator.

The PI user is already included in the sudoer file.

Allow other users to use Super user privileges. You can add these users to the sudo group, or use Visudo to join them.


Many other specific information please refer to user management.



Original address: Http://www.raspberrypi.org/documentation/linux/usage/root.md


Raspberry Pi--root user and sudo

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.