Installation failing on AWS EC2 with Ubuntu 16.04

I followed a standard guide to install Discourse on EC2 using docker by following this link

While running the launcher to install discourse I am getting error something like user requested shut down. Full logs are available here
I saw that people have faced the similar problem on installation through digitalOcean as well which is highlighted in this link in the last comments
But doubt if it can actually be a solution to my problem. I am using t2.micro instance from EC2 which already has 1 GB RAM

Any help or first hand experience will be much appreciated

If you check the error log, you’ll notice errors reported early on in the process.
Install complains that the postgress database already exists, and that role discourse’ already exists.
I also saw an HTTP 429 unknown error, and an error Bundler::HTTPError: Net::HTTPTooManyRequests.
Is it possible that you re-ran install without cleaning-up results from the first install?


Try again. Looks like a temporary rubygems error.

1 Like

Tried removing db information from shared/web_only folder.Now I am not getting db errors but still I am getting HTTP errors.New logs in the link.Please do check if you have any idea

No I am always getting these errors tried multiple times.

This may not fix your problem, but you will likely run into this too.

Be sure to enable swap on the t2.micro instance. If you don’t you’re going to run out of memory catastrophically sooner or later. How to enable swap -Discourse Meta

I’m running on a t2.micro (web only install) with db and redis running on separate boxes (RDS and Elasitcache) and I’ve run out of memory on the t2 instance.

AWS DOES NOT monitor your memory for you, and when your process overruns the amount of available memory it quits in all kinds of weird. These are strange spurious errors (or no error at all) that are hard to track down until you watch your memory use and see it go near zero when the process gets wonky.

Another thing to try: Stop your instance, adjust the instance size to a t2.medium, boot and try again. If everything installs fine you can stop again, downgrade to the t2.micro and boot again.


A big Thanks!! It solved my problem

1 Like