Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 50908 - PHP 4.3.6 & mod_php 4.3.6 again have the same php.ini
Summary: PHP 4.3.6 & mod_php 4.3.6 again have the same php.ini
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: PHP Bugs
URL:
Whiteboard:
Keywords:
: 53982 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-05-13 01:13 UTC by Andreas Schrogl
Modified: 2004-07-31 14:48 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
PHP CLI Output (php-cli.txt,2.38 KB, text/plain)
2004-05-13 03:54 UTC, Andreas Schrogl
Details
PHP Apache Output (php-apache,2.33 KB, text/plain)
2004-05-13 03:56 UTC, Andreas Schrogl
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Schrogl 2004-05-13 01:13:11 UTC
Hi,

today i emerged the updated php and mod_php.
After some strange errors after compiling i checked the phpinfo page
and the cli version is using the same php.ini as the apache version.

Both are using the /etc/php/apache1-php/ version of the php.ini file.
This also happens some versions bevor this release.

Regards
Andreas Schrogl
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-13 03:41:20 UTC
could you please attach a copy of the phpinfo web output AND the CLI 'php -i' output?
Comment 2 Andreas Schrogl 2004-05-13 03:54:57 UTC
Created attachment 31319 [details]
PHP CLI Output 

 only the Configuration strings and the upper part of the config
Comment 3 Andreas Schrogl 2004-05-13 03:56:05 UTC
Created attachment 31320 [details]
PHP Apache Output

again only the Configuration Stings + the upper part of the config
Comment 4 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-13 10:28:50 UTC
do you use a portage overlay at all, possibly with a php-sapi.eclass ?
Comment 5 Andreas Schrogl 2004-05-13 23:45:36 UTC
I just done an "emerge -u world" not more not less. 

The only thing i use is the /etc/portage/package.mask 
to mask apache2. That's all i used on that server i don't have configured any 
special settings on this machine, it's just a plain LAMP Server wich comes nealry out of the box of a 2004.0 Gentoo.

Bevor the Update i installed this Server the First time with

emerge apache mysql mod_php mod_ssl

this will automaticly install the cli version of php, too. 
Comment 6 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-13 23:49:53 UTC
did the etc-update show any changes to the ini files?
Comment 7 Andreas Schrogl 2004-05-13 23:58:56 UTC
don't know, i skipped that, because the location of the php.ini is a configure process so it's not important what's IN the php.ini file if it's at the wrong location.
Comment 8 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-28 12:47:00 UTC
_do_ do the etc-update for the ini files and then try:
'emerge apache mod_php php' again.
during the mod_php and php outputs, please look for the comment about 'INI' that comes up before the configure is run, and include it here (or better yet, turn on emerge logging, and attach the logfiles from /var/log/emerge/ for php and mod_php).
Comment 9 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-28 12:48:13 UTC
oh, wait 2-3 hours and emerge sync before you do this,
i've added some more logging stuff into the php eclass, that should help us diagnose this.
Comment 10 Andreas Schrogl 2004-06-01 00:15:58 UTC
Sorry can't emerge php on that System - this is a hightraffic Webserver which runs over 200 commerical Websites. For emerging php and mod_php i have to turn him down, which is absolutly NOT possible at the moment - just for a testing purpose.

Regards
Andreas Schrogl
Comment 11 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-06-01 00:55:26 UTC
assuming your server uses only the mod_php for the websites,
you can safely do the 'emerge php' part right now.
i'd suggest doing the 'emerge mod_php' part at your earliest convience/scheduled downtime. your downtime window for updating mod_php should be extremely minimal, namely just the period when you run '/etc/init.d/apache restart' right after the emerge.
Comment 12 Andreas Schrogl 2004-06-01 01:14:11 UTC
We are also using cli-php for cronjobs every minute. i have to schedule a downtime for this server for this testing.
I know that the downtime is minimal, because we are running over 30 Servers with gentoo at the moment, but i something goes wrong i have a big problem which doesn't takes only 5 minutes.
as soon as i'm able to test it i write back
Comment 13 Andreas Schrogl 2004-06-09 12:50:20 UTC
Hi,
ok with you updated build Files the problem is fixed.
Now i have the cli version with the cli/php.ini and the mod_php with the apache1/ php.ini.

Thx for the help
Comment 14 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-06-15 18:21:58 UTC
*** Bug 53982 has been marked as a duplicate of this bug. ***
Comment 15 awk 2004-07-31 13:14:15 UTC
This bug is still present. If you install php and then mod_php, mod_php will overwrite /usr/bin/php. One solution is to always remember to reinstall php after mod_php. Here is another work-around:

ln -s ../cli-php4/php.ini /etc/php/apache2-php4/php-cli.ini

Since PHP looks for php-cli.ini before loading php.ini, this will always load the correct config file.

Why does mod_php install /usr/bin/php in the first place?
Comment 16 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-07-31 14:48:04 UTC
awk: open a new bug for /usr/bin/php being overwritten, and provide your details.