How To Install GeoIP on CentOS 7
Introduction
In this tutorial we learn how to install GeoIP
on CentOS 7.
What is GeoIP
GeoIP is a C library that enables the user to find the country that any IP address or hostname originates from. It uses a file based database that is accurate as of June 2007 and can optionally be updated on a weekly basis by installing the GeoIP-update package. This database simply contains IP blocks as keys, and countries as values. This database should be more complete and accurate than using reverse DNS lookups. This package includes GeoLite data created by MaxMind, available from http GeoIP is a C library that enables the user to find the country that any IP address or hostname originates from. It uses a file based database that is accurate as of June 2007 and can optionally be updated on a weekly basis by installing the GeoIP-update package. This database simply contains IP blocks as keys, and countries as values. This database should be more complete and accurate than using reverse DNS lookups. This package includes GeoLite data created by MaxMind, available from http
We can use yum
or dnf
to install GeoIP
on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install GeoIP.
Install GeoIP on CentOS 7 Using yum
Update yum database with yum
using the following command.
After updating yum database, We can install GeoIP
using yum
by running the following command:
Install GeoIP on CentOS 7 Using dnf
If you don’t have dnf installed you can install DNF on CentOS 7 first.
Update yum database with dnf
using the following command.
After updating yum database, We can install GeoIP
using dnf
by running the following command:
How To Uninstall GeoIP on CentOS 7
To uninstall only the GeoIP
package we can use the following command:
References
Summary
In this tutorial we learn how to install GeoIP
on CentOS 7 using yum
and dnf
.