murze
murze

Reputation: 4103

How to start Apache on EC2

I'm an absolute newbie to EC2. My goal is to run a php-mysql-website on EC2.

I've just setup a new instance based on this ami

It seems that apache isn't running? How do I start apache? Is there a general tutorial on how to start EC2 as a web server?

Thanks!

Upvotes: 9

Views: 25799

Answers (5)

Paul Preibisch
Paul Preibisch

Reputation: 4322

If you are running bitnami's Drupal Stack, you can

1) cd /opt/bitnami 2) sudo bash (enter password) 3) sh ctlscript.sh restart

this will restart the LAMP stack

Upvotes: 0

Brij Raj Singh - MSFT
Brij Raj Singh - MSFT

Reputation: 5113

sudo apt-get update sudo tasksel

and enjoy.

Upvotes: 0

Hasanavi
Hasanavi

Reputation: 8615

Well, you need to set up a LAMP server. To install LAMP server with one command, try the following:

sudo apt-get install lamp-server^ 

Note that the last ^ is not a typo, it's included in the command. See this page for more information.

Upvotes: 0

scientastic
scientastic

Reputation: 171

It really depends on the distribution you have chosen. Typically, though, you can start Apache using the init scripts. For example, on Ubuntu server it will be:

sudo /etc/init.d/apache2 start

On CentOS or Redhat it might be:

sudo /etc/init.d/httpd start

Upvotes: 9

Brandon Frohbieter
Brandon Frohbieter

Reputation: 18139

For Suse 11, try

 rcapache2 status
 rcapache2 start

If it is not installed, you can install with

yast2 --install apache2

for a tutorial on LAMP with this server, check

http://www.susegeek.com/internet-browser/install-configure-lamp-apachemysqlphp-in-opensuse-110/

Upvotes: 7

Related Questions