How to Find php.ini File in Ubuntu?

By Hardik Savani November 5, 2023 Category : Ubuntu

Hi Folks,

Here, I will show you how to work how to find php.ini file in ubuntu. you will learn how to get php.ini file in ubuntu. In this article, we will implement a how to get php.ini file path in ubuntu. This post will give you a simple example of ubuntu php.ini file location.

There are two commands to find the location of your php.ini file in ubuntu. we will use php -i | grep php.ini and php --ini commands to get php.ini file path in ubuntu.

You can use this command with your ubuntu 22.10, ubuntu 22.04, ubuntu 21.10, ubuntu 21.04, ubuntu 20.04, ubuntu 18.04 and ubuntu 16.04 server.

Example 1:


php -i | grep php.ini


Example 2:


php --ini


I hope it can help you...

Tags :