ispCP - Board - Support
How to save modified php.ini file settings - Printable Version

+- ispCP - Board - Support (http://www.isp-control.net/forum)
+-- Forum: ispCP Omega Support Area (/forum-30.html)
+--- Forum: System Setup & Installation (/forum-32.html)
+--- Thread: How to save modified php.ini file settings (/thread-3446.html)



How to save modified php.ini file settings - robmorin - 06-04-2008 02:49 AM

If i modify a php.ini file for a client, and then he adds something to his domain say an alias, all the cnages are reset to default.... now for other files such as zone files there is a working dir to copy changes over to , but what does one use for php.ini file..

Thanks...

Rob..


RE: How to save modified php.ini file settings - pgentoo - 06-04-2008 04:04 AM

The template php.ini is located in: /etc/ispcp/fcgi/parts/php[4/5]

If you want to make a change that will be applied to all new domains, then it should go here. If you just want to tweak one clients domain, then i'm not sure if you can persist those changes after an update... I'm sure someone else can chime in on this though.


RE: How to save modified php.ini file settings - robmorin - 06-04-2008 06:52 AM

Right i was looking for hte per client thingy, as i have about a dozen clients with special options in their php.ini file.... i was thinking about just over writing the newly installed php.ini files with my backups as i only see one difference in the php4.ini files there are 2 new additions to the excludes for executables.. popen and proc_open other than that i see no difference... as for php5.ini i have no diffed them yet...

Thanks to all...

ROb...


pasichnyk Wrote:The template php.ini is located in: /etc/ispcp/fcgi/parts/php[4/5]

If you want to make a change that will be applied to all new domains, then it should go here. If you just want to tweak one clients domain, then i'm not sure if you can persist those changes after an update... I'm sure someone else can chime in on this though.



RE: How to save modified php.ini file settings - pgentoo - 06-04-2008 10:42 AM

If you really need these changes to not be overwritten, you could comment out the lines in dmn_change_httpd_file_data (in ispcp-dmn-mngr), that delete the php.ini files at the beginning of the method.

This should fix your problem, but then you need to know that they will never be updated unless you first delete the files, then set the domain to a change status.

I'm not sure if there could be any bad consequences of doing this, but i'm sure someone else will chime in if that is the case.


RE: How to save modified php.ini file settings - robmorin - 06-04-2008 11:55 PM

Ok lets wait a bit and see if anyone mentions anything..

ANother quick question... when i change someone over to php5 by simply editing the php4-fcgi-starter file am i supposed to change the php.ini file that is used from php4 to php5 one? otherwise the php4 ini file is used, no?

thanks..

pasichnyk Wrote:If you really need these changes to not be overwritten, you could comment out the lines in dmn_change_httpd_file_data (in ispcp-dmn-mngr), that delete the php.ini files at the beginning of the method.

This should fix your problem, but then you need to know that they will never be updated unless you first delete the files, then set the domain to a change status.

I'm not sure if there could be any bad consequences of doing this, but i'm sure someone else will chime in if that is the case.



RE: How to save modified php.ini file settings - pgentoo - 06-05-2008 05:48 AM

robmorin Wrote:when i change someone over to php5 by simply editing the php4-fcgi-starter file am i supposed to change the php.ini file that is used from php4 to php5 one? otherwise the php4 ini file is used, no

I believe the directory to look for the php.ini file is defined in the phpX-fcgi-starter with the "PHPRC" variable. If you just rename a copy of the php4-fcgi-starter, it won't work. You need to modify this file to ponit to the correct binary as well as the correct PHPRC directory.

You'll also need to modify your vhosts file for apache, to switch it from using the php4-fcgi-starter to php5-fcgi-starter.

I'm sure there is a way to change something in the database, and then set the domain to change, and have the vhosts and starter scripts updated for you, but then you'd blow out any changes you've made...


RE: How to save modified php.ini file settings - robmorin - 06-05-2008 06:00 AM

Right ok i just want to make sure that i should be setting the PHPRC to the php5 dir rather than leave it at php4 dir...
good to know i have the option of either modifying the apache conf or the php4-fcgi-starter file..

thanks dude!

Rob..



pasichnyk Wrote:
robmorin Wrote:when i change someone over to php5 by simply editing the php4-fcgi-starter file am i supposed to change the php.ini file that is used from php4 to php5 one? otherwise the php4 ini file is used, no

I believe the directory to look for the php.ini file is defined in the phpX-fcgi-starter with the "PHPRC" variable. If you just rename a copy of the php4-fcgi-starter, it won't work. You need to modify this file to ponit to the correct binary as well as the correct PHPRC directory.

You'll also need to modify your vhosts file for apache, to switch it from using the php4-fcgi-starter to php5-fcgi-starter.

I'm sure there is a way to change something in the database, and then set the domain to change, and have the vhosts and starter scripts updated for you, but then you'd blow out any changes you've made...



RE: How to save modified php.ini file settings - RatS - 06-05-2008 05:42 PM

As far as I've writen these changes, the php*.ini files won't be overwritten.


RE: How to save modified php.ini file settings - robmorin - 06-05-2008 09:27 PM

You mean doing what pasichnyk mentioned above?

Thanks

ROb..

RatS Wrote:As far as I've writen these changes, the php*.ini files won't be overwritten.