Error 404 after install

Error 404 after install

by abe xxs -
Number of replies: 3

I've installed Moodle 3.2 Developer.

Install runs 100% perfect, after installation I got redirected to admin/index.php?sessionstarted=1&sessionverify=1&lang=en and I get a error 404. What is the solution to this problem. I've spent hours: clearing cache, editing admin/index.php etc. Nothing seems to help.


Site: http://topintaal.be/b/admin/index.php?sessionstarted=1&sessionverify=1&lang=en
Server Nginx 1.8
Moodle 3.2 Dev


Error log:

[code]

PHP message: PHP Warning:  is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8967" while reading response header from upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php?sessionstarted=1&sessionverify=1&lang=en HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:00 [error] 31059#31059: *40 FastCGI sent in stderr: "PHP message: PHP Warning:  is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8967
PHP message: PHP Warning:  is_executable(): open_basedir restriction in effect. File(/usr/bin/uptime) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8970
PHP message: PERF: /b/ time: 0.754319s memory_total: 3594576B (3.4MB) memory_growth: 3220768B (3.1MB) memory_peak: 4614808B (4.4MB) includecount: 88 langcountgetstring: 8 db reads/writes: 6/5 db queries time: 0.09165s ticks: 75 user: 38 sys: 1 cuser: 0 csys: 0 Session (core\session\file): 90 bytes Caches used (hits/misses/sets): 0/0/0" while reading response header from upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/ HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:01 [error] 31059#31059: *40 FastCGI sent in stderr: "PHP message: PHP Warning:  is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8967" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:01 [error] 31059#31059: *40 FastCGI sent in stderr: "PHP message: PHP Warning:  is_executable(): open_basedir restriction in effect. File(/usr/bin/uptime) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8970" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:01 [error] 31059#31059: *40 FastCGI sent in stderr: "PHP message: PERF: /b/admin/index.php time: 0.589323s memory_total: 13334224B (12.7MB) memory_growth: 12967904B (12.4MB) memory_peak: 14193864B (13.5MB) includecount: 681 langcountgetstring: 11 db reads/writes: 11/1 db queries time: 0.16906s ticks: 59 user: 19 sys: 23 cuser: 0 csys: 0 Session (core\session\file): 90 bytes Caches used (hits/misses/sets): 0/0/0" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:02 [error] 31059#31059: *43 FastCGI sent in stderr: "PHP message: PHP Warning:  is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8967" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php?sessionstarted=1&lang=en HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:02 [error] 31059#31059: *43 FastCGI sent in stderr: "PHP message: PHP Warning:  is_executable(): open_basedir restriction in effect. File(/usr/bin/uptime) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8970" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php?sessionstarted=1&lang=en HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:02 [error] 31059#31059: *43 FastCGI sent in stderr: "PHP message: PERF: /b/admin/index.php?sessionstarted=1&lang=en time: 0.64754s memory_total: 25871232B (24.7MB) memory_growth: 24854216B (23.7MB) memory_peak: 27117192B (25.9MB) includecount: 682 langcountgetstring: 12 db reads/writes: 10/0 db queries time: 0.00534s ticks: 70 user: 36 sys: 19 cuser: 0 csys: 0 Session (core\session\file): 135 bytes Caches used (hits/misses/sets): 0/0/0" while reading upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php?sessionstarted=1&lang=en HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"
2016/08/25 10:25:04 [error] 31059#31059: *40 FastCGI sent in stderr: "PHP message: Default exception handler: Installation must be finished from the original IP address, sorry. Debug:
Error code: installhijacked
* line 495 of /lib/setuplib.php: moodle_exception thrown
* line 725 of /admin/index.php: call to print_error()

PHP message: PHP Warning:  is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client0/web4/web:/var/www/clients/client0/web4/private:/var/www/clients/client0/web4/tmp:/var/www/topintaal.be/web:/srv/www/topintaal.be/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client0/web4/web/b/lib/moodlelib.php on line 8967" while reading response header from upstream, client: 109.128.154.247, server: topintaal.be, request: "GET /b/admin/index.php?sessionstarted=1&sessionverify=1&lang=en HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/web4.sock:", host: "topintaal.be"

[/code]

Average of ratings: -
In reply to abe xxs

Re: Error 404 after install

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

For a start... is there a particular reason you are installing the development version? If not, try again with the latest stable branch. It's entirely possible that there are issues with the development version. 

In reply to Howard Miller

Re: Error 404 after install

by abe xxs -

Because with stable version I got exactly same error.

I re--installed stable version and got again the same error ...


In reply to abe xxs

Re: Error 404 after install

by Ken Task -
Picture of Particularly helpful Moodlers

/proc/loadavg which is only provided in the info for footer on all pages
IF perfomance info is turned on in debugging and using a standard theme.

http://site/admin/settings.php?section=debugging

The allowed paths as defined on your server:


/var/www/clients/client0/web4/web:
/var/www/clients/client0/web4/private:
/var/www/clients/client0/web4/tmp:
/var/www/topintaal.be/web:
/srv/www/topintaal.be/web:/usr/share/php5:
/usr/share/php:
/tmp:
/usr/share/phpmyadmin:
/etc/phpmyadmin:
/var/lib/phpmyadmin

These are not within those paths:

/usr/bin/uptime
/proc/loadavg

Looks like if you want those to be displayed one needs to ad those to allowed paths in config of php and nginx.

http://serverfault.com/questions/431200/how-to-add-an-open-basedir-path-in-nginx-vhost

IMHO, This extra info is not something I'd leave on all the time.

'spirit of sharing', Ken