Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 13th April 2011, 12:57
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default which php.ini's get applied

I know there are different php.ini's inside /etc/php5/etc /etc/php5/cli /etc/php5/cgi

but now I checked the settings for a particular client and found he was using different values. So I found out he was using this php.ini /var/www/conf/web1/php.ini which seems to have been generated because I added some Custom php.ini settings when I configured his site in ispcfg3

to me it seems when I created his site, a php.ini was copied to /var/www/conf/web1/php.ini and the Custom php.ini settings were added to this php.ini.

My problem is that later on I changed the default php.ini i.e. /etc/php5/cgi - is this the one used by FastCGI? but he h
still had the old copy inside /var/www/conf/web1/php.ini - now which one takes precedence? How can I update his local copy to my updated one?

Sorry for the long confusing thread but can someone shed some light onto how this works please?
Reply With Quote
Sponsored Links
  #2  
Old 13th April 2011, 13:06
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default

added an example: http://zice.ro/info.php

see the line: max_execution_time 30 ?

now both php.ini's:
/etc/php5/cgi/php.ini and
/var/www/conf/web1/php.ini

have this value: max_execution_time = 60

now where does the 30 come from?
Please, need urgent help with this. there are some more settings I do not knwo where they come from :-(

have a look:

h1870666:/var/www/knightsenglish.com/web/wp-content/plugins/mailpress# grep -R -i 'max_execution_time' /etc/php5/
/etc/php5/cgi/php.ini:max_execution_time = 60
/etc/php5/apache2/php.ini:max_execution_time = 60
/etc/php5/cli/php.ini:max_execution_time = 60
h1870666:/var/www/knightsenglish.com/web/wp-content/plugins/mailpress# grep -R -i 'max_execution_time' /var/www/conf/web1/
/var/www/conf/web1/php.ini:max_execution_time = 60
h1870666:/var/www/knightsenglish.com/web/wp-content/plugins/mailpress#


where does this come from?

Last edited by Ovidiu; 13th April 2011 at 13:09.
Reply With Quote
  #3  
Old 13th April 2011, 15:20
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default

this has jsut become extremely urgent!

it seems my setting of: display_errors = OFF

is now also being ignored and my sites have errors all over them :-(

Please help!
Reply With Quote
  #4  
Old 13th April 2011, 16:55
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Quote:
but now I checked the settings for a particular client and found he was using different values. So I found out he was using this php.ini /var/www/conf/web1/php.ini which seems to have been generated because I added some Custom php.ini settings when I configured his site in ispcfg3
correct.

Quote:
now which one takes precedence?
/var/www/conf/web1/php.ini

Quote:
How can I update his local copy to my updated one?
Change a value in the custom php.ini settings and click on save.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
Ovidiu (13th April 2011)
  #5  
Old 13th April 2011, 17:07
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default

thx Till, I understand all that now but please have a look at my second post: http://howtoforge.com/forums/showpos...55&postcount=2

the value that shows up is nowhere in my php.ini files !?

The point is hte problem could have been there for a while, I just realized it today as I did a /etc/ini.t/apache force-reload
oh, I rememebred: one of hte last changes I did, a whiel ago was add these: /etc/squirrelmail:/usr/share/squirrelmail:/usr/share/xcache/admin:/var/www/piwik to the custom PHP open_basedir - that shouldn't matter with this problem surely?
Reply With Quote
  #6  
Old 13th April 2011, 17:11
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Create a php file which contains the phpinfo() function. It will tell you which php.ini files are used for this website. If the website uses mod_php, then the settings can be also in a .htaccess file inside the website root.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #7  
Old 13th April 2011, 17:12
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default

sorry it seems I forgot to post the link: http://zice.ro/info.php

that all doesn't make sense without this link...
Reply With Quote
  #8  
Old 13th April 2011, 17:13
Ovidiu Ovidiu is offline
Senior Member
 
Join Date: Sep 2005
Posts: 1,269
Thanks: 84
Thanked 25 Times in 21 Posts
Default

ahhhh, it all works now after I followed your advice of:
Quote:
Change a value in the custom php.ini settings and click on save.
THANKS!

I don't understand what happened but all is good now.
Reply With Quote
  #9  
Old 13th April 2011, 17:13
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Here are the files that you have to check:

Configuration File (php.ini) Path /etc/php5/cgi
Loaded Configuration File /var/www/conf/web1/php.ini
Scan this dir for additional .ini files /etc/php5/cgi/conf.d
Additional .ini files parsed /etc/php5/cgi/conf.d/curl.ini, /etc/php5/cgi/conf.d/gd.ini, /etc/php5/cgi/conf.d/imagick.ini, /etc/php5/cgi/conf.d/imap.ini, /etc/php5/cgi/conf.d/mcrypt.ini, /etc/php5/cgi/conf.d/memcache.ini, /etc/php5/cgi/conf.d/mysql.ini, /etc/php5/cgi/conf.d/mysqli.ini, /etc/php5/cgi/conf.d/pdo.ini, /etc/php5/cgi/conf.d/pdo_mysql.ini, /etc/php5/cgi/conf.d/recode.ini, /etc/php5/cgi/conf.d/suhosin.ini, /etc/php5/cgi/conf.d/xcache.ini

if the value is not defined there, then its the default compiled in value of the php binary and you can override it in the php.ini settings field in ispconfig.

If you did any manual changes, make sure that you restarted apache and not just reloaded it.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #10  
Old 13th April 2011, 17:16
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
 
Default

Just as a additional note, max_execution time is 60 as defined in your php.ini files and not 30.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
Reply

Bookmarks

Tags
fastcgi, ispcfg3, php.ini

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 02:33.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.