Page MenuHomePhabricator

Restarting daemons isn't fixing daemons.need-restarting config issue
Closed, DuplicatePublic

Description

After recent update (previous was 11th August), Phabricator Daemons Need Restarting config issue is apparent.

Stopping daemons removes config issue, but upon starting again config issue arises.

Any ideas how to hunt this one down?

Event Timeline

zorfling assigned this task to epriestley.
zorfling raised the priority of this task from to Needs Triage.
zorfling updated the task description. (Show Details)
zorfling added a project: Phabricator.
zorfling added a subscriber: zorfling.

Some possible causes:

  • You might actually have different daemon and web configuration. Are you using PHABRICATOR_ENV? Is it set to the same value when the daemons execute as it is in Phabricator?
  • We might need to asort() the $keys coming out of self::getAllConfigKeys() in calculateEnvironmentHash(). I'm not sure this is guaranteed to be stable.

You could try applying this patch to test the second theory:

diff --git a/src/infrastructure/env/PhabricatorEnv.php b/src/infrastructure/env/PhabricatorEnv.php
index d5e3237..a8f4dce 100644
--- a/src/infrastructure/env/PhabricatorEnv.php
+++ b/src/infrastructure/env/PhabricatorEnv.php
@@ -223,6 +223,8 @@ final class PhabricatorEnv {
 
   public static function calculateEnvironmentHash() {
     $keys = array_keys(self::getAllConfigKeys());
+    asort($keys);
+
     $values = array();
     foreach ($keys as $key) {
       $values[$key] = self::getEnvConfigIfExists($key);

Aaah fail. Yep the daemons and web had different phabricator_env.

Thanks for the pointers.

btrahan changed the task status from Resolved to Duplicate.Aug 26 2014, 5:10 PM

✘ Merged into T5968.