OPERATING SYSTEMSOS Linux

#Ubuntu file structor

Installing Software, and exploring the file structure.

3 Task

1. Installing an application
2. Overview of directories
3. Exploring Config files

1. Installing an application

Midnight Commander is a console application with a text user interface, if you are new to an ubuntu server this may help you navigate the file system by giving you a visual interface.
A task that as a system administrator you will be navigating the file system pretty regularly.

First, you will need to install it. Since we don’t know what the package name is we can use the apt search command to find it.

:~$ apt search “midnight commander”

It found ‘mc’ as the name of the package.

Now run the apt install command to install it.

:~$ sudo apt install mc

apt will read the package lists and find the dependencies needed to install.

You will be asked if you want to continue.

Once it is installed we will open it by using the command

:~$ mc

2. Overview of directories
# /root # /home # /sbin # /etc # /var/log

Ok now let’s open the Linux Programmer’s Manual and see the official definitions for the file structure
:~$ man hier

Here you will find the description of the filesystem hierarchy.

/ – This is the root directory
/bin – contains executable programs
/etc – contains configurations files that are local to the machine
site-wide configuration files may be placed here or in /usr/etc
programs should always look for these files in /etc
/home – home directories for users
/sbin – holds commands needed to boot the system, but which are usually not executed by normal users.
/var/log – Miscellaneous log files.

3. Exploring config files.
Let’s view a configuration file.

less /etc/ssh/sshd_config

There are parameters, sshd server system-wide configuration file, PATH=/usr/bin:
port 22, address

Now lets ls the etc file
ls /etc/

You will see a lot of .conf and .cfg. They are configuration files

It is important as a system administrator to be familiar with the configuration files and be able to read what they say.

source

ubuntu