Unable to run Upgrade

Talks about metering
Post Reply
robinc
Posts: 15
Joined: Wed Jul 13, 2016 2:07 pm

Unable to run Upgrade

Post by robinc » Thu Oct 17, 2019 12:43 pm

Hi jeanmarc

I am currently unable to run the Upgrade process either for meterN or for 123solar.

In both cases, it reaches the _INSTALL/updater.php page which simply displays 'ERROR'
Looking at updater.php, I modified the ERROR message to display CURDIR and SRVDIR.
It seems that the Session variables $_SESSION['CURDIR'] and $_SESSION['SRVDIR'] are returning empty strings.

I have been running metern 0.8.4 and 123solar 1.8.1 for the past 2years without any problems but
decided that it was time to bring things up to date.

I have recently done a full system upgrade ( pacman -Syu ) and everything continues to run smoothly except that
I am unable to get an Update to run .....

Distro is Arch ARM, PHP version is 7.3.10 :-

[-@pw-archpi ~]$ uname -a
Linux pw-archpi 4.19.76-1-ARCH #1 SMP PREEMPT Tue Oct 8 03:34:09 UTC 2019 armv7l GNU/Linux

[-@pw-archpi ~]$ pacman -Qs php
local/php 7.3.10-1
A general-purpose scripting language that is especially suited to web development
local/php-cgi 7.3.10-1
CGI and FCGI SAPI for PHP
local/php-fpm 7.3.10-1
FastCGI Process Manager for PHP
_INSTALL/updater.php

Any suggestions for further troubleshooting ?

Thanks as always .....

jeanmarc
Posts: 1866
Joined: Thu Aug 29, 2013 7:16 am

Re: Unable to run Upgrade

Post by jeanmarc » Thu Oct 17, 2019 7:27 pm

Hi,
Make sure your read the release notes. I have pass under HTTPS since 0.9, you should change some files
You can also use admin/update.php and updater.php from the latest if you wish.
That should do the trick
For 123s it use HTTPS since 1.8, you have problem ?

robinc
Posts: 15
Joined: Wed Jul 13, 2016 2:07 pm

Re: Unable to run Upgrade

Post by robinc » Fri Oct 18, 2019 12:29 am

Yes, I am aware of the https change and have done the change for previous upgrades.

The upgrade process successfully detects the available new release and fails as described when attempting to start the actual upgrade.

robinc
Posts: 15
Joined: Wed Jul 13, 2016 2:07 pm

Re: Unable to run Upgrade

Post by robinc » Fri Oct 18, 2019 1:56 am

OK, so I have just discovered that /var/log/nginx/error.log is full of the following error messages :-

Code: Select all

2019/10/17 22:12:06 [error] 284#284: *85 FastCGI sent in stderr: "PHP message: PHP Warning:  session_start(): open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (/dev/shm:/srv/http/:) in /srv/http/_INSTALL/updater.php on line 2PHP message: PHP Warning:  session_start(): Failed to initialize storage module: files (path: ) in /srv/http/_INSTALL/updater.php on line 2PHP message: PHP Notice:  Undefined variable: _SESSION in /srv/http/_INSTALL/updater.php on line 3PHP message: PHP Notice:  Undefined variable: _SESSION in /srv/http/_INSTALL/updater.php on line 4" while reading response header from upstream, client: 127.0.0.1, server: localhost, request: "GET /_INSTALL/updater.php HTTP/1.1", upstream: "fastcgi://unix:/run/php-fpm/php-fpm.sock:", host: "127.0.0.1:8083", referrer: "http://127.0.0.1:8083/123solar/admin/update.php"

jeanmarc
Posts: 1866
Joined: Thu Aug 29, 2013 7:16 am

Re: Unable to run Upgrade

Post by jeanmarc » Fri Oct 18, 2019 6:34 am

Thanks for letting us know. I have to look back in 0.8.4 code but i guess you should have no problem with latest update.

robinc
Posts: 15
Joined: Wed Jul 13, 2016 2:07 pm

Re: Unable to run Upgrade

Post by robinc » Fri Oct 18, 2019 11:54 am

Hi,
It turns out that the problem was due to an old php.ini file.

Earlier versions of php had open_basedir set by default, and in my case this excluded access to /tmp.
php 7 and later leaves open_basedir unset by default.

I can now run the updater for both metern and for 123solar ....
Thanks ...

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests