My web site running on EC2 instances. Web servers stores dynamic data in glusterfs servers. When the glusterfs instances are restarted, their ip addresses changes, so that web servers lost the connection to glusterfs.
How could I fix this problem?
This is expected behavior of EC2. If you want more granular control over your IP addressing, you're going to have to create instances inside of a VPC.