In this article, I will talk about the GNU Nano tool, user groups and administrator privileges in the command system.
The first thing you need to know is that you can basically use the Linux terminal with two different identities: administrator and user. With the user ID, you can only access files in your home directory. The Admin ID puts the entire system at your disposal. To switch from the user console to the admin console, you need to issue the su command. It will ask you for the administrator password you entered while installing Pardus. To exit the admin console and return to the user, you need to issue the exit command. I do not recommend using the console as an administrator. For this reason, I will explain how you can issue administrator-authorized commands with the user ID. We will use the sudo tool for this. First of all, you should know what the GNU Nano tool is, one of the cornerstones of the Linux console.
The most user-friendly of text editors running from the console. I will only mention its simple usage. If you want to know all the features man page read.
To make it work
nano dosya_konumu command is used (For example:
nano /etc/X11/xorg.conf). When you want to create a file, enter a command with nano as if you were opening a file (For example:
nano ~/yeni_dosya) and write whatever you want in it and save it. See the shortcuts below for file save, exit, and page navigation.
- F3: registration
- F2: Log out
- Ctrl+V: Next page
- Ctrl+Y: Previous page
Now that we have removed Nano, we can move on to user authorizations. I explained the difference between administrator and user above, now I will explain how you can issue commands from the user account with administrator privileges. There are two ways to this:
- wheel grubwith u
- with visudo file
Wheel grubThe easiest way, made by arranging the flour. All you have to do is wheel your user grubtake it to you. For this to this document You can browse.
Visudo is the name of the tool that gives users instant administrative privileges. You can make that command an administrator by typing sudo at the beginning of your command. For example, I gave above
nano /etc/X11/xorg.conf if given with user privileges xorg.conf file is opened as read-only because it is outside the user's home directory. But command
sudo nano /etc/X11/xorg.conf as per sudo If you enter it, the command will be processed with administrator privileges and xorg.conf opens as writable.
After that, handle all your operations in the console from your user console by obtaining instant privileges with the sudo command when necessary. You must of course give your user permission to use sudo before using sudo. As I explained above, wheel your user. grubYou can do it by adding it to it, or you can directly give permission by manipulating the visudo file. For this, first
su Switch to the admin console with the command and open the visudo file with the following command:
EDITOR = nano visudo
In the file that opens, find the following section:
#User privilege specification root ALL=(ALL) ALL
There, a bottom line of root,
kullanıcı_adı ALL=(ALL) ALL Add the line and save and exit. Now your user can use the sudo command. If the wheel grubOf course, you don't have to do this if you're a member.