Unable to Login: Install Horde 5 Webmail For ISPConfig On Debian Wheezy Through PEAR

Discussion in 'HOWTO-Related Questions' started by onastvar, May 2, 2016.

  1. onastvar

    onastvar Member

    I followed HowTo
    Install Horde 5 Webmail For ISPConfig On Debian Wheezy Through PEAR
    I'm having issues with logging into HORDE, the following errors are in the log


    Code:
    May 2 09:49:24 sun HORDE: PHP ERROR: session_start(): open(/var/www/web2/phptmp//sess_ulbj3qke2iiha4p3rbkvkc7667, O_RDWR) failed: No such file or directory (2) [pid 13266 on line 204 of "/usr/share/php/Horde/Session.php"]
    May 2 09:49:25 sun dovecot: imap-login: Login: user=<[email protected]>, method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, mpid=20468, TLS, session=<41BFGd0xcwB/AAAB>
    May 2 09:49:35 sun HORDE: [horde] Login success for [email protected]@mydomain.com to horde (20.2.30.5) [pid 13266 on line 164 of "/var/www/horde/login.php"]
    May 2 09:49:35 sun dovecot: imap([email protected]): Disconnected: Logged out in=26 out=380
    May 2 09:49:35 sun HORDE: PHP ERROR: session_start(): open(/var/www/web2/phptmp//sess_igvqg1c005951lbo81gir6nd93, O_RDWR) failed: No such file or directory (2) [pid 13266 on line 204 of "/usr/share/php/Horde/Session.php"]
    May 2 09:49:45 sun HORDE: Guest user is not authorized for Horde (Host: 20.2.30.5). [pid 13266 on line 324 of "/usr/share/php/Horde/Registry.php"]
    May 2 09:49:45 sun HORDE: PHP ERROR: session_start(): open(/var/www/web2/phptmp//sess_igvqg1c005951lbo81gir6nd93, O_RDWR) failed: No such file or directory (2) [pid 13266 on line 204 of "/usr/share/php/Horde/Session.php"]
    Any suggestions how to troubleshoot?

     
  2. sjau

    sjau Local Meanie Moderator

    does /var/www/web2/phptmp exist?
     
  3. onastvar

    onastvar Member

    ISPConfig 3 has following folder structure /var/www/clients/client1/web2
    I don't think it's a good idea to have phptmp folder for each website manually which I cannot even create
    Code:
    [email protected]:/var/www/clients/client1/web2# mkdir phptmp
    mkdir: cannot create directory `phptmp': Permission denied
    [email protected]:/var/www/clients/client1/web2# mkdir: cannot create directory `phptmp': Permission denied
    
     
  4. sjau

    sjau Local Meanie Moderator

    Well, in the howto it says:

    Code:
    mkdir /var/www/horde/phptmp/
    chown -R www-data:www-data /var/www/horde
    
    So I wonder why you end up with your path...
     
  5. onastvar

    onastvar Member

    I created folder and chown it. I'm not sure why I'm getting
    PHP ERROR: session_start()
    It looks like something is pointing to incorrect folder (/var/www/web2/phptmp)
    Anyone has any suggestions how to fix this?
     
  6. sjau

    sjau Local Meanie Moderator

    pastebin your horde.conf file
     
  7. onastvar

    onastvar Member

    Thanks for looking at this. Here's my /etc/apache2/conf.d/horde.conf
    Code:
    
    Alias /Microsoft-Server-ActiveSync /var/www/horde/rpc.php
    Alias /horde /var/www/horde
    <Directory /var/www/horde>
               Options +FollowSymLinks
               AllowOverride All
               order allow,deny
               allow from all
               AddType application/x-httpd-php .php
               php_value include_path ".:/usr/share/php"
               php_value open_basedir "none"
               php_value upload_tmp_dir "/var/www/horde/phptmp/"
    </Directory>
    

     
  8. sjau

    sjau Local Meanie Moderator

    hmmm, weird...
     
  9. onastvar

    onastvar Member

    Do you think above error/issue is related to Horde only or PHP or ISPConfig?
     
  10. sjau

    sjau Local Meanie Moderator

    I have no idea what you did. Using a fresh install with ispc according to the perfect howto - it all works.
     
  11. onastvar

    onastvar Member

    sjau thanks for your help!

    The reason I wanted to try Horde some of my customers have issues using roundcube, when replying to emails just hangs and does not do anything.

    I did follow perfect "howto" years ago debian squeeze then I upgraded to debian wheezy, I can't fresh install because we have too many clients.
    I'm trying to fix it, I'm sure it's possible, I just need some direction. I tried to send my issue to HORDE mailing list but got blocked for no reason.

    It may be an issue with PHP installation
     
    Last edited: May 12, 2016
  12. onastvar

    onastvar Member

    Could someone share/post horde conf.php?
    /var/www/horde/config/conf.php
     
  13. sjau

    sjau Local Meanie Moderator

    From my Jessie install:

    Code:
    <?php
    /* CONFIG START. DO NOT CHANGE ANYTHING IN OR AFTER THIS LINE. */
    // $Id: 41a4cec5f53fb2d327c8ed9e1c6cfd330a6b7217 $
    $conf['vhosts'] = false;
    $conf['debug_level'] = E_ALL & ~E_NOTICE;
    $conf['max_exec_time'] = 0;
    $conf['compress_pages'] = true;
    $conf['secret_key'] = 'xxxxxxxxxxxxxxxxxxx';
    $conf['umask'] = 077;
    $conf['testdisable'] = true;
    $conf['use_ssl'] = 2;
    $conf['server']['name'] = $_SERVER['SERVER_NAME'];
    $conf['urls']['token_lifetime'] = 30;
    $conf['urls']['hmac_lifetime'] = 30;
    $conf['urls']['pretty'] = false;
    $conf['safe_ips'] = array();
    $conf['session']['name'] = 'Horde';
    $conf['session']['use_only_cookies'] = true;
    $conf['session']['timeout'] = 0;
    $conf['session']['cache_limiter'] = 'nocache';
    $conf['session']['max_time'] = 0;
    $conf['cookie']['domain'] = $_SERVER['SERVER_NAME'];
    $conf['cookie']['path'] = '/';
    $conf['sql']['username'] = 'horde';
    $conf['sql']['password'] = 'xxxxxxxxxxx';
    $conf['sql']['protocol'] = 'unix';
    $conf['sql']['database'] = 'horde';
    $conf['sql']['charset'] = 'utf-8';
    $conf['sql']['ssl'] = true;
    $conf['sql']['splitread'] = false;
    $conf['sql']['phptype'] = 'mysql';
    $conf['nosql']['phptype'] = false;
    $conf['ldap']['useldap'] = false;
    $conf['auth']['admins'] = array([email protected]');
    $conf['auth']['checkip'] = true;
    $conf['auth']['checkbrowser'] = true;
    $conf['auth']['resetpassword'] = true;
    $conf['auth']['alternate_login'] = false;
    $conf['auth']['redirect_on_logout'] = false;
    $conf['auth']['list_users'] = 'list';
    $conf['auth']['params']['app'] = 'imp';
    $conf['auth']['driver'] = 'application';
    $conf['auth']['params']['count_bad_logins'] = false;
    $conf['auth']['params']['login_block'] = false;
    $conf['auth']['params']['login_block_count'] = 5;
    $conf['auth']['params']['login_block_time'] = 5;
    $conf['signup']['allow'] = false;
    $conf['log']['enabled'] = false;
    $conf['log_accesskeys'] = false;
    $conf['prefs']['maxsize'] = 65535;
    $conf['prefs']['params']['driverconfig'] = 'horde';
    $conf['prefs']['driver'] = 'Sql';
    $conf['alarms']['params']['driverconfig'] = 'horde';
    $conf['alarms']['params']['ttl'] = 300;
    $conf['alarms']['driver'] = 'Sql';
    $conf['group']['driverconfig'] = 'horde';
    $conf['group']['driver'] = 'Sql';
    $conf['perms']['driverconfig'] = 'horde';
    $conf['perms']['driver'] = 'Sql';
    $conf['share']['no_sharing'] = false;
    $conf['share']['auto_create'] = true;
    $conf['share']['world'] = true;
    $conf['share']['any_group'] = false;
    $conf['share']['hidden'] = false;
    $conf['share']['cache'] = false;
    $conf['share']['driver'] = 'Sqlng';
    $conf['cache']['default_lifetime'] = 86400;
    $conf['cache']['params']['sub'] = 0;
    $conf['cache']['driver'] = 'File';
    $conf['cache']['use_memorycache'] = '';
    $conf['cachecssparams']['url_version_param'] = true;
    $conf['cachecss'] = false;
    $conf['cachejsparams']['url_version_param'] = true;
    $conf['cachejs'] = false;
    $conf['cachethemes'] = false;
    $conf['lock']['params']['driverconfig'] = 'horde';
    $conf['lock']['driver'] = 'Sql';
    $conf['token']['params']['driverconfig'] = 'horde';
    $conf['token']['driver'] = 'Sql';
    $conf['history']['params']['driverconfig'] = 'horde';
    $conf['history']['driver'] = 'Sql';
    $conf['davstorage']['params']['driverconfig'] = 'horde';
    $conf['davstorage']['driver'] = 'Sql';
    $conf['mailer']['params']['sendmail_path'] = '/usr/lib/sendmail';
    $conf['mailer']['params']['sendmail_args'] = '-oi';
    $conf['mailer']['type'] = 'sendmail';
    $conf['vfs']['params']['driverconfig'] = 'horde';
    $conf['vfs']['type'] = 'Sql';
    $conf['sessionhandler']['type'] = 'Builtin';
    $conf['sessionhandler']['hashtable'] = false;
    $conf['spell']['driver'] = '';
    $conf['gnupg']['keyserver'] = array('pool.sks-keyservers.net');
    $conf['gnupg']['timeout'] = 10;
    $conf['nobase64_img'] = false;
    $conf['image']['driver'] = false;
    $conf['exif']['driver'] = 'Bundled';
    $conf['timezone']['location'] = 'ftp://ftp.iana.org/tz/tzdata-latest.tar.gz';
    $conf['problems']['email'] = 'u';
    $conf['problems']['maildomain'] = 'example.com';
    $conf['problems']['tickets'] = false;
    $conf['problems']['attachments'] = true;
    $conf['menu']['links']['help'] = 'all';
    $conf['menu']['links']['prefs'] = 'authenticated';
    $conf['menu']['links']['problem'] = 'all';
    $conf['menu']['links']['login'] = 'all';
    $conf['menu']['links']['logout'] = 'authenticated';
    $conf['portal']['fixed_blocks'] = array();
    $conf['accounts']['driver'] = 'null';
    $conf['user']['verify_from_addr'] = false;
    $conf['user']['select_view'] = true;
    $conf['facebook']['enabled'] = false;
    $conf['twitter']['enabled'] = false;
    $conf['urlshortener'] = false;
    $conf['weather']['provider'] = false;
    $conf['imap']['enabled'] = false;
    $conf['imsp']['enabled'] = false;
    $conf['kolab']['enabled'] = false;
    $conf['hashtable']['driver'] = 'none';
    $conf['activesync']['params']['driverconfig'] = 'horde';
    $conf['activesync']['storage'] = 'Sql';
    $conf['activesync']['emailsync'] = true;
    $conf['activesync']['version'] = '14.1';
    $conf['activesync']['auth']['type'] = 'basic';
    $conf['activesync']['autodiscovery'] = 'full';
    $conf['activesync']['outlookdiscovery'] = false;
    $conf['activesync']['logging']['type'] = false;
    $conf['activesync']['ping']['heartbeatmin'] = 60;
    $conf['activesync']['ping']['heartbeatmax'] = 2700;
    $conf['activesync']['ping']['heartbeatdefault'] = 480;
    $conf['activesync']['ping']['deviceping'] = true;
    $conf['activesync']['ping']['waitinterval'] = 5;
    $conf['activesync']['enabled'] = true;
    /* CONFIG END. DO NOT CHANGE ANYTHING IN OR BEFORE THIS LINE. */
    
    altered the secret key, db-info and admin email
     
  14. onastvar

    onastvar Member

    Thanks for sharing your conf.php I tried to modify my conf to match yours still get same issue.

    May 12 10:05:35 sun HORDE: PHP ERROR: session_start(): open(/var/www/web2/phptmp//sess_igvqg1c005951lbo81gir6nd93, O_RDWR) failed: No such file or directory (2) [pid 13266 on line 204 of "/usr/share/php/Horde/Session.php"]

    Here is part of my /usr/share/php/Horde/Session.php starting at line 204

    session_start();
    $this->_active = true;
    $this->_data = &$_SESSION;


    /* We have reopened a session. Check to make sure that authentication
    * status has not changed in the meantime. */
    if (!$this->_readonly &&
    !is_null($this->_relogin) &&
    (($GLOBALS['registry']->getAuth() !== false) !== $this->_relogin)) {
    Horde::log('Previous session attempted to be reopened after authentication status change. All session modifications will be ignored.', 'DEBUG');
    $this->_readonly = true;
    }
    }


    Tried to modify my php.ini by adding
    session.save_path = "/tmp"
    still same problem

    Something with sessions is not correct I'm not sure how to fix it, anyone has any ideas?
     
    Last edited: May 13, 2016
  15. sjau

    sjau Local Meanie Moderator

    where do you have horde installed to?
     
  16. onastvar

    onastvar Member

    /var/www/horde
     
  17. sjau

    sjau Local Meanie Moderator

    don't know.
     
  18. onastvar

    onastvar Member

    What's your PHP temporary directory?
     
  19. sjau

    sjau Local Meanie Moderator

    which one?
     
  20. onastvar

    onastvar Member

    I was able to fix this issue. I had php_admin_value session.save_path "/var/www/web2/phptmp/" in my website options tab under Apache Directives which was overriding the main php.ini

    Fixed by modifying
    php_admin_value session.save_path "/var/www/web2/phptmp/"
    to
    php_admin_value session.save_path "/tmp/"

    After that, I was able to login to horde.
    Thanks for your help with this issue!
     

Share This Page