Migration of MODX Revo 2.7 to the new hosting

Hi everybody! A super dummy question here (sorry for that).
So I have to migrate a MODX Revo 2.7 website to the new hosting. Normally I would save only assets and config + database of course. Then upload a new MODX, unzip on server, add my old config with updated file path and db connections, run setup and voila. It usually works like a charm.

This time however I used a design theme called Base (quite pretty). I wonder if it is possible to upload everything “as is”? So I uploaded the complete MODX installation (all files from the old server) and updated the Config – expecting this to work. It says “Site temporarily unavailable!” Is it because there are other spots where I need to update paths, etc?

P.S. I don’t give the exact server configuration details, even not sure about the exact MODX version that I had (2.7.2 maybe)… it’s a very generic question, I think. Please advise!

Hey @design4music

If you haven’t already - check the path in the following:

  • /config.core.php
  • /connectors/config.core.php
  • /manager/config.core.php

Then empty your cache folder.

1 Like

OMG, that’s awesome!!! Fixed everything!!!

My case is funny {I think}. I made over 60 websites with MODX (quite decent quality, etc.) but never learned some basics. Also I do something different now; haven’t touched this subject for 2 years and forgot that little I knew. Hence such silly blinders. Thanks a lot!

2 Likes

Glad you got it sorted! :+1:

Hey, @dejaya
Yet another problem with paths. It’s a different site, restoring on the new server from archived download. Old version MODX 2.6.5-pl. This time I stumbled upon uploading extras. I’ve forced removed all extras and re-downloaded them again in Package Manager.
But then I try to install any of them I get this error:

Attempting to install package with signature: breadcrumbs-1.1.0-pl
Package found...now preparing to install.
Target directory is either not a directory or writable: /homepages/5/d329033657/htdocs/fabris/core/packages/
Could not transfer package breadcrumbs-1.1.0-pl.transport.zip to /homepages/5/d329033657/htdocs/fabris/core/packages/.
Could not install package with signature: breadcrumbs-1.1.0-pl

Where the path “/homepages/5/d329033657/htdocs/fabris/core/packages/” is my old path. Of course it is irrelevant!
I made sure to update paths in all 4 config files and empty cache (deleted everything in core/cache).
The problem prevails. The question is where else my old path can be stored?

Any ideas?

Hmm … I’m not sure to be honest.

All paths definitely correct in /core/config/config.inc.php ?

You could try running setup over your site:

  • download your current version [2.6.5]
  • unzip over your site’s files [backup first, of course]
  • go to yoursite.com/setup

I don’t normally find that step is necessary but it can sometimes help iron out issues like this.

Honestly, I don’t understand what’s going on. I’ve done it million times and now it’s like “nothing works”.
I receive all sort of errors during the setup process or when [at best] later - when I configure extras. I am trying to re-install 3 more websites and it is either: no connection with database despite I checked and checked, tried auto and manually… and also wrong paths.

Also the hosting doesn’t allow me to go back to my older version 2.6.5-pl, 2.7.1-pl because of that “curly brackets” error. I can’t go further back than php 7.4… so my options start from MODX version 2.8.0 or 2.8.3 ---- I wonder if the problem is with older database dumps?

I am not a real developer and don’t remember much about MODX anatomy (used to know better) – do we have any version related info in the db?

All in all, sh*tty situation. No easy restore :frowning:

Yes, and the hosting is pretty common - 1and1 aka ionos. I am having these troubles as I move sites from ionos.com to ionos.de (some new US requirements that they don’t allow non-US clients and hey, I am not even from Russia, China or Iran :smiley: It’s the best buddy, Germany… [saying for fun].

I will update here though not directly the topic. This time I am migrating MODX 2.6.5-pl website from ionos.com to ionos.de.
PHP 7.4
MYSQL 5.7
I have unzipped the entire site (with all MODX files and folders) and received red alert “site temporary unavailable”. In the errors log I find these:

[timestamp] (ERROR in xPDOConnection::connect @ [...]/core/xpdo/xpdo.class.php : 3119) SQLSTATE[HY000] [1045] Access denied for user 'username'@'infong-eu378.clienthosting.eu' (using password: YES)
[timestamp] (ERROR @ [...]/core/xpdo/om/xpdoquery.class.php : 652) Could not construct or prepare query because it is invalid or could not connect: SELECT `modSystemSetting`.`key` AS `modSystemSetting_key`, `modSystemSetting`.`value` AS `modSystemSetting_value`, `modSystemSetting`.`xtype` AS `modSystemSetting_xtype`, `modSystemSetting`.`namespace` AS `modSystemSetting_namespace`, `modSystemSetting`.`area` AS `modSystemSetting_area`, `modSystemSetting`.`editedon` AS `modSystemSetting_editedon` FROM `prefix_system_settings` AS `modSystemSetting` 
[timestamp] (ERROR in xPDOConnection::connect @ [...]/core/xpdo/xpdo.class.php : 3119) SQLSTATE[HY000] [1045] Access denied for user 'username'@'infong-eu378.clienthosting.eu' (using password: YES)
[timestamp] (ERROR @ [...]/core/xpdo/om/xpdoobject.class.php : 263) Error preparing statement for query: SELECT `modSystemSetting`.`key` AS `modSystemSetting_key`, `modSystemSetting`.`value` AS `modSystemSetting_value`, `modSystemSetting`.`xtype` AS `modSystemSetting_xtype`, `modSystemSetting`.`namespace` AS `modSystemSetting_namespace`, `modSystemSetting`.`area` AS `modSystemSetting_area`, `modSystemSetting`.`editedon` AS `modSystemSetting_editedon` FROM `prefix_system_settings` AS `modSystemSetting`  -

Access denied is kind of understandable but why? - DB password, etc tripple checked when updated core/config/config.inc.php
The url “infong-eu378.clienthosting.eu” - doesn’t look familiar. It’s not my db server url.

Any help and advise is much appreciated, help!

Download the zip file of your site to your computer and do a text search locally. This string has to be somewhere in one of the files.

1 Like