Search Linux Here

Google
 
Showing posts with label server. Show all posts
Showing posts with label server. Show all posts

Monday, February 25, 2008

Install MySQL Server 5 on Ubuntu

Installing MySQL 5 Server on Ubuntu is a quick and easy process. It almost feels like it should be more difficult.

Open a terminal window, and use the following command:

# sudo apt-get install mysql-server

If you are running PHP you will also need to install the php module for mysql 5:

# sudo apt-get install php5-mysql

To create a new database, use the mysqladmin command:

# mysqladmin create

After that is finished, you can test MySQL by running this, where zzzz is your password

# mysql -uroot -pzzzz

See, really easy!

Installing PHP in UBUNTU

This is a way to install PHP, type or paste this into your terminal:

# sudo apt-get install php5 libapache2-mod-php5

Once it's finished installing, restart apache, using:

# sudo /etc/init.d/apache2 restart

Testing PHP
Now, let's make sure that PHP is working properly. To do this, we're going to run phpinfo(). You can, of course, swap out gedit with your editor of choice.

# sudo gedit /var/www/phpinfo.php



Type or paste the following into the document, and save it. (remove the space before the '?php')

< ?php phpinfo(); ?>


Now we can test PHP by browsing to:

http://localhost/phpinfo.php



Installing apache on Ubuntu

This How-to is to get the latest apache .. I Hope this article can help U to install apache..

To get Apache, try type this code in terminal
# sudo apt-get install apache

or
# sudo apt-get install apache2

after that, you can test your apache with this code :
# firefox "http://localhost"

or
# http://localhost

Once apache2 is done installing, you can go ahead and test it by using:
# sudo /etc/init.d/apache2 start

I hope this article can help u to build a web server....:)