Skip to main content

Cara Install Webserver Menggunakan LAMP di Ubuntu Linux

Cara Install Webserver Menggunakan LAMP di Ubuntu Linux


Jika anda pengguna Linux Ubuntu atau distro lain dengan basis debian. Berikut cara membuat webserver di localhost komputer anda dengan menggunakan LAMP ( Linux, Apache, Mysql, PHP ) .



Untuk persiapan proses instalasi ini dibutuhkan koneksi internet.  Setelah Komputer anda dengan distro kesayangan anda sudah terkoneksi dan buka terminal linux anda dengan Ctr+Alt+t atau melalui " Applications > Accessories > Terminal   lalu kita mulai dengan menjalankan perintah-perintah dibawah ini :
1. Install Apache2 .
$ sudo apt-get install apache2
Setelah selesai install apache2, buka browser dan ketikkan pada address bar: localhost atau 127.0.0.1 . Jika yang terlihat adalah tulisan:
It works
berarti Apache kita sudah bekerja baik, tapi jika terdapat pesan error (kebetulan mengenai saya) seperti ini :
Could not reliably determine the server�s fully qualified domain name, using 127.0.1.1 for ServerName
kita bisa memperbaiki dengan cara :
$ gksu gedit /etc/apache2/conf.d/fqdn
ketika aplikasi Gedit sudah terbuka, ketik ServerName localhost di dalam file tersebut dan jangan lupa klik simpan kemudian bisa ditutup.
2. Install php5
$ sudo apt-get install php5 libapache2-mod-php5
agar php5 bisa jalan, kita restart dulu apache2 kita, untuk merestart apache, jalankan perintah ini :
$ sudo /etc/init.d/apache2 restart
untuk memeriksa apakah php5 sudah jalan atau belum, caranya :
membuat file php baru di dalam
/var/www/folder
, caranya :
$ sudo gedit /var/www/phpinfo.php
setelah aplikasi gedit terbuka, silakan isikan :
<?php phpinfo();
?>
buka browser lagi dan ketikkan pada address bar :
http://localhost/phpinfo.php
Jika melihat phpinfo() dan informasi installasi tentang php, berarti sudah benar dan bisa dilanjutkan. Perhatikan gambar di bawah :

3. Install mysql

$ sudo apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql

Di akhir installasi kita diharuskan mengisi password root atau admin.

4. Installasi phpmyadmin

$ sudo apt-get install phpmyadmin

pada saat dalam proses instalasi kita diminta untuk memilih server web ( Please choose the web that should be automatically configured to run phpMyAdmin ) yang digunakan pilihlah apache2 dengan tombol space.
Secara default phpMyAdmin akan terinstall ke dalam
/usr/share/ ( /usr/share/phpmyadmin/direktori )
. Kita salin terlebih dahulu ke dalam
/var/www( /var/www/direktori ).
Untuk menyalin, silakan ketikkan perintah :

$ sudo ln -s /usr/share/phpmyadmin/ /var/www/phpmyadmin

Untuk mencoba apakah berhasil atau belum, silakan buka kembali browser dan ketikkan pada address bar :

http://localhost/phpmyadmin/index.php

Untuk mysql biasanya usernamenya root, password silakan yang tadi telah dibuat dalam installasi mysql.

5. Mengganti tampilan awal localhost/server web.

Default-nya ketika kita mengetikkan localhost pada browser akan diredirect ke halaman index.html yang telah ada Kita bisa mengedit halaman tersebut sesuai  yang kita inginkan, caranya:

$ sudo gedit /var/www/index.html


Anda juga bisa membuat halaman index tersendiri yang lebih menarik.
Nah saat ini komputeranda sudah memiliki webserver localhost sendiri. Anda bisa mengeksplore kemampuan anda mendesain web lewat localhost ini, bisa menggunakan wordpress, joomla, drupal atau banyak source web lain. Jadi nanti untuk meletakan sourcenya, letakan di root tepatnya di folder
/var/www/
.


go to link download

Popular posts from this blog

GDB Leônico 2014 By Jailson

GDB Leônico 2014 By Jailson go to link download

Picasa 3 9 0 Build 135 81 Portable Multimedia

Picasa 3 9 0 Build 135 81 Portable Multimedia Picasa is a free software  download from  Google that helps you: * Locate and organise all the  photos  on your computer. * Edit and add effects to your  photos  with a few simple clicks. * Share your  photos  with others through email,  prints  and on the web: it�s fast, easy and free. Take your  photos  further with Picasa from Google Organise Picasa instantly locates and organises all the pictures on your computer. Find the pictures you forgot you had. Picasa organises your entire collection while you watch, scanning the images on your computer and automatically sorting them by date. Move and re-name pictures from inside Picasa. Want to clean up messy folders and move pictures around on your computers hard drive? Simply drag and drop pictures from one folder in Picasa to another. Picasa will make the change permanent after double-checking with you. Want to change a pictures filen...

Smartphone 5 5 inch display 2560 x 1440 pixels Owned LG Carrying 538 PPI

Smartphone 5 5 inch display 2560 x 1440 pixels Owned LG Carrying 538 PPI Hello Friend Voltshare Now i will discuss about Smartphone 5.5-inch display 2560 x 1440 pixels Owned LG Carrying 538 PPI  and previously I have made an article about  Rumor: AMD will be shipped GPU Architecture-Based New Upper Class in October LG Display has just announced the 5.5-inch screen smartphone with stunning resolution, 2560 x 1440 pixels with a pixel density of 538 PPI. According to LG, the screen is also the thinnest panel is only 1.21 mm. By comparison, Apples iPhone 5 has 326 PPI, Samsung Galaxy S4 has 441 PPI and 468 PPI HTC has, means new screens LG brings 15% more pixels per inch than the HTC One! Tags: lg , 5.5-inch , 2560 x 1440 , smartphone display , 538 ppi go to link download