pgAdmin4 is a client application used for managing PostgreSQL servers graphically. It is available as a desktop application for Linux desktop systems as well as a web application. Which provides a beautiful and easy-to-use web interface and helps us to increase productivity. This article will help you to install the PostgreSQL server on Fedora 34/33 Linux system. Also, provide you the instructions to install pgAdmin4 on the Fedora system. This article has been tested with the Fedora version 34.

Step 1 – Installing PostgreSQL on Fedora

Follow the below instructions to install the PostgreSQL server on a Fedora system.

  1. First of all, search for the available DNF modules contains the PostgreSQL server packages. Open a terminal and type the below command:

  2. In the above command, you will see the available PostgreSQL versions. Now enable the repository of the required version. The below command will enable the repository for the PostgreSQL 13 on your system.

  3. Once you have successfully enabled the required DNF module. Use the following command to install the PostgreSQL server packages using DNF package manager. This will also install additional required packages on your system. Press ‘y’ to confirm and finish the packages installation.

  4. After that, you need to initialize the PostgreSQL data directory. In other words, this will create a data directory and other configuration files on your system. To initialize the database server, type:

After finishing the above command, the PostgreSQL server installation is completed on your Fedora system. PostgreSQL server uses PGDATA environment variable to contain the data directory location.

Setp 2 – Manage PostgreSQL Service

To start the PostgreSQL service use the following command as per your operating systems. Also, enable the PostgreSQL service to autostart on system boot. You can see the current status of the service using the following command.

Step 3 – Secure Postgres User

After completing the above steps. Your PostgreSQL 11 server is ready to use. Log in to the postfix instance to verify the connection. You may create a strong password for the “postgres” account to enhance server security.

Step 4 – Installing pgAdmin4 on Fedora

The pgAdmin4 is a great tool for managing PostgreSQL server databases with a graphical interface. It is available as an application for desktop systems. Also, a web version is available to access in a web browser. The below steps will help you to set pgAdmin4 on your Fedora system.

  1. First, configure the pgAdmin4 repository to your Fedora system. In a terminal execute the following command.

  2. After that, install the pgadmin4-web package on your system. This will also add other dependencies to your system.

  3. The policycoreutils-python-utils package contains the management tools use to manage an SELinux environment for the Python applications. Install it on your system with the following command.

  4. Finally, run a shell script to configure the pgAdmin4 on your system. This will prompt for an email address and password to enable web application authentication.

Remember that, this authentication is just for login to the pgAdmin4 dashboard. It can’t be used to log in to the PostgreSQL server.

Step 5 – Allow Public Access to pgAdmin4

The Fedora systems use a firewall to protect the server from external users. You need to allow access on port 80 to access pgAdmin4 from outside of the server. To open web port in firewall, type: As the Fedora system has default SELinux in enforcing mode, you need to apply SELinux setting to allow network access to the webserver. In the end, restart the Apache service to reload all the settings and changes.

Step 6 – Access pgAdmin4

Now, you can access the pgAdmin4 web application in a web browser. Access your server with the IP address following with /pgadmin4 http(s)://server-ip/pgadmin4

Enter login credentials created in the above step. After a successful login, you will get access to the pgAdmin4 dashboard. Here you can connect multiple PostgreSQL servers and manage them.

Conclusion

In conclusion, You have successfully installed the PostgreSQL server on the Fedora Linux system. Additionally, provides you instructions to install the pgAdmin4 dashboard to manage the PostgreSQL server graphically.

How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 40How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 16How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 50How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 97How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 11How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 2How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 76How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 60How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 81How To Install PostgreSQL and pgAdmin4 in Fedora 35 34   TecAdmin - 28