User Tools

Site Tools


start:howto:changeip

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
start:howto:changeip [2013/08/14 09:26]
aseques created
— (current)
Line 1: Line 1:
-To change the system ip, it depends on the version you are, basically there are two different cases: 
  
-=== Non released versions, such as 1.1.0-rc3 or newer === 
-In this versions the change is quite simple because the engine allows some reconfigurations (such as this one an others) 
-You only need to do: 
-  cd /​var/​www/​imscp/​engine/​setup 
-  perl imscp-setup --reconfigure ips 
- 
- 
-=== Released stable versions (1.0.3.0) === 
-For the older versions, the change has to be done manually, basically as follows: 
- 
-* Change IP address in /​etc/​imscp/​imscp.conf ​ 
- 
-From: 
-  BASE_SERVER_IP = xxx.xxx.xxx.xxx 
-To: 
-  BASE_SERVER_IP ​ = yyy.yyy.yyy.yyy 
- 
-then, stop the i-mspcp daemon: ​ 
-Code: 
-/​etc/​init.d/​imscp_daemon stop 
- 
-Now we need to change the IP address in database. ​ 
-Also we need to change the domain status from '​ok'​ to '​changed'​ so that the IP address will be replaced by a new one for all domains, subdomains and aliases. ​ 
- 
-  #Connect to mysql: 
-  mysql -u root -p 
-  USE imspcp; 
-  ​ 
-  UPDATE server_ips SET ip_number = "​yyy.yyy.yyy.yyy"​ WHERE ip_id = 1; 
-  UPDATE `domain` SET `domain_status` = '​change'​ WHERE `domain_status` = '​ok';​ 
-  UPDATE `subdomain` SET `subdomain_status` = '​change'​ WHERE `subdomain_status` = '​ok';​ 
-  UPDATE `domain_aliasses` SET `alias_status` = '​change'​ WHERE `alias_status` = '​ok';​ 
-  UPDATE mail_users SET status="​toadd"​ where status="​ok";​ 
- 
- 
-  * Make the system update the domains configuration 
-  /​var/​www/​imscp/​engine/​imscp-rqst-mngr 
- 
-  * Start the i-mspcp daemon: ​ 
-  /​etc/​init.d/​imscp_daemon start 
- 
-  * Finally modify the IP addresse in apache and bind, this can be done with the simple sed onliner below (just replace the word xxx.xxx.xxx.xxx with the new ip yyy.yyy.yyy.yyy: ​ 
- 
-  sed -i "​s/​xxx.xxx.xxx.xxx /​yyy.yyy.yyy.yyy/​g"​ /​etc/​apache2/​sites-available/​* /etc/bind/* /​var/​cache/​bind/​* /​etc/​imscp/​*/​working/​* 
- 
-  * Restart apache and bind:  
-  /​etc/​init.d/​apache2 restart 
-  /​etc/​init.d/​bind9 restart 
- 
-=== More info ===  
- 
-More info on the forum [[http://​forum.i-mscp.net/​Thread-HOWTO-Change-main-i-mspcp-IP-address|here]] 
/var/www/virtual/i-mscp.net/wiki/htdocs/data/attic/start/howto/changeip.1376472393.txt.gz · Last modified: 2013/08/14 09:26 by aseques