Note: This step explains the directory structure for a Linux environment. You might skip it once this is a theoretical step. Click the button below to show.

In the Linux environment, there is the notion of absolute or full path and relative path. See the following directory structure:

Sample directory structure

There are some notations for describing a directory path:

/ is the root directory. All absolute paths start with /

/ is also the directory separator

. denotes the current or present directory

.. denotes the parent directory, relative to the current directory

~ is the home directory. For the Toradex modules, it is always the /home/root directory.

The full path points to a location in a file system without depending on the current directory. The picture below presents the absolute paths for the previously presented directory structure:

Absolute paths

The relative path points to a location in a file system relative to the current path. The picture below presents the relative paths for the previously presented directory structure, considering /home/root the present directory:

To search for a file that has a specific text as content, you can use the grep command. Grep is useful not only for file contents search, but also as a filter to the output of other commands, for instance.

#search for files containing the "hello world" string in the current directory

There are two relevant date/time clocks in Linux: the hardware date/time, usually referred to as real-time clock (RTC) and the system date/time. While the command timedatectl takes care of synchronizing both of them, usually the date command is used to get the system time, due to its simpler output.

The hwclock command is commonly used in systems that don't have a program such as timedatectl to synchronize the system and hardware clocks.

You should see a screen similar to the one presented in the figure below:

Htop overview

It presents system status and statistics, such as: CPU and RAM usage (the pre-built images have swap disabled by default); system tasks; load average and; uptime. Below the overall status, all of the system tasks are listed, as well as their individual resources usage and other relevant information.