Page MenuHomePhabricator

"Cannot seek on a pipe" warning in maintenance scripts
Closed, ResolvedPublic

Description

For some reason this doesn't happen on my local machine but does happen on the prototype server.

When I run maintenance scripts, I get lots of warnings like these:

Warning: fopen(): cannot seek on a pipe in /srv/org/wikimedia/prototype/wikis/rl2/maintenance/Maintenance.php on line 313

Call Stack:

 0.0004     154088   1. {main}() /srv/org/wikimedia/prototype/wikis/rl2/maintenance/update.php:0
 0.0026     782096   2. require_once('/srv/org/wikimedia/prototype/wikis/rl2/maintenance/doMaintenance.php') /srv/org/wikimedia/prototype/wikis/rl2/maintenance/update.php:147
 0.0995   12657528   3. UpdateMediaWiki->execute() /srv/org/wikimedia/prototype/wikis/rl2/maintenance/doMaintenance.php:105
10.8290   19037824   4. Maintenance->output() /srv/org/wikimedia/prototype/wikis/rl2/maintenance/update.php:128
10.8290   19037824   5. fopen() /srv/org/wikimedia/prototype/wikis/rl2/maintenance/Maintenance.php:313

The offending line is $f = fopen( 'php://stdout', 'a' );


Version: unspecified
Severity: normal

Details

Reference
bz32263

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 12:05 AM
bzimport set Reference to bz32263.
bzimport added a subscriber: Unknown Object (MLST).

https://bugs.php.net/bug.php?id=45303 ?

Claims "fixed in CVS" somewhere in what might be PHP 5.2 timeline.

What PHP ver is on these boxes?

PHP 5.2.4-2ubuntu5.12wm1 with Suhosin-Patch 0.9.6.2 (cli) (built: Sep 23 2010 20:36:55)

Seems to be a since-fixed upstream bug in PHP then, closing.

PHP Bug 45303 was fixed with 5.2.7 (04-Dec-2008)
Ref: http://php.net/ChangeLog-5.php