Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Changed IP address, nginx won't start #160
setup is: _Ubuntu 10.04 minimal in a Virtualbox vm, installed with all the optional additions, manually setting _MY_OWNIP (originally 192.168.0.104), _MY_HOSTN, and MY_FRONT.
Objective is to build the VM locally, and then push it to another network, where it is used in closed network for demos/training, and so at the moment I am struggling a bit with the service(s) reaction to changing _MY_OWNIP after the successful installation.
So, when on a different network bridged to a DHCP source (yes, I know..), I changed 192.168.0.104 to the new address it bound to, in
/etc/hosts /etc/nginx/conf.d/aegir.conf /etc/bind/named.conf.options
.. Restarted networking and bind, and then due to nginx start issues, restarted the server then tried to start nginx again with
nginx: [emerg] bind() to 192.168.0.104:80 failed (99: Cannot assign requested address)
Now this _MY_OWNIP address is no longer in the above files, or in /etc/nginx/* and I can't tell if nginx is looking to bind to confirm before starting, or where else it is getting this 192.168.0.104 from.
2010/12/21 12:25:07 [emerg] 3039#0: bind() to 192.168.0.104:80 failed (99: Cannot assign requested address)
Is nginx trying to resolve itself via /etc/resolv.conf and not /etc/hosts as a check before starting up?
Maybe I should just start again without bind, but then again the issue might be nginx and not related to bind, or pdnsd, not that I can actually find the pdnsd config files (/etc/default/?).
Then I turned eth0 to a static rather than DHCP address, and to try and force some local resolution. Same issue. Knowing which files need updating on an address change would solve all the above, but I can't figure out where else _MY_OWNIP is set despite trying to read through its inner workings.
The LOCALHOST ON LOCAL NETWORK Barracuda script section sure looks interesting... despite - or because of - the warnings :)
Finally just to add that what was already an amazing script has moved on considerably since I last used it. Brilliant stuff, and happy to report I've evangelized a few people in to using Barracuda :) Thanks again!
This comment has been minimized.
This comment has been minimized.Show comment Hide comment
To change the IP of already installed Aegir system/hostmaster you need to start with some manual IP changes first in listed below files:
A. In the Barracuda main hostmaster:
B. In the Octopus hostmaster (if used):
C. Update the IP/name of database in your hostmaster site settings.php
Now you will be able to start Nginx:
Now it is a time to log into the Aegir control panel and go to the server node edit form, where you need to change/update its IP address. It will cause all platforms re-verify. Then you can re-verify all sites to update their settings.php files.
Thanks for your kind words! :)