Page MenuHomePhabricator

Fix "PHP Warning: Module 'apc' already loaded" on zend slaves
Closed, ResolvedPublic

Description

Looks legit?
https://integration.wikimedia.org/ci/job/php-composer-test/5064/console
https://integration.wikimedia.org/ci/job/php-composer-test-zend/891/console

...
07:11:03 [php-composer-test] $ /bin/bash -xe /tmp/hudson7229315295886512237.sh
07:11:03 + /srv/deployment/integration/composer/vendor/bin/composer test
07:11:03 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
07:11:03 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
...

Event Timeline

Nemo_bis raised the priority of this task from to Needs Triage.
Nemo_bis updated the task description. (Show Details)
Nemo_bis subscribed.
Legoktm renamed this task from PHP Warning: Module 'apc' already loaded in Unknown on line 0 to PHP Warning: Module 'apc' already loaded in Unknown on line 0 on zend slaves.May 18 2015, 8:39 AM
Legoktm updated the task description. (Show Details)
Legoktm set Security to None.

Legoktm said:

...no, it was just failing on "08:11:01 42 | WARNING | Line exceeds 100 characters; contains 107 characters" and confusingly also included the apc error in the final exception.

hashar subscribed.

Surely annoying but not causing any specific issue.

Seems APC is configured twice in /etc/php/**

Krinkle renamed this task from PHP Warning: Module 'apc' already loaded in Unknown on line 0 on zend slaves to Fix "PHP Warning: Module 'apc' already loaded" on zend slaves.May 31 2015, 10:15 PM
Krinkle updated the task description. (Show Details)
Krinkle added a subscriber: Legoktm.

This warning impairs readability of the test resutls. Especially things like phplint which have no other output normally and are exclusively run on Zend (and thus trigger this warning for every linted file.)

https://integration.wikimedia.org/ci/job/phplint/14601/console

00:00:01.089 + xargs -n1 -t php -l
00:00:01.104 php -l HCUpdater.php 
00:00:01.119 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
00:00:01.149 No syntax errors detected in HCUpdater.php
00:00:01.156 php -l HitCounters.body.php 
00:00:01.167 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
00:00:01.196 No syntax errors detected in HitCounters.body.php
00:00:01.204 php -l HitCounters.i18n.magic.php 
00:00:01.218 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
00:00:01.239 No syntax errors detected in HitCounters.i18n.magic.php
00:00:01.243 php -l HitCounters.php 
00:00:01.255 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
00:00:01.277 No syntax errors detected in HitCounters.php
00:00:01.282 php -l Hooks.php 
00:00:01.294 PHP Warning:  Module 'apc' already loaded in Unknown on line 0
00:00:01.315 PHP Parse error:  syntax error, unexpected T_USE, expecting '&' or T_VARIABLE in Hooks.php on line 17
00:00:01.315 Errors parsing Hooks.php
00:00:01.320 xargs: php: exited with status 255; aborting
00:00:01.331 Build step 'Execute shell' marked build as failure
00:00:01.359 Notifying endpoint 'HTTP:http://127.0.0.1:8001/jenkins_endpoint'
00:00:01.400 Finished: FAILURE

It's not obvious here that the warnings don't matter, and it's hard to find the one line that actually matters (the PHP Parse error).

integration-slave-precise-1013:/etc/php5$ grep -R "extension=.*apc" .
./conf.d/apc.ini:extension="apc.so"
./conf.d/disable-html_errors.ini:extension="apc.so"
./cli/conf.d/apc.ini:extension="apc.so"
./cli/conf.d/disable-html_errors.ini:extension="apc.so"
./apache2filter/conf.d/apc.ini:extension="apc.so"
./apache2filter/conf.d/disable-html_errors.ini:extension="apc.so"

So it is also enabled via disable-html_errors.ini not idea what it is.

cat /etc/php5/conf.d/disable-html_errors.ini

; This file is managed by puppet
; puppet:///modules/contint/php-disable-html_errors.ini
extension="apc.so"

; Disable html_errors per T97040
; http://php.net/html-errors
html_errors=0

Seems an issue in operations/puppet contint module :-}

Per T97040, this was https://gerrit.wikimedia.org/r/206143. Which was deployed on integration slaves for a short time while debugging. That file was based on another file, and that line was accident kept in duplication.

I've removed the stale files from the integration slaves.

Krinkle claimed this task.
Krinkle moved this task from Next to Done on the Continuous-Integration-Infrastructure board.