How to install CentOS 8 minimum server

How to install CentOS 8 minimum server

This document describes the installation of the CentOS 8 server. The purpose of this guide is to provide a minimal setup that can be used as the basis for other tutorials in this article, such as the complete server guide or SAMBA, LAMP, and LEMP server guides, such as howtoforge.

Claim

To start installing CentOS 8, we will need the installer ISO file. This can be CentOS minimum ISO or DVD ISO file. If you plan to install only one server and then choose a smaller minimum ISO, the installer will download the required packages during the subsequent installation process. I will install multiple servers on CentOS 8, so I chose the DVD installer ISO, so I don’t have to download the same package again for each server.

I will install it on the VMware virtual machine. The installation steps on the physical server are the same. If your server fails to boot from the ISO file, burn the ISO on the DVD, and then insert it into the DVD drive of the server.

Preliminary notes

This tutorial is based on the CentOS 8 server. In this tutorial, I use 192.168.0.100 as the IP address and host1.example.com as the host name. These settings may vary depending on you, so you must replace them where appropriate.

Install CentOS 8 basic system

Boot from your CentOS 8 ISO image. Choose to install CentOS 8.

Next press ENTER.

Boot from system image

Choose the installation language. I use English with American English here, so I just press continue:

Choose a language

Next, we get the following screen:

CentOS installer overview

I will customize the settings starting from LOCALIZATION in DATE & TIME. Click DATE & TIME. Choose your time zone, as far as I am concerned, I choose “Europe” as the “region” and Berlin After finishing as a city, press Finish.

Select time zoneIt sets the server DATE&TIME to the European/Berlin time zone. Next, I will customize the keyboard layout, click keyboard Start the setup dialog.Go to keyboard layout settings.

Press the + icon to add another keyboard layout:

Add another keyboard layout

It will display the following window and a list of available keyboard layouts. In my case, I select German and click Add. Button to add keyboard layout.

Add German keyboard layout on CentOS 8

Next, we customize the “Layout Switching” option by pressing “Options”:

Layout switching

You can use any key combination to switch between the keyboards. In this example, I used Alt + Ctrl. After selecting the desired key combination, press Finish.

Custom layout switching options.

Then press Finish.

Layout switching

Now, if you don’t want to use English, we can add language support. Click “Language Support” to open the dialog box.

Multi-language support

By default, CentOS is pre-installed with English, but we can easily add more languages. In my case, I want to add Deutsch German and Deutsch (Deutschland) as additional languages. After selection, press Finish

Add other languages ​​in CentOS

Next, we go to SOFTWARE> INSTALLATION SOURCE and select the installation media.

Go to the software installation menu

Next, you will see that the installation source is “automatically detected installation media”. If you have other installation sources (such as a network installation), you can set the path in the “on the network” field, whether it is used or not Proxy is established. In addition, we can add other repositories if needed. Then press Finish.

Select installation source

Next, we will proceed to “Software Selection”, which has a minimum installation option by default.

Software selection menu

If needed, we can add more packages (when you use the installation DVD instead of the minimal installer). In my case, I only need the minimum installation (basic function) settings to install the software with yum in the future, so I will save the settings by pressing Done.

How to install CentOS 8 minimum serverAdd other packages here

We move to SYSTEM and select the installation destination.

Installation destination

When you need a manual partitioning scheme, you can choose “I will configure the partition”. In my case, I prefer to configure the partition automatically after “Done”.

Choose CentOS installation target

Next, we will customize the network and host name by selecting it.

Configure the network in CentOS

I will use the host name server1.example.com and customize the Ethernet settings by pressing configuration.

Set Hostname

The next screen will look like this, now we add IPv4 settings by selecting. If you have IPv6, add it to “IPv6 Settings”.

Network card details

Next, you can set up the network to match your local network settings. In my case, I use a static IP, so I will choose “Manual”

Set IPv4 mode to manual

Add entries for address, netmask and gateway according to your static IP environment. In my case, the address I use is 192.168.0.100, the netmask is 255.255.255.0, the gateway is 192.168.0.1, and the DNS server is 8.8.8.8 8.8.4.4 These values ​​may vary depending on your network environment . After that, press save.

Configure IPv4 details

important: If you do not have an IPv6 internet connection, please set automatic IPv6 to “Ignore” on the IPv6 tab, otherwise you will not be able to access the Internet on IPv4 through this server, because CentOS seems to ignore the correct IPv4 settings and use IPv6 Failed.

IPv6 settings

Next, we must open the connection, as shown in the following figure. Press further to complete.

Connect Network

Set the server host name in the “Host Name” field, and then click the “Apply” button.

Set the correct host name

Now that we are ready to start the installation process, you may need to cross-check all the settings and then press to start the installation.

Start installing CentOS 8

The installation process will start immediately, and a small blue progress bar will be displayed in the next window. Now we must set “ROOT PASSWORD” and add a new non-root user in the USER CREATION option. I will first enter the root password.

Configure user and password while installing CentOS

Enter the security code of your choice and press Finish

Choose a secure root password

Next, we will proceed to USER CREATION.

User created

Next, I will create a non-root user because I use the full name “Howtoforge” and the user name “howtoforge”, select the option Require the password to use this account, and then press Done. Of course, you should use the username and password of your choice.

Add new users on CentOS 8

Press Finish. Please be patient and wait for the installation to complete.

After the installation is complete, it will ask to reboot the server, just press “Finish Configuration”.

Reboot

The server restarts, and then you will be asked to enter your username and password.

CentOS 8 starts for the first time

Now, we can log in with the user we just created above, or we can use root credentials.

First login on CentOS 8

Log in to the server as the root user so that we can perform some final installation steps.

Log in to CentOS 8 for the first time

The first is to use dnf to install all available updates.

dnf update

Click “y” to confirm to continue installing the update.

I will install two command line editors to be able to edit the configuration file on the shell:

dnf install nano vim

Network Configuration

CentOS 8 minimal does not have the ifconfig command pre-installed, we will install it as follows:

yum install net-tools

If you want to change or view the network configuration file, just edit the file

nano /etc/sysconfig/network-scripts/ifcfg-ens33

When you configure a static IP address, it will look like this:

TYPE="Ethernet"BOOTPROTO="none"DEFROUTE="yes"IPV4_FAILURE_FATAL="no"IPV6INIT="no"IPV6_AUTOCONF="yes"IPV6_DEFROUTE="yes"IPV6_PEERDNS="yes"IPV6_PEERROUTES="yes"IPV6_FAILURE_FATAL="no"IPV6_ADDR_GEN_MODE="stable-privacy"NAME="ens33"UUID="233f2c1b-877c-4b28-b17d-1eb091ded288"DEVICE="ens33"ONBOOT="yes"IPADDR="192.168.0.100"PREFIX="24"GATEWAY="192.168.0.1"DNS1="8.8.8.8"

Or when using DHCP as follows:

TYPE="Ethernet"BOOTPROTO="dhcp"DEFROUTE="yes"IPV4_FAILURE_FATAL="no"IPV6INIT="yes"IPV6_AUTOCONF="yes"IPV6_DEFROUTE="yes"IPV6_FAILURE_FATAL="no"NAME="ens33"UUID="233f2c1b-877c-4b28-b17d-1eb091ded288"DEVICE="ens33"ONBOOT="yes"HWADDR="00:50:56:15:23:79"PEERDNS="yes"PEERROUTES="yes"IPV6_PEERDNS="yes"IPV6_PEERROUTES="yes"IPV6_PRIVACY="no"

If necessary, change the value.

Note: The above DEVICE names may be different, so please check the equivalent files in the directory /etc/sysconfig/network-scripts.

Adjust /etc/hosts

Adjust the file /etc/hosts as follows:

nano /etc/hosts

Make the value as follows:

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
192.168.0.100   server1.example.com     server1

::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
    

Congratulations! Now that we have the basic minimum CentOS 8 server settings, we have laid a solid foundation for our other tutorials.

Download the CentOS 8 server as a virtual machine

This setting can be downloaded as a virtual machine in ova/ovf format (compatible with VMWare and Virtualbox) for use by howtoforge subscribers.

VM login details

  • The root password is: howtoforge
  • The password of the “howtoforge” user is: howtoforge

Please change both passwords when logging in for the first time.

  • The IP address of the virtual machine is 192.168.0.100
Sidebar