Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Where is the php.ini file in Ubuntu hardy?

The file found in path called /etc/php5/apache2/php.ini.ucf-dist.

Do I need to rename file 'php.ini.ucf-dist' to 'php.ini'?

Where is the system currently reading the php information when I run info.php file?

I tried to compare one item what gets displayed when I run info.php file and when I edit the 'php.ini.ucf-dist' file. The 'memory_limit' shows 128M when I run info.php file but in the 'php.ini.ucf-dist' file it is set to 16M. So this cant be the same file being read by the system currently?

Thanks for help.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

Running phpinfo(); will tell you which php.ini file is loaded. For example, mine says:

Loaded Configuration File: /etc/php5/apache2/php.ini

share|improve this answer
    
This is the preferred way since it tells you which php.ini your system is actually using. The locate or whereis command is also your friend in situations like this... –  voretaq7 May 13 '10 at 15:58

Try renaming file to:

/etc/php5/apache2/php.ini

If your info.php is working you can search for 'Loaded Configuration File' and there will be path to file from which php module is reading options.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.