Help! Linux! (Compact)

You’re a traditional Windows user? This strange black box has just popped up and you’ve got no idea what to do now? First of all – don’t panic. On your Revolution Pi, you’ve also got the chance to change to a graphic user interface.

You won’t quite get around not having to occupying yourself a little with the Linux terminal.

In this chapter, we will explain a few basics about Linux. You will also find out how you can change to a graphic user interface.

A look at the roots

Linux was developed as a multi-user system. Originally various users worked on a Linux system who were managed by an administrator (user: root).

The Linux file system is structured accordingly. Linux saves files in a file directory tree. It begins with a root directory /(rootfs).

File Contents
/ The root directory is at the very top of the hierarchy.
/bin Programmes that every user can use e.g Shells.
/boot All the files necessary to boot the system.
/dev Device files that are used as an interface to hardware. You can find entries here for all hard disks and their partitions.
/etc Configuration files that contain the programme settings or basic system information.
/home Home directory for all users. A separate file has to be set up for every user that is comparable with “My Documents” on Windows. Every user has full access rights.
/lib The system’s function libraries. Don’t change anything here!
/proc Interface to the kernel. Every current programme is listed in a sub-directory. These files contain information about the latest programme status. There is additionally a directory structure with data about the kernel and the system hardware.
/root The home directory for the system administrator (root). It lies on the root directory so that the system administrator can also access his files whenever a fault makes it impossible to access other partitions.
/sbin Programmes of the system administrator.
/tmp Temporary place for files.
/usr Installed software
/var Status information of the various programmes. Log files are good for searching for errors.
/opt (optional software) Commercial software or very big programmes that don’t directly belong to the system like for example KDE, Firefox usw.

User administration

When you log on your RevPi Compact, you are automatically in your home directory as User pi@RevPi. You will recognise it by the symbol ~ after your user name. In your home directory, you have the full access rights to all your files. Here is where you can archive and administer for example documents, videos or audio files.

You however need system administrator rights for some functions. An example is the shutting down the RevPi Compact.

By entering the command shutdown -h 0 as User pi@RevPi you will be shown an error message. Only the user “root” (system administrator) has the right to shut down the system. There is a historical background to the command. Linux was developed in a time when computers were still very expensive and several users had to share the system. To make sure a user isn’t able to shut down the system mistakenly and prematurely end the work of others, it was only the right of the system administrator.

In contrast to windows, as you in Linux are allowed to alter all the files and therefore completely destroy your system, in many cases it is sensible to limit the rights of the user.

You naturally don’t have to leave your RevPi Compact on for the whole time.

PLEASE NOTE
DON’T pull the power supply plug to turn the device off. If the system is writing data at the time on the eMMC storage, it may lead in rare cases to the eMMC storage’s filing system being destroyed thus even making it impossible to boot the system.

In the following section, we will describe how to shut RevPi Compact down properly.

Sudo-the magical formula

sudo

By writing sudo before your command, you will be given system adminstrator rights for the specific command.

You can thus access, for example, system data, install programmes and for instance using “sudo shutdown –h 0” shut down your RevPi Compact properly.

Tip!Save your data before doing anything of a critical nature to your system. You can find out how to do it in the chapter titled “Save image and install”.

If you’d like to get better acquainted with Linux, we recommend you visit the following website: http://www.selflinux.org/

Are you now of the opinion that you would like to have as little to do with Linux terminal as possible? No problem, here’s how you get to the user interface:

    • Log on your RevPi Compact (info is written on the sticker on the side of your RevPi Compact)
    • Enter “startx” in the command line.

You can now start working on the graphical user interface.