Your JoeDog was down this morning. This site is hosted on the free plan at Amazon Web Services. Through the EC2 web portal, he was able to read the console logs of the downed instance. It was filled with entries which looked like this:
9443.085875 Write-error on swap-device (202:0:10258840)
9443.085875 Write-error on swap-device (202:0:10295632)
9443.085875 Write-error on swap-device (202:0:10320576)
9443.085875 Write-error on swap-device (202:0:10336216)
9443.085875 Write-error on swap-device (202:0:10395280)
So Your JoeDog plugged that error into the Google machine and it produced this Amazon EC2 forum entry. The Amazon rep asked that troubled soul if he could stop and start his instance. So Your JoeDog did a stop and start. That didn’t solve his problem, either. In the end, he was forced to clone the volume and bring up a whole new server. He took the opportunity to add more memory. Yeah, that means he’s no longer on the free plan but he can’t deal with the low-memory micro instance for another second. Not. One. More. Second.
So if you’re a troubled soul who found this entry because you googled “Write-error on swap-device” for your downed EC2 instance, here’s how you bring up a clone.
- EC2 Dashboard => Instances (select downed instance)
- Actions => Image => Create image (that’s going to take a while)
- On the left nav: Images => AMIs (select the new one)
- Select it, then hit Launch. (follow the instructions)
Once your new server is up and running, log in and scrutinize the environment. You should have all the content that was one the old one. It is, afterall, a clone. Once you’re feeling good about the new server, you can terminate the old one and delete the old image.