I had amazon ec2 account. I had an instance which associated with a elastic ip . But when I stop and start the instance then the Elastic ip detached from the instance . I have to associate the elastic ip manually each time after starting the instance. Is there any script for auto attach the elastic ip on starting the instance .? Please let me know.
You can run the below command on your instance start up.
A simple approach is to add a line in /etc/rc.local :
or if as root :