How To Install php-pecl-geoip on Fedora 36

In this tutorial we learn how to install php-pecl-geoip in Fedora 36. php-pecl-geoip is Extension to map IP addresses to geographic places

Introduction

In this tutorial we learn how to install php-pecl-geoip on Fedora 36.

What is php-pecl-geoip

This PHP extension allows you to find the location of an IP address City, State, Country, Longitude, Latitude, and other information as all, such as ISP and connection type. It makes use of Maxminds geoip database

We can use yum or dnf to install php-pecl-geoip on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install php-pecl-geoip.

Install php-pecl-geoip on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install php-pecl-geoip using dnf by running the following command:

sudo dnf -y install php-pecl-geoip

Install php-pecl-geoip on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install php-pecl-geoip using yum by running the following command:

sudo yum -y install php-pecl-geoip

How To Uninstall php-pecl-geoip on Fedora 36

To uninstall only the php-pecl-geoip package we can use the following command:

sudo dnf remove php-pecl-geoip

php-pecl-geoip Package Contents on Fedora 36

/etc/php.d/40-geoip.ini
/usr/lib/.build-id
/usr/lib/.build-id/ad
/usr/lib/.build-id/ad/18d345cea0bd2a8582f61745e79fac46dac332
/usr/lib64/php/modules/geoip.so
/usr/share/doc/pecl/geoip
/usr/share/doc/pecl/geoip/ChangeLog
/usr/share/doc/pecl/geoip/README
/usr/share/licenses/php-pecl-geoip
/usr/share/licenses/php-pecl-geoip/LICENSE
/var/lib/php/peclxml/php-pecl-geoip.xml

References

Summary

In this tutorial we learn how to install php-pecl-geoip on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).