Temporary moving website from one to another DA server

Snorky

New member
Joined
Nov 21, 2024
Messages
9
Hi all,

I can imagine this has been asked before, please point me to the right howto or manual, I can't find it.

Currently I have a domain and website running at a webhoster using DirectAdmin. That DNS contains not only the main domain but also subdomains that point to various projects outside of that server.
The website on the main domain (let's call it dadomain.com) is very slow, and I suspect a resource problem. To test this, I started my own VM and instaled Direct Admin Personal on it.

Now the question is; what would be the exact steps to take, to create that same domain in my new da server, make a backup of only the maindomain website dadomain.com inluding mail, ftp etc. and import it into the new server, without running into SSL issues etc. I clean move.
I assume after this move I quickly have to change the DNS settings on the current old server to point to my new DA server, not to miss any order in my webshop.

It may be a temporary test. If the website is equally slow it may really be a software issue and I may piut everything back to where it was with my current host.
 
Personal license is admin + 1 account, so you could do it the easy way.
On the current DA server, use the admin backup/transfer to backup and transfer the account to the other server. You can choose what to backup.

On the other server, as admin, use the admin backup/transfer to restore the account again.
Take care! Note the DNS settings on the bottom of the page, for example be sure you select "restore with current nameservers" otherwise nameservers of the backup are used and most likely on the new server the will not be the same.

Also on restore don't forget to tick the ip of the current server (new server).

Should go smootly, you have them running on 2 servers then and as soon as ou change nameservers or ip's (depending on how you configured it), the site will work on the new server.
To switch back, just switch back the ip's or nameservers and the copy there will work. However, if changes were made on the new server or new mail is arrived, you might need to backup/restore to the new server or maybe it's already enough to rsync the mail and public_html directory backup to the old server or just database, depending on what is in use.
 
Before you testing with other server resource.

Check database query, if any query longer than 5second, that's will cause impact performance in your website.

"DB Monitor" should show all slow query,
 
Awesome replies you both! Thank you. Will give the DB test an attempt first. Some pages take 16 second to build, ridiculous. Will let you know how it goes
 
Before you testing with other server resource.

Check database query, if any query longer than 5second, that's will cause impact performance in your website.

"DB Monitor" should show all slow query,
Seems we had Query Monitor already installed for that reason. The DB queries in total take up max 1,5 second, of which woocommerce and elementor are te biggest, but tother still less than 0,5 second. The page build however takes 15 seconds.
I do see a bunch of 'mistakes' reported and some java and php stuff. The mistakes suggest the translation app to be requesting at the wrong time. Maybe I should disable it. We purchaced wpml-translator, but if that's bad I'd love to hear better suggestions. OUr website should really be in at least 2 languages but both indexed by search engines
 
I never use auto translate in the website. but disable the plugins one by one is good to start to find the problem.

If that's plugin is realtime translate, maybe missing some cache ?
Imagine, 10 customer access your site, every request will send data into translate app ... maybe via CURL. ao that's could slow the page. As you know "CURL" is the hell.

if that's plugin translate via js Ajax, it fine.
 
I never use auto translate in the website. but disable the plugins one by one is good to start to find the problem.

If that's plugin is realtime translate, maybe missing some cache ?
Imagine, 10 customer access your site, every request will send data into translate app ... maybe via CURL. ao that's could slow the page. As you know "CURL" is the hell.

if that's plugin translate via js Ajax, it fine.
I do not have enough technical knowledge to know the difference between CURL and others, but it's not real time translation, it is translated manually to make sure both langauges index well into search engines
 
Ok, I eventually made a backup of the current DA package, copied it onto the new server with DA Personal Plus running on it. On that new server I created a domain with the same domainname and restored the uploaded backup. I used my Windows (sorry) hosts file to point to the new server. I added a testpage.html to make sure it points to the correct location, and that works. Database was created, e-mail boxes are there. Everything looks great. But; white screen. Als in Wordpress Debug mode. So, I wanted to lookup PHP settings. There's hardy any. I can't even see what version it's running. In the manual https://docs.directadmin.com/webservices/php/multiple-php.html I find something about multiple php version so I though I'd give that a go, i believe I was alreayd running 8.3 on the old currect DA server. Guess what, no terminal. The manual says somehting about the terminal being here: https://docs.directadmin.com/other-hosting-services/web-terminal/general.html

But it's not. Do I have an incomplete version or so? I'm confused how to continue.

I used the temrinal direct;y into the VM now and it shows:
php1_mode is already set to php-fpm
php1_release is already set to 8.3

So I guess that means I'm running 8.3 too. Where to set memory limits etc?
 
My mistake, it's not.

Meanwhile, found somehting that may be one of the causes of this not to work, I think it;s in the paths:

In the OLD current DA server I have a reseller package with it's own username 'user1' for instance. Under this reseller package is where the domain is hosted. Now, in the new location it gives errors saying:

'/home/user1/domains/domain.nl/public_html/wordfence-waf.php' (include_path='.:') in Unknown on line 0'

In the new location the File Manager shows a map structure as: MyFiles/ domains/domain.nl
I did not make use of a reseller package on the new server but just run it as the admin user.

What is the best option here to get the whole site in the correct map structure?
 
File Manager shows a map structure as: MyFiles/ domains/domain.nl
Ah yes I see. I don't know why they put it there, it's indeed confusing.

However, the real path is still the same as before like /home/user1/domains etc. except now the user is admin.
So it would be /home/admin/domains etc. now. So for things to work just change user1 to admin in the path and things should work fine.

Normally if you import Wordpress to a new location, you have to change paths too in the settings as admin in Wordpress. I thought this would automatically fix the path for this addon too, seems not then.
 
Thanks Richard, but that path is definitely not in the wordfence-waf.php file. That points to other scripts inside the worfence map. I'm afraid this path may be used all through the WP install?! It feels like it would be way easier to somehow change the user then on either side. Or am I mistaken?
 
No, its just in Wordfence
 
It feels like it would be way easier to somehow change the user then on either side. Or am I mistaken?
Not really, you should know how this can be fix for customers or if you need to move to another account.

Look at the solutions @johannes posted to fix this.
Worst case scenario, download the database, make a backup, then doe a search/replace for user1 to be replaced with admin and restore the database. However... as said, last case scenario.
 
Thanks both. Meanwhile I fixed it myself by simply creating a reseller with the same name as the old server and imported the backup again. Now it works. But the above is good to know for next time, I guess temporary disablign and removing Wordfence during the move would have worked as well then :)
 
Back
Top