What is LAMP? Its actually a short form the expansion of LAMP is
L --> Linux
A --> Apache
M --> Mysql
P --> Php {{ P can be perl or python too }}
These are the basic things which are needed for a web server to work. The steps for installation are for red hat flavoured Linux systems or servers.
Login as root to the server where LAMP is to be installed.
# /etc/init.d/httpd start
Now the apache will be installed and its running. You can verify the installation by giving the command.
# telnet localhost 80 which should give the output silimilar to this
--------------------------------------------------------------
telnet localhost 80
Trying 127.0.0.1...
Connected to localhost (127.0.0.1).
Escape character is '^]'.
--------------------------------------------------------------
To configure apache you will have to edit the configuration file /etc/httpd/conf/httpd.conf. Please make sure to restart apache after editing configuration file for changes to take effect.
#/etc/init.d/httpd restart
# /etc/init.d/mysqld start
Now Mysql is started. We will perform a quick basic setup of mysql now.
Note: For fedora 16/17 users
systemctl start mysqld.service
systemctl enable mysqld.service
# mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 349034 to server version: 4.1.22-standard
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
Set the mysql root password now:
mysql>USE mysql;
(Replace 'yourpass with your required password' in the command below)
mysql> UPDATE user SET Password=PASSWORD('yourpass') WHERE user='root';
mysql> FLUSH PRIVILEGES;
mysql> quit
Bye
Now to login with new details:
mysql -u root -p
Enter Password:
# /etc/init.d/httpd restart
To verify the php installation type the command below:
# php -v
We can also create a php info page to test this.
L --> Linux
A --> Apache
M --> Mysql
P --> Php {{ P can be perl or python too }}
These are the basic things which are needed for a web server to work. The steps for installation are for red hat flavoured Linux systems or servers.
Login as root to the server where LAMP is to be installed.
- APACHE
# /etc/init.d/httpd start
Now the apache will be installed and its running. You can verify the installation by giving the command.
# telnet localhost 80 which should give the output silimilar to this
--------------------------------------------------------------
telnet localhost 80
Trying 127.0.0.1...
Connected to localhost (127.0.0.1).
Escape character is '^]'.
--------------------------------------------------------------
To configure apache you will have to edit the configuration file /etc/httpd/conf/httpd.conf. Please make sure to restart apache after editing configuration file for changes to take effect.
#/etc/init.d/httpd restart
- MYSQL
# /etc/init.d/mysqld start
Now Mysql is started. We will perform a quick basic setup of mysql now.
Note: For fedora 16/17 users
systemctl start mysqld.service
systemctl enable mysqld.service
# mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 349034 to server version: 4.1.22-standard
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
Set the mysql root password now:
mysql>USE mysql;
(Replace 'yourpass with your required password' in the command below)
mysql> UPDATE user SET Password=PASSWORD('yourpass') WHERE user='root';
mysql> FLUSH PRIVILEGES;
mysql> quit
Bye
Now to login with new details:
mysql -u root -p
Enter Password:
- PHP
# /etc/init.d/httpd restart
To verify the php installation type the command below:
# php -v
We can also create a php info page to test this.
0 comments:
Post a Comment