I am using java api for EC2 instance creation.
While creating EC2 instance i want to install MYSQL server on that instance.
So how can i install MySQL server on EC2 instance by passing user data ?
I am using java api for EC2 instance creation.
While creating EC2 instance i want to install MYSQL server on that instance.
So how can i install MySQL server on EC2 instance by passing user data ?
writing the user-data script is as simple as writing an bash script. Follow the example and illustration
Its pretty good for newbies. (Disclaimer: I have absolutely nothing to do with the website/blog or the author of the article)
You probably wouldn't want to install MySQL as part of a start-up script via user-data. In fact, you would likely only want to work with EBS-backed instances if you have the need to actually persist your data in MySQL between instance restarts. In this case, you would have to have MySQL as part of your AMI, so there would be no need to install it on startup.