Can't login to webGUI - instantly returns to login screen

  • Hi guys,


    I'm running OMV 4.1.35-1 and from a couple of weeks ago I suddenly couldn't login to the Web GUI anymore:

    When I enter the credentials it starts loading the admin web page but then returns to the login screen.

    I can successfully login with SSH and as far as I can see all services run smoothly. I do not experience other problems.

    I randomly use the web gui so I can not state the exact point when it stopped letting me login.


    What I tried:

    - use another browser with empty cache or use private session,

    - df -h shows enough free space,

    - dpkg -l | grep openmediavault :


    ii openmediavault 4.1.35-1 all openmediavault - The open network attached storage solution

    ii openmediavault-autoshutdown 4.0.5 all OpenMediaVault AutoShutdown Plugin

    ii openmediavault-backup 4.0.6 all backup plugin for OpenMediaVault.

    ii openmediavault-diskstats 4.0.2-1 all OpenMediaVault disk monitoring plugin

    ii openmediavault-flashmemory 4.2.1 all folder2ram plugin for OpenMediaVault

    ii openmediavault-keyring 1.0 all GnuPG archive keys of the OpenMediaVault archive

    ii openmediavault-locate 3.4 all locate plugin for OpenMediaVault.

    ii openmediavault-omvextrasorg 4.1.16 all OMV-Extras.org Package Repositories for OpenMediaVault

    ii openmediavault-resetperms 3.3 all Reset Permissions

    ii openmediavault-route 4.0.4-1 all OpenMediaVault IP routing table plugin



    Any hints on that?


    Cheers,

  • no, really strange your case sorry.


    if finally you do not find the reason, perhaps a re-install solve your problems.


    In that case try to do the fresh install on a new boot device , so if something goes wrong at least you can put old boot device and start OMV ( without WebGUI access, but at least run).

  • Is your OS partition full by chance? That will cause you to not be able to log into the webUI.


    I would try opening a browser in Privacy/Incognito mode, and try to log in to the GUI, just to make sure it's not a cache issue.

  • Executed the commands without any errors (didn't get any sort of successful messages either).

    But that didn't help. GUI still returns to the login screen when trying to log me in.


    I assume that what I should look for is log files of nginx. Or does OMV write own logs in another location, too ?

  • Did some research in the logfiles and monitored my own login tries.


    Found this in openmediavault-webgui_error.log:

    Code
    2020/06/12 08:23:56 [error] 2062#2062: *56 FastCGI sent in stderr: "PHP message: PHP Warning: session_start(): open(/var/lib/php/sessions/sess_k7r8eiig1i8j3o18n0hr6l33u4, O_RDWR) failed: Permission denied (13) in /usr/share/php/openmediavault/session.inc on line 43" while reading response header from upstream, client: 127.0.0.1, server: openmediavault-webgui, request: "HEAD / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm-openmediavault-webgui.sock:", host: "127.0.0.1"
    2020/06/12 08:24:13 [error] 2062#2062: *58 FastCGI sent in stderr: "PHP message: PHP Warning: session_start(): open(/var/lib/php/sessions/sess_ccne044kgksro7rfbaoiaghqp1, O_RDWR) failed: Permission denied (13) in /usr/share/php/openmediavault/session.inc on line 43
    PHP message: PHP Warning: session_regenerate_id(): open(/var/lib/php/sessions/sess_ccne044kgksro7rfbaoiaghqp1, O_RDWR) failed: Permission denied (13) in /usr/share/php/openmediavault/session.inc on line 67
    PHP message: PHP Warning: session_regenerate_id(): Session write failed. ID: files (path: /var/lib/php/sessions) in /usr/share/php/openmediavault/session.inc on line 67" while reading response header from upstream, client: 192.168.0.248, server: openmediavault-webgui, request: "POST /rpc.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm-openmediavault-webgui.sock:", host: "nas", referrer: "http://nas/"
    2020/06/12 08:24:14 [error] 2062#2062: *58 FastCGI sent in stderr: "PHP message: PHP Warning: session_start(): open(/var/lib/php/sessions/sess_ccne044kgksro7rfbaoiaghqp1, O_RDWR) failed: Permission denied (13) in /usr/share/php/openmediavault/session.inc on line 43" while reading response header from upstream, client: 192.168.0.248, server: openmediavault-webgui, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm-openmediavault-webgui.sock:", host: "nas", referrer: "http://nas/"


    And found this in openmediavault-webgui_access.log:


    Code
    127.0.0.1 - - [12/Jun/2020:08:23:56 +0200] "HEAD / HTTP/1.1" 200 0 "-" "Monit/5.20.0"
    192.168.0.248 - - [12/Jun/2020:08:24:12 +0200] "GET /images/exclamation.svg HTTP/1.1" 304 0 "http://nas/css/theme-all.min.css" "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36"
    192.168.0.248 - - [12/Jun/2020:08:24:12 +0200] "GET /extjs6/classic/theme-triton/resources/fonts/OpenSans-Bold.ttf HTTP/1.1" 304 0 "http://nas/extjs6/classic/theme-triton/resources/theme-triton-all_2.css" "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36"
    192.168.0.248 - - [12/Jun/2020:08:24:13 +0200] "POST /rpc.php HTTP/1.1" 200 78 "http://nas/" "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36"
    192.168.0.248 - - [12/Jun/2020:08:24:14 +0200] "GET / HTTP/1.1" 200 1870 "http://nas/" "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36"
    127.0.0.1 - - [12/Jun/2020:08:24:26 +0200] "HEAD / HTTP/1.1" 200 0 "-" "Monit/5.20.0"

  • The mentioned thread on GitHub gave me helpful information to solve the problem. Thank you, macom !

    For the records:

    Something broke during the upgrade from "openmediavault-flashmemory folder2ram plugin for OpenMediaVault" v 4.2.x up to v 4.2.2 with the sessions folder of NGinx. The permissions were lost or altered or not updated (I'm not exactly sure what happened).


    Deleting the sessions folder and re-creating it did help:

    Code
    sudo rm -rf /var/lib/php/sessions 
    sudo mkdir -m 777 /var/lib/php/sessions 
    ls /var/lib/php -l 
    sudo nginx -s reload

    After that I was able to log in to the web GUI.

    To avoid future problems with the folder2ram plugin I deinstalled it. I switched from an USB flash drive to a standard SSD a couple of months ago and preserved the plugin just out of habit.

    Thank you all for your support!

  • Glad you finally solved it :thumbup:


    Please consider to upgrade to OMV5.

    OMV4 is based on Debian 9 and that will be end of life soon.

    The last time I considered an upgrade I found out that there's no inplace upgrade path from OMV 3.x to 4.x which resulted in a complete new installation.

    I did not read any manuals yet but I am hopeful that OMV evolved and an inplace upgrade from v4 to v5 is available now. Is it?

  • The last time I considered an upgrade I found out that there's no inplace upgrade path from OMV 3.x to 4.x which resulted in a complete new installation.

    I did not read any manuals yet but I am hopeful that OMV evolved and an inplace upgrade from v4 to v5 is available now. Is it?

    There was a built in upgrade mechanism in OMV 3 for inplace upgrading to OMV 4 that did not involve a fresh from scratch install.


    Currently, the method used to inplace upgrade OMV 4 to OMV 5 is not built in to OMV 4 and not officially supported.

    --
    Google is your friend and Bob's your uncle!


    OMV AMD64 5.x on ASRock Rack C2550D4I C0 Stepping - 16GB ECC - Silverstone DS380 + Silverstone DS380 DAS Box.

  • Several users performed the upgrade using the script and commands posted here:

    RE: OMV 5.0 - finally out! :-)


    Among other things the script will remove all plug-ins that have not been ported to OMV5.

    RE: Why should you use or not use dockers

  • Hi macom ,

    thanks for pointing me to that thread.

    In the meanwhile I succesfully upgraded my v4 to v5.5.3-1 with that script and the given commands.

    At some point the installer asked me for several modules if I would like to keep my current customized configs or update with the new releases:


    I was afraid to maybe overwrite OMV-specific settings when upgrading to the highly current versions.

    Nevertheless I always chose to install the maintainer's version - and everything worked well.


    Cheers,

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!