Creating a new user

If you don't have a regular user account yet, then you need to create one. You have to be root to do this.

[root@localhost root]# adduser user1 (user1 is the actual user name)

Now set the password for user1 (give your user1 a password).

[root@localhost root]# passwd user1 (granting user1 a password)

New UNIX password: type the password for user1 hereRetype the password:

If the password is a dictionary word you will receive a bad password warning, you can still use it, but keep in mind that it is a very weak password (easy to crack). Retype it for the system to finish setting the password. When the password is accepted you will receive the following message: all authentication tokens updated successfully.

Well you just created a new user, which is the beginning of system administration. From now on, you should login as your regular user and every time when you need administrative privileges you just switch to it. So logout now, and re-login as regular user.

Working as normal user

Your prompt should be now:

[user1@localhost user1]$

At your command line you can execute almost anything, but some commands will not be available to you as a regular user unless you become super-user or root.

Anyway let's try some basic commands so you know what they do in case you need them.

[user1@localhost user1]$ ls

The ls command lists the current directory, you can use it with several switches: –R recursive, -S sort by file size, -l use long listing format, -a all.

For more switches type man ls at your command prompt to view the manual. After scrolling down the manual press “Q” to quit the manual.

[user1@localhost user1]$ cd /home

The cd command is used to move between directories. Notice the forward slash it is very important in Linux.

[user1@localhost user1]$ cp

cp [OPTION] SOURCE DESTINATION

The cp command is used for copying, useful to move and for backing up small portions of files. You can only copy files where you have permission.

[user1@localhost user1]$ mkdir mywork

The mkdir command is used to create directories. You can only create a directory in places where you have permission to do so. By default you have permission to write and delete in your home directory. If you become a super user, you can write anywhere you want. Be organized!

Become a super user

While logged in as a regular user, you might temporarily need root's privileges in order to do something that only root can do. You don't have to logout to gain this power.

[user1@localhost user1]$ su

At your prompt type su, that will ask you for a password. That password is root's password, type it and hit enter.

Now your prompt should look like this:

[root@localhost user1]#

Note inside the brackets says root, and now you have root's power to do anything you want.