[horde] changed domain name, broke 'users' config!

w trillich will at serensoft.com
Thu Jul 14 15:41:13 PDT 2005


first: we've been VERY impressed with horde -- wonderful slew of features
and convenience. can't imagine trying to get along without it! well done,
horde horde!

but we threw ourselves a curve:

horde WAS working nicely, playing nicely -- until we changed
our domain name (/etc/hosts, /etc/hostname). we're using IMP (imap)
to authenticate, and since saslpasswd2 (cyrus21) stores all usernames
as <user>@<fqdn> we had to rebuild those... (as fqdn changed)

now, with the new sasldb up-to-date with the new domain name
all set, we can log in as usual, and administrators can do
just about everything... except handle users!

seems odd that we can log in and authenticate from the main screen,
but the 'users' admin page gets borked. to wit:

- we log in (authenticate just fine, no snags at all)
- expand 'administration'
- click 'users'
- wait 15-20 seconds, and the web browser shows:

A fatal error has occurred
Can not authenticate to IMAP server: user not found

[line 236 of /var/www/horde/admin/user.php]
Details (also in Horde's logfile):

object(pear_error)(8) {
    ["error_message_prefix"]=>
    string(0) ""
    ["mode"]=>
    int(1)
    ["level"]=>
    int(1024)
    ["code"]=>
    string(11) "horde.error"
    ["message"]=>
    string(51) "Can not authenticate to IMAP server: user not found"
    ["userinfo"]=>
    NULL
    ["backtrace"]=>
    array(8) {
      [0]=>
      array(6) {
        ["file"]=>
        string(23) "/usr/share/php/PEAR.php"
        ["line"]=>
        int(538)
        ["function"]=>
        string(10) "pear_error"
        ["class"]=>
        string(10) "pear_error"
        ["type"]=>
        string(2) "->"
        ["args"]=>
        array(5) {
          [0]=>
          string(51) "Can not authenticate to IMAP server: user not found"
          [1]=>
          string(11) "horde.error"
          [2]=>
          int(1)
          [3]=>
          int(1024)
          [4]=>
          NULL
        }
      }
      [1]=>
      array(6) {
        ["file"]=>
        string(35) "/usr/share/php/Horde/IMAP/Admin.php"
        ["line"]=>
        int(98)
        ["function"]=>
        string(10) "raiseerror"
        ["class"]=>
        string(4) "pear"
        ["type"]=>
        string(2) "::"
        ["args"]=>
        array(2) {
          [0]=>
          string(51) "Can not authenticate to IMAP server: user not found"
          [1]=>
          string(11) "horde.error"
        }
      }
      [2]=>
      array(6) {
        ["file"]=>
        string(35) "/usr/share/php/Horde/IMAP/Admin.php"
        ["line"]=>
        int(189)
        ["function"]=>
        string(8) "_connect"
        ["class"]=>
        string(10) "imap_admin"
        ["type"]=>
        string(2) "->"
        ["args"]=>
        array(0) {
        }
      }
      [3]=>
      array(6) {
        ["file"]=>
        string(30) "/var/www/horde/imp/lib/api.php"
        ["line"]=>
        int(271)
        ["function"]=>
        string(13) "listmailboxes"
        ["class"]=>
        string(10) "imap_admin"
        ["type"]=>
        string(2) "->"
        ["args"]=>
        array(0) {
        }
      }
      [4]=>
      array(2) {
        ["function"]=>
        string(13) "_imp_userlist"
        ["args"]=>
        array(0) {
        }
      }
      [5]=>
      array(4) {
        ["file"]=>
        string(33) "/usr/share/php/Horde/Registry.php"
        ["line"]=>
        int(551)
        ["function"]=>
        string(20) "call_user_func_array"
        ["args"]=>
        array(2) {
          [0]=>
          string(13) "_imp_userList"
          [1]=>
          array(0) {
          }
        }
      }
      [6]=>
      array(6) {
        ["file"]=>
        string(41) "/usr/share/php/Horde/Auth/application.php"
        ["line"]=>
        int(143)
        ["function"]=>
        string(13) "callbypackage"
        ["class"]=>
        string(8) "registry"
        ["type"]=>
        string(2) "->"
        ["args"]=>
        array(2) {
          [0]=>
          string(3) "imp"
          [1]=>
          string(8) "userList"
        }
      }
      [7]=>
      array(6) {
        ["file"]=>
        string(29) "/var/www/horde/admin/user.php"
        ["line"]=>
        int(234)
        ["function"]=>
        string(9) "listusers"
        ["class"]=>
        string(16) "auth_application"
        ["type"]=>
        string(2) "->"
        ["args"]=>
        array(0) {
        }
      }
    }
    ["callback"]=>
    NULL
}

i presume that's a call stack for php? (we're not php gurus, by any stretch.)
if so, looks like it died in /usr/share/php/Horde/IMAP/Admin.php:

      #line 187:
      function listMailboxes()
      {
          if (is_a($imap = $this->_connect(), 'PEAR_Error')) {
              return $imap;
          }

the code is so darn modular we haven't been able to trace where it's
getting its username/servername from. maybe if we can straighten out
those two variables...?

plus we've not been able to find the log file it mentions, up top.
(lsof, lsof -i, lsof -U all show nothing when grepping -i for
'horde' and 'log'.) there's /var/log/horde/* but they're either
empty or untouched since may. argh!

$ find . -name README | xargs grep -i \$Revision
./imp/README::Revision:      $Revision: 2.21 $
./ingo/README::Revision:      $Revision: 1.8 $
./kronolith/README::Revision:      $Revision: 1.9 $
./mnemo/README::Revision:      $Revision: 1.7 $
./nag/README::Revision:      $Revision: 1.9 $
./po/README::Revision: $Revision: 1.29 $
./README::Revision:      $Revision: 2.13 $
./scripts/sql/README::Revision:      $Revision: 1.2.10.2 $
./turba/README::Revision:      $Revision: 1.12.10.1 $
./WASchora/README::Revision:      $Revision: 1.11 $

and before we upgrade to a new version and all the terror THAT
implies, we'd like to un-kink this one little kink, first.

which pages of which manuals pertain to this? any pointers welcome.

[another small speedbump is that 'permissions' under 'administration'
says 'invalid parent permission' when we click on the keys, but that's
another thread waiting to happen.]




More information about the horde mailing list