Switching to Linux. Network and system settings

In this series, we provide an overview of the fundamentals to help you successfully migrate to Linux from another operating system. If you missed the previous articles in the series, you can find them here:

Part 1 – Introduction

Part 2 – Disks, Files, and File Systems

Part 3 – Graphical environment

Part 4 – Command Line

Part 5 – Using sudo

Part 6 – Installing the Software

Linux gives you a lot of control over your network and system settings. On your desktop, Linux lets you customize just about anything on your system. Most of these settings appear in text files in the / etc directory. Here we describe some of the most common settings that you will use on your Linux desktop.

Many settings can be found in the program’s settings, and the options available depend on the Linux distribution. You can usually change the background, adjust the sound volume, connect to printers, customize displays, etc. While we won’t talk about all the settings here, you can of course explore on your own.

Connect to the Internet

Connecting to the Internet on Linux is pretty straightforward. If you are connected via an Ethernet cable, Linux usually obtains an IP address and automatically connects when the cable is plugged in, or at startup if the cable is already plugged in.

If you are using wireless, most distributions have a menu, either on the indicator panel or in the settings (depending on your distribution), where you can choose the SSID for your wireless network. If the network is password protected, it usually asks for the password. After that, it connects and the process is pretty smooth.

You can configure the network settings in a graphical environment by going to settings. This is sometimes referred to as “System Settings” or “Settings”. Often, you can easily identify a customization program because its icon is a gear or a toolbox (Figure 1).

Network interface names

In Linux, network devices are named. Historically, they were given names such as eth0 and wlan0, or Ethernet and wireless, respectively. Newer Linux systems use different names that look more esoteric, such as enp4s0 and wlp5s0. If the name starts with en, it is a wired Ethernet interface. If it starts with wl, it is a wireless interface. The rest of the letters and numbers reflect how the device is connected to the equipment.

Network management from the command line

If you want more control over your network settings or manage your network connections without a graphical desktop, you can also manage your network from the command line.

Note that the most common service used to manage graphical desktop networks is Network Manager, and Network Manager often overrides changes made to the command line. If you are using Network Manager, it is best to change the settings in your interface so that it does not undo changes you made on the command line or elsewhere.

Changing settings in a graphical environment will most likely interact with Network Manager, and you can also change Network Manager settings from the command line using the nmtui tool. The nmtui tool provides all the options you find in a graphical environment, but gives it in a text-based semi-graphical interface that runs on the command line (Figure 2).

Figure 2. The nmtui interface

The command line has an old tool called ifconfig for managing networks and a newer one called ip. On some distributions ifconfig is deprecated and not even installed by default. Other distributions still use ifconfig.

Process and system information

On Windows, you can go to Task Manager to see a list of all running programs and services. You can also stop running programs. And you can view the system performance in some of the tabs displayed there.

You can do similar things in Linux from both the command line and graphical tools. There are several graphical tools available on Linux, depending on your distribution. The most common are System Monitor or KSysGuard. In these tools, you can see system performance, view a list of processes, and even kill processes (Figure 3).

Figure 3. Screenshot from NetHogs.

In these tools, you can also view the global network traffic on your system (Figure 4).

Figure 4. Screenshot of Gnome System Monitor.

Process control and system use

There are also several tools that you can use from the command line. The ps command can be used to display the processes on your system. By default, it will display the processes running in the current terminal session. But you can list other processes by giving it various command line parameters. You can get more help on ps with the commands info ps, or man ps.

Most people want to get a list of processes because they would like to stop one that is using too much memory or CPU time. In this case, there are two commands to make this task easier. These are top and htop (Figure 5).

Figure 5. Screenshot above.

The top and htop tools are very similar to each other. These commands update their list for one or two seconds and rebuild the list so that the task using the most CPU is at the top. You can also change the sort with other resources like memory usage.

In either of these programs (top and htop), you can type ‘?’ get help, and “q” quit. You can press “k” to kill the process, and then enter the unique PID number for the process to kill it.

With htop, you can highlight a task by pressing the down arrow or up arrow to move the highlighted bar and then press F9 to kill the task and then Enter to confirm.

The information and tools presented in this series will help you get started with Linux. With a little time and patience, you will feel right at home.

Please disable your ad blocker or whitelist this site!

Related Posts