1
0
-1

Everything looks goon on the installation.  A file changed on codeigniter:

/usr/local/open-audit/code_igniter/application/config/database.php

/usr/local/open-audit/code_igniter/application/config/database.php.upgrade

I tried both with and without applying the changes.  Same result. When I logging, I am informed a database upgrade will occur, then when I login, a 505 error.  From that point nothing works and I'm stuck at

http://oa.domain.com/open-audit/index.php/database?action=update

Checking /var/log/httpd/error.log I see this:

[Tue Jun 18 11:13:28.175081 2019] [:error] [pid 13854] [client 192.168.0.20:7734] PHP Parse error:  syntax error, unexpected '==' (T_IS_EQUAL), expecting ')' in /usr/local/open-audit/code_igniter/application/models/m_queries.php on line 251


Have to revert to my old snapshot. (Fortunately I'm running inside VM and made a checkpoint just before the upgrade).

    CommentAdd your comment...

    2 answers

    1.  
      1
      0
      -1

      My apologies - an incorrect closing bracket placement is the cause. I have upgraded several instances from 3.0.2 to 3.1.0 and am wondering why I have done this successfully, but you have not. Anyway, install 3.1.0 again and before running the DB upgrade, replace line 251 in /usr/local/open-audit/code_igntier/application/models/m_queries.php with the below and you should be good to go.

              if (!empty($CI->response->meta->format) == 'json') {

      FWIW - The erroneous line was as below. This is the line to be replaced.

              if (!empty($CI->response->meta->format == 'json')) {
        CommentAdd your comment...
      1.  
        1
        0
        -1

        Great. Tested, everything OK now.  Thanks!

          CommentAdd your comment...