Just to make sure the below points doesnt throw any error, I have tried this on one of the Ubuntu Instances(12.04) to make sure the below steps work. It has worked as expected.
1) Create a complete image backup of the instance before proceeding.
2) Launch a test instance in the same AZ as that of the actual instance. (Lets call this instance "copy")
3) Stop the actual instance and detach the root volume(840 GB) and attach it to the "copy" instance as "/dev/sdf".
4) Create a new 50 GB volume and attach it to the "copy" instance as "/dev/sdg"
5) Format the volume of 50 GB with ext4 filesystem.
sudo mkfs.ext4 /dev/xvdg(or /dev/sdg)
6) Once the 50GB volume has the filesystem, mount both the volumes.(Once you attach the volumes to the instances, it would show the volumes as /dev/xvdf and /dev/xvdg instead of /dev/sdf and /dev/sdg)
mkdir orig
mkdir second
mount /dev/xvdf orig
mount /dev/xvdg second
7) Copy the contents from the 840GB volume to 50 GB volume by running the below command:
rsync -aHAXxSP orig second
8) Once the copy is complete, change the label of the 50GB volume to match the label of the 840GB volume. You can check the label of 840 GB by running the command "blkid".
once you have the label, run the command "e2label /dev/xvdg "cloudimg-rootfs"" [Normally the label on ubuntu root is cloudimg-rootfs"
9) Once it is renamed, go ahead and unmount the 50 GB drive and attach it back to the original instance. Make sure you mount the volume as /dev/sda1 while mounting.
If you want to help you out in any of the steps, please respond to the case and I will call you back as quickly as possible to assist you with the steps.
I also understand that you are not able to get your website backup after stopping and starting the instance.
Initially we got the "502 Gateway error".
After checking the logs, we were able to detect that it was listening on port 8080 which was not up on the instance. We started the tomcat after which port 8080 started. But unfortunately we started getting the error, "HTTP Status 404 - /MarketMaker".
This points to the configuration of the nginx. From the description I could see "The requested resource is not available". You may want to take a look at how the nginx is configured to serve the webpages(Especially location and the proxy options).
Comments
Post a Comment