Page MenuHomePhabricator

"Echo isn't enabled on this wiki" from Cron <www-data@terbium> /usr/local/bin/foreachwiki extensions/Echo/maintenance/processEchoEmailBatch.php >/dev/null
Closed, ResolvedPublicPRODUCTION ERROR

Description

/usr/local/bin/foreachwiki extensions/Echo/maintenance/processEchoEmailBatch.php is apparently sending an email to root from terbium from cron with several "Echo isn't enabled on this wiki".

Maybe something has to change on puppet that is outdated concerning mediawiki config? Maybe Echo has been disabled on some wikis recently? Maybe this error always happened?

If everything is ok, then make sure no daily emails are sent for spam.

Event Timeline

This has probably happened for the past two years or so. We could fix this by running this script on echo.dblist (which doesn't exist, so we'd have to create it), or by making the absence of Echo not be considered an error. I'll submit a patch to do the latter.

This is not a huge priority task, but like logs, two many of the least important ones sometimes hide the one mail we cannot miss.

Whatever is a quick an dirty fix would be ok, as long as it is on code / puppet.

\We could fix this by running this script on echo.dblist (which doesn't exist, so we'd have to create it)

so...undo T59375: remove echowikis to simplify configuration?

Change 294268 had a related patch set uploaded (by Catrope):
processEchoEmailBatch.php: Don't exit with code 1 if Echo is not installed

https://gerrit.wikimedia.org/r/294268

I do not think that will work, I assume that will output to 2> and send an email anyway. Maybe redirecting 2> /dev/null would be enough (or enable echo on all wikis)?

\We could fix this by running this script on echo.dblist (which doesn't exist, so we'd have to create it)

so...undo T59375: remove echowikis to simplify configuration?

If we go the dblist route, I'd rather have a nonecho.dblist listing all the wikis that don't have Echo, use that in InitialiseSettings (i.e. [ 'default' => true, 'nonecho' => false ]), then have echo.dblist be a computed dblist (%% all.dblist - nonecho.dblist) that's only used for running maintenance scripts.

I do not think that will work, I assume that will output to 2> and send an email anyway. Maybe redirecting 2> /dev/null would be enough (or enable echo on all wikis)?

Good point, I'd forgotten that would still write to stderr. So I'll abandon that and just do the dblist thing.

Change 294268 abandoned by Catrope:
processEchoEmailBatch.php: Don't exit with code 1 if Echo is not installed

Reason:
Won't do what we want because it'll still write to stderr

https://gerrit.wikimedia.org/r/294268

Change 294269 had a related patch set uploaded (by Catrope):
Add nonecho.dblist and echo.dblist

https://gerrit.wikimedia.org/r/294269

Change 294271 had a related patch set uploaded (by Catrope):
Only run processEchoEmailBatch.php on Echo-enabled wikis

https://gerrit.wikimedia.org/r/294271

I've scheduled the mw-config change for the morning SWAT at 15:00 UTC, and the puppet change for the puppet SWAT at 16:00 UTC.

Change 294269 merged by jenkins-bot:
Add nonecho.dblist and echo.dblist

https://gerrit.wikimedia.org/r/294269

Change 294271 merged by Giuseppe Lavagetto:
Only run processEchoEmailBatch.php on Echo-enabled wikis

https://gerrit.wikimedia.org/r/294271

Catrope claimed this task.

Both patches are deployed, so this error should stop happening now. Closing this task, reopen if the issue persists.

Warning: require_once(/etc/mediawiki/WikitechPrivateSettings.php): failed to open stream: No such file or directory in /srv/mediawiki/wmf-config/wikitech.php on line 183
Fatal error: require_once(): Failed opening required '/etc/mediawiki/WikitechPrivateSettings.php' (include_path='/srv/mediawiki/php-1.28.0-wmf.7:/usr/local/lib/php:/usr/share/php') in /srv/mediawiki/wmf-config/wikitech.php on line 183
Warning: require_once(/etc/mediawiki/WikitechPrivateSettings.php): failed to open stream: No such file or directory in /srv/mediawiki/wmf-config/wikitech.php on line 183
Fatal error: require_once(): Failed opening required '/etc/mediawiki/WikitechPrivateSettings.php' (include_path='/srv/mediawiki/php-1.28.0-wmf.7:/usr/local/lib/php:/usr/share/php') in /srv/mediawiki/wmf-config/wikitech.php on line 183

Something may be wrong with wikitech? I think I saw someone commening about this on IRC?

But this is from terbium 9 hours ago.

Something may be wrong with wikitech? I think I saw someone commening about this on IRC?

I don't think anything is wrong with wikitech if this was running on terbium, that file is only supposed to exist on the wikitech host.

s/Something may be wrong with wikitech/something may be wrong with configuration for wikitech because somehow the general mediawiki installation try to use it, so that probably is an error, but I do not not know why or how, so I am reporting the error I saw here because I reported an earlier error and I think this could be related to Catrope's fix and he said that we shoud reopen if the issue persists/g

something may be wrong with configuration for wikitech because somehow the general mediawiki installation try to use it, so that probably is an error, but I do not not know why or how, so I am reporting the error I saw here because I reported an earlier error and I think this could be related to Catrope's fix and he said that we shoud reopen if the issue persists

When people run scripts against all wikis there will be issues because terbium can't run stuff properly against wikitech anymore.

Change 309615 had a related patch set uploaded (by Chad):
Include wikitech's private settings on terbium-like hosts

https://gerrit.wikimedia.org/r/309615

Change 309615 abandoned by Chad:
Include wikitech's private settings on terbium-like hosts

https://gerrit.wikimedia.org/r/309615

Change 309616 had a related patch set uploaded (by Chad):
Sometimes we want to pretend to be wikitech even when we aren't

https://gerrit.wikimedia.org/r/309616

Change 309616 merged by jenkins-bot:
Sometimes we want to pretend to be wikitech even when we aren't

https://gerrit.wikimedia.org/r/309616

demon subscribed.

The reason this was reopened should be solved now.

@demon I love you! Thank you very much!

mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:11 PM