Updating from LAMP 7.3 to new LAMP package
-
Hello,
First, I am very glad to see that Cloudron now has a single LAMP package which allows changing the PHP version internal to that package. It was very frustrating when I had to change PHP versions previously and move my giant LAMP package to a new one involving days of downtime for my site.
Now, I'm looking at having to do that again. Is there any way to upgrade from a LAMP 7.3 package to the current LAMP package without shutting off my site, doing a backup, downloading the backup, and the uploading it to a new LAMP package?
The last time I had to manually migrate from one LAMP package to another there were many server errors because the site's database is so large and in the end Johannes had to make the migration for me (after 3 days of emailing back and forth).
If I can avoid that hassle at all, I would love to! -
@Nicolas
You can potentially avoid a lot of down time by installing the new lamp app at a temp location, move the files for the site, backup the sql database(s) (you can probably just use mysqldump for this if you use the mysql db) and import via phpmyadmin on the new app. Once that's done have the old app change to a temp location and the new app to the old location. Results may vary -
I think OP is asking to upgrade from the very old LAMP 7.3 package to the new one i.e the appstore id has changed. This prevents "clone" from what working easily.
What you do to is:
- Backup
- Download the backup configuration
- Install the new LAMP package is some location
- Import from backup using the backup configuration in step 2 - https://docs.cloudron.io/backups/#import-app-backup
- Once, you are satisfied, you can delete the old app and also move the new app to whatever location you want.
-
@girish Thanks, Grish. This is what I previously had to do to move from 7.2 to 7.3 and it was such a large hassle (requiring a support ticket and manual help from you guys to make the package accept the large backup!) that I avoided ever doing it again. That's why I'm so grateful there's a new package that will handle changing PHP versions a lot easier!
That said, I'm still dreading the downtime and the liklihood that the new package also won't be too pleased about importing such a large backup.
I wonder if there's any reason I couldn't just manually update the PHP version for the app via the console?
-
@Nicolas Which LAMP package are you on? You check the package id in the Update section of the app. In the latest one (package id:
lamp.cloudronapp.php74
) , you can easily switch like so - https://docs.cloudron.io/apps/lamp/#supported-php-versions . Just have to edit a file in the console.(Apologies, I don't quite remember why we had to go via support last time around. But this should not be needed).
-
@girish We're on
App Title and Version
LAMP (PHP 7.3) PHP 7.3
Package Version
lamp.cloudronapp.php73@2.0.0-1It used to be each php version was another package altogether, and you had to migrate to a new package.
We needed support before because the mysql import kept timing out (Johannes told me "For information, there was a REST api timeout hit in the mysql addon, which was hard-coded to 10min.") Ideally that's completely resolved, but I'm bracing myself for the worst again!I am very glad that going forward changing the PHP version will not require moving to a new LAMP package (that seems like a pretty important design flaw that is now resolved).
-
@Nicolas I would suggest trying something like this:
- Clone your current app .
- Install the cloudron CLI tool
npm install -g cloudron
(on your PC/laptop) cloudron login my.domain.com
- Then,
cloudron update --app <appdomain> --appstore-id lamp.cloudronapp.php74
(the appdomain is the domain of the cloned app).
By default, the PHP version is 8.1 . You might want to adjust that as needed if the app does not work.
-
@girish Thank you so much!
This was the simple update method I needed to save a lot of headache. We'll need to edit some things to get ready for 8.1, but know it's as simple as editing a file and rebooting the app is such a relief.Thanks again!