The new update crashed my installation (and yes I run php7)

OK, I’m gonna try again, I don’t want to be stuck on legacy software forever even if 3.9.2 is a pretty acceptable release.

I have :

  • The database I sent you and a working 3.9.2 release.
  1. I try :
    php artisan ninja:update-key --legacy=true

and I get that

[Symfony\Component\Console\Exception\RuntimeException]
The “–legacy” option does not exist.

  1. It’s alright, I’m gonna upgrade to 4.0.0 with the pastebin script.

and I get an EXPECTED Whoops, looks like something went wrong.

  1. php artisan ninja:update-key --legacy=true

Thu, 14 Dec 2017 17:43:21 +0000 Running UpdateKey…
Thu, 14 Dec 2017 17:43:21 +0000 Successfully updated the key, set the cipher in the .env file to AES-256-CBC

  1. I set the cipher.

  2. Well, you’re right. It works.

Thank you very much.

Great to hear!

I am having this issue with the client site after login. The main site works as it should, I can create invoices and customers, the full works, no problems there, but when I visit the new client login link and attempt to login i get the ‘Whoops’ message. I updated my site the old way, made a backup then copied over the install directory.

Have you updated to v4.0.1?

I am doing it right now. Will let you know how it goes.

Having the same problem, I followed the instructions in this comment, and I’m getting the following errors:


  [Illuminate\Database\QueryException]                                                         
  SQLSTATE[42S22]: Column not found: 1054 Unknown column 'google_2fa_secret' in 'where clause  
  ' (SQL: select * from <code>users</code> where <code>google_2fa_secret</code> !=  and <code>users</code>.<code>deleted_at</code> is nul  
  l)                                                                                           
                                                                                               

                                                                                               
  [Doctrine\DBAL\Driver\PDOException]                                                          
  SQLSTATE[42S22]: Column not found: 1054 Unknown column 'google_2fa_secret' in 'where clause  
  '                                                                                            
                                                                                               

                                                                                               
  [PDOException]                                                                               
  SQLSTATE[42S22]: Column not found: 1054 Unknown column 'google_2fa_secret' in 'where clause  
  '

Note that I was trying to update from v3.7.2 to v4.0.1; I had tried updating to v3.9.2 first and kept running in to the issue noted in the original post…

What do you see if you load /update (or /public/update)

I keep running in to this same problem, it’s driving me crazy. I just tried to update from v3.7.2 to v4.1.5, and got the error The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths. I tried changning from rijndael_128 to AES-256-CBC in my .env, then running php artisan ninja:update-key --legacy=true, but then I get the error The only supported ciphers are MCRYPT_RIJNDAEL_128 and MCRYPT_RIJNDAEL_256. I then tried running php artisan ninja-update-key (no –legacy=true), and got the error The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths..

I have no idea what the problem is, I’m rolling back my server as I type this. I’ve tried running updates many times, and I can’t get it to work. What am I doing wrong, and how do I fix this?

You need to run ninja:update-key before changing the APP_CIPHER value.

Okay, so I just updated to v3.9.2, then to v4.1.5, ran ninja:update-key without making any changes to .env, and it did successfully update the cipher & key, but I still get the error The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths. when trying to visit the site.

EDIT: Oh wait! I just noticed it didn’t update the “cipher” value in .env; updated that manually and it appears to be working. Thanks for the help!

Steps I took for anyone in the same situation as me:

  1. Create a backup (just in case)
  2. Update to v3.9.2
  3. Create another backup (just in case)
  4. Update to v4.1.5
  5. Run sudo php artisan ninja:update-key --legacy=true
  6. Change the value of APP_CIPHER in .env to AES-256-CBC
  7. Run sudo composer dump-autoload
  8. Visit https://www.example.com/update
  9. It works!
  10. Create a final backup (just in case)

The script only updates the key, it should display a message telling you to manually change the cipher.

Great to hear!!

Yea, noticed that just after posting, thanks for the help ?