How To Install glpk on Rocky Linux 8

In this tutorial we learn how to install glpk on Rocky Linux 8. glpk is GNU Linear Programming Kit

Introduction

In this tutorial we learn how to install glpk on Rocky Linux 8.

What is glpk

The GLPK (GNU Linear Programming Kit) package is intended for solving large-scale linear programming (LP), mixed integer programming (MIP), and other related problems. It is a set of routines written in ANSI C and organized in the form of a callable library. GLPK supports the GNU MathProg language, which is a subset of the AMPL language. The GLPK package includes the following main components * Revised simplex method. * Primal-dual interior point method. * Branch-and-bound method. * Translator for GNU MathProg. * Application program interface (API). * Stand-alone LP/MIP solver.

We can use yum or dnf to install glpk on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install glpk.

Install glpk on Rocky Linux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install glpk using dnf by running the following command:

sudo dnf -y install glpk

Install glpk on Rocky Linux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install glpk using yum by running the following command:

sudo yum -y install glpk

How To Uninstall glpk on Rocky Linux 8

To uninstall only the glpk package we can use the following command:

sudo dnf remove glpk

glpk Package Contents on Rocky Linux 8

/usr/lib/.build-id
/usr/lib/.build-id/45
/usr/lib/.build-id/45/778222b16964e89e5d27b05314390b7e36378a
/usr/lib64/libglpk.so.40
/usr/lib64/libglpk.so.40.3.0
/usr/share/doc/glpk
/usr/share/doc/glpk/README
/usr/share/licenses/glpk
/usr/share/licenses/glpk/COPYING

References

Summary

In this tutorial we learn how to install glpk on Rocky Linux 8 using yum and dnf.