3

Fixing issues after your server was moved

 3 years ago
source link: https://help.dreamhost.com/hc/en-us/articles/216386277-Fixing-issues-after-your-server-was-moved
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Fixing issues after your server was moved

Overview

DreamHost may need to make server changes from time to time in order to optimize the hosting environment and make it more robust and dependable.

This article gives you information on what exactly changes when a server moves and how to resolve any issues.

What changes when a server moves?

Server name

When your server is changed, the name of it also changes. Each shared server at DreamHost has a specific name.

Please review the Finding your FTP server hostname article for information on how to view the name of your web server.

Below are some things you should check prior to the move to ensure that things go as smoothly as possible:

  • Make sure when you connect to your domain via FTP/SFTP/SSH, you use your domain as the hostname.
  • If your domain is example.com, you would enter exactly that as your hostname.
  • Do not add https:// to the URL.

DNS settings

Here are a few steps to set up your DNS settings when a server moves:

  1. Review the email that is sent to you once the server migration has completed – your new server is listed in the Subject line.
  2. If you are not using DreamHost’s nameservers, update your IP address once the server is migrated. If your IP continues to point to the old server IP, your site will not function.
  3. View the DNS article for information on how to find the correct IP address of your site.
  4. If necessary, update the correct IP of your site at the company that hosts your nameservers.

Keep in mind, Unique IPs will change as well since DreamHost does not offer static IP addresses.

Fixing issues after the move

After the migration completes, you may notice errors with your site or you may find it’s not responding as it once did.

The following sections help you troubleshoot the most common causes of this.

My site is not responding

This is most likely a DNS issue. Since the server changed, the IP of the site also changed. At your current DNS host, you must point your DNS to your new DreamHost IP. View the DNS settings section above to correct this.

If your site is correctly pointed to your new DreamHost IP, it's possible you could see a 'Site Not Found' error. View the Site not found article to fix this.

If your site is still not responding, contact DreamHost support for assistance.

My email form or cron job is not working

It's possible to use your servername as part of your email address in a custom email form or cron job. For example, you could use:

[email protected]

In this example, 'username' is your FTP user and 'servername' is the name of your web server. If you're using this format, make sure to update the name of your server you're using for the email address.

My uploaded files do not display online

This is likely because you're using the old server name as your FTP hostname. If you're using something like SERVER.dreamhost.com as your hostname, you'll need to change that to your new server name (which is given to you in the Subject line of the email confirming that you've been successfully moved). Review the Finding your FTP server hostname article for more information on how to view the name of your web server.

An even better idea is to use your domain name. The domain name will automatically point to the correct server no matter where it's moved.

My server key is incorrect

Since you'll be moving to a new server, the SSH keys will also change. If you have the key of the old server saved on your local computer, you'll need to remove it. When you log in to the new server after that, it will prompt you to save the new key.

Here's an example of what it will look like when you log in with an incorrectly saved key:

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 
@ WARNING: POSSIBLE DNS SPOOFING DETECTED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
The RSA host key for www.example.com has changed,
and the key for the corresponding IP address xxx.xxx.x.xxx
is unknown. This could either mean that
DNS SPOOFING is happening or the IP address for the host
and its host key have changed at the same time.
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
0e:c2:f6:f4:d9:86:9d:4b:c4:3d:77:e7:a4:bb:59:14.
Please contact your system administrator.
Add correct host key in /Users/username/.ssh/known_hosts to get rid of
this message.
Offending key in /Users/username/.ssh/known_hosts:3
RSA host key for www.example.com has changed and you have requested
strict checking.
Host key verification failed.

View the following article for instructions on how to resolve this error:

Using Linux (OpenSSH)

The OpenSSH version of SSH provides a command-line utility to remove specific host keys without disturbing the others. This is especially useful if you use SSH to connect to more than one host and you don't want to hand-edit the known_hosts file.

At your shell prompt, type:

[server]$ ssh-keygen -R www.example.com
  • This will create a backup of the ~/.ssh/known_hosts file and remove the old key of www.example.com from the current known_hosts.
  • Repeat as necessary for each domain that was moved.

See also

Did this article answer your questions?


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK