How to Update Static IP Addresses for Saner App and Database Servers During Data Center Migration

Modified on Sun, 11 May at 3:15 PM

Overview

As part of a data center migration activity, it is necessary to update the static IP addresses of both the Saner App Server and the Database Server. This guide provides step-by-step instructions to correctly configure the new IP addresses on both servers, ensuring a smooth transition without service interruptions.


Prerequisites

  • Access credentials for the hosting platform (e.g., ESXi, vCenter, etc.)

  • Root user access to the App and DB Ubuntu servers

  • New IP addresses assigned for the App and DB servers


Steps to Update the Static IP Address

Step 1: Update the App Server IP Address

  1. Login to the App Server:
    • Access the server via its hosting platform (e.g., ESXi, vCenter).
    • Open a console session and log in.
    • Switch to the root user:

sudo su -

  1. Edit the Netplan Configuration File:
    • Open a terminal and run the following command:

nano /etc/netplan/01-netcfg.yaml

  1. Locate and Update the IP Address:
    • Find the addresses field within the file.
    • Update the current IP address to the new static IP address.


Example – Before update:

yaml

CopyEdit

network:

  version: 2

  ethernets:

    eth0:

      addresses:

        - 192.168.1.100/24

      gateway4: 192.168.1.1

      nameservers:

        addresses: [8.8.8.8, 8.8.4.4]


Example – After update (new IP assigned, e.g., 172.23.35.167):

  1. Save and Exit:
    • Press Ctrl + O to save the file.
    • Press Enter to confirm.
    • Press Ctrl + X to exit the editor.
  2. Verify the YAML File:
    • Validate the configuration:

sudo netplan try

    • If no errors appear, accept the changes.
  1. Apply the Changes:

sudo netplan apply
sudo netpan generate

Step 2: Update the Database Server IP Address

  • Repeat the same steps as above to update the IP address of the Database Server.
  • Example New IP address: 172.23.35.168

Step 3: Update Hostname and Restart Services

  1. Login to Ancor-CLI:
    • Access the Ancor command-line interface.
  2. Update the Hostname:

sethostname <your_domain_or_accessible_URL>

  1. Restart Required Services:

systemctl restart apache2

/etc/init.d/restart tomcatd

  1. Verify Service Status:
    • Check if critical services are running:

netstat -nltp

Step 4: Verify Network Connectivity

  • Ensure communication between the App Server and Database Server.


Commands to Verify:

  • Ping Test:

ping <DB_Server_New_IP>

  • Telnet Test:

telnet <DB_Server_New_IP> <Port_Number>



Note:
In some environments, PING and Telnet may be restricted due to organizational security policies.

If PING and Telnet are not permitted, use the nc (netcat) command:

  • Netcat Test:

nc -vz <DB_Server_IP> <Mongo DB server Port_Number>

Example:

nc -vz 172.23.35.168 27017

  • Similarly, test connectivity to the Saner CVEM cloud server:

nc -vz saner.secpod.com 443


Conclusion

By following the steps outlined above, you will successfully migrate your Saner App and Database servers to the new data center with updated static IP addresses.
It is essential to verify the server’s reachability to both the Database Server and the Saner Cloud Server, and to restart the necessary services to ensure smooth operation after the migration.


If you encounter any issues during the process, please do not hesitate to contact the SecPod Support Team for assistance.



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article