Instalasi FAMP

Instalasi FAMP (Free BSD Apache MySQL PHP dll)

By : Haruno Sajati – Jurusan Teknik Elektro STTA

jati@stta.ac.id

Install SSL

Paket yang diperlukan : openssl-0.9.7e.tar.gz
# tar -zxvf openssl-0.9.7e.tar.gz
# cd openssl-0.9.7e
# ./config –prefix=/usr/local
# make
# make install

# mkdir /home/ssl
# cd /home/ssl
# /usr/local/ssl/bin/openssl genrsa -des3 -rand some_big_file_1:some_big_file_2 -out localhost.key 1024

# /usr/local/ssl/bin/openssl rsa -in localhost.key -out localhost.key.unsecure
# /usr/local/ssl/bin/openssl req -new -key localhost.key -out localhost.key.csr
# /usr/local/ssl/bin/openssl x509 -req -days 30 -in localhost.key.csr -signkey localhost.key -out localhost.cert
# chmod 400 localhost.cert
# chmod 400 localhost.key
# chmod 400 localhost.key.unsecure

Install Apache 2!

1. Langkah pertama download file apache, disini saya menggunakan file apache httpd-2.2.4.tar.gz
2. Login ke freeBSD dengan root
3. Masukkan file httpd-2.2.4.tar.gz ke /usr/src
# cp httpd-2.2.4.tar.gz /usr/src
3. Kemudian masuk ke direktori /usr/src
# cd /usr/src
4. Ekstrak file httpd-2.2.4.tar.gz dengan perintah
# tar -zxvf httpd-2.2.4.tar.gz
5. Kemudian masuk pada derektori hasil ekstrak
# cd httpd-2.2.4
6 kemudian lakukan perintah konfigurasi
Perhatikan tanda (-)
# ./configure –prefix=/usr/local/apache2 –enable-so –enable-auth-digest –enable-rewrite –enable-setenvif –enable-mime –enable-deflate –enable-ssl –with-ssl=/usr/local –enable-headers

7. setelah konfigurasi kurang lebih 15 menit dan gak ada eror jalan kan perintah
# make
# make install
9. Buka file loader.conf : edit /boot/defaults/loader.conf kemudian cari entri berikut ini :

accf_data_load=”NO” # Wait for data accept filter
accf_http_load=”NO” # Wait for full HTTP request accept filter

dan ganti NO dengan YES kemudian save.

10. restart komputer

11. peroses make install selesai masuk pada derektori /usr/local/apache2/bin
# cd /usr/local/apache2/bin
12. kemudian jalakan daemon dari apache dengan perintah
# ./apachectl start
13. untuk mencoba keberhasilan instalasi lihat pada broser ketikkan localhost / pada kompi yang terjaring dengan memanggil ip kompi freeBSD kita
14. kalo ada tertampil pada broser maka kita telah berhasil melakukan instalasi apache

Install MySQL 5!
# tar -zxvf /usr/src/mysql-5.0.54.tar.gz
# cd mysql-5.0.54
# ./configure –prefix=/usr/local/mysql –localstatedir=/var/mysql –without-perl –with-unix-socket-path=/var/mysql/mysql.sock
# make all && make install
# cd /usr/local/mysql/bin/
# ./mysql_install_db –user=root
# ./mysqld_safe –user=root &
# ./mysql -u root -p mysql
-> Enter password:

Jika ada tulisan mysql.sock coba perhatika script no. 7 (harus spesifikasi usernya)
Trus pastikan hostnya pake squid.stta (nama dnsnya)

Install PHP 5!
Paket yang diperlukan :

* PHP 5.0.3 itself – php-5.0.3.tar.bz2
* CURL library – curl-7.12.1.tar.gz
* libiconv library – libiconv-1.9.2.tar.gz
* JPEG library: jpegsrc.v6b.tar.gz
* PNG library: libpng-1.2.8.tar.gz
* cpdflib library: clibpdf202r1.tar.gz
* libxml2-2.6.31.tar.gz

1. Compile libiconv from source:
# cd /usr/local/src
# tar -zxvf libiconv-1.9.2.tar.gz
# cd libiconv-1.9.2
# ./configure –prefix=/usr/local
# make
# make install
2. Compile jpegsrc from source:

# cd /usr/local/src
# tar -zxvf jpegsrc.v6b.tar.gz
# cd jpeg-6b
# ./configure –prefix=/usr/local
# make
# make install-lib

3. Compile libpng from source:
# cd /usr/local/src
# tar -zxvf libpng-1.2.8.tar.gz
# cd libpng-1.2.8
# cp scripts/makefile.linux makefile
# make
# make install

4. Compile cpdflib from source:
# cd /usr/local/src
# tar -zxvf clibpdf202r1.tar.gz
# cd ClibPDF/source
# cp Makefile.Linux makefile
# make
# make install

5. Compile curl from source:
# cd /usr/local/src
# tar -zxvf curl-7.12.1.tar.gz
# cd curl-7.12.1
# ./configure –prefix=/usr/local
# make
# make install

6. Compile libxml2-2.6.31.tar.gz from source:
# cd /usr/src
# tar -zxvf libxml2-2.6.31.tar.gz
# cd libxml2-2.6.31
# ./configure –prefix=/usr/local
# make && make install

7. Extract PHP tarbal
# tar -zxvf php-5.2.4.tar.gz
# cd php-5.2.4
# ./configure –with-apxs2=/usr/local/apache2/bin/apxs –with-mysql=/usr/local/mysql –with-mysqli=/usr/local/mysql/bin/mysql_config –with-mysql-sock=/tmp/mysql.sock –with-sqlite –enable-sqlite-utf8 –with-zlib –with-zlib-dir –with-bz2 –with-gd –enable-gd –enable-gd-native-ttf –with-ttf –with-iconv=/usr/local –with-curl=/usr/local –enable-track-vars –with-config-file-path=/usr/local/apache2/conf –enable-trans-id –enable-ftp –with-cpdflib=/usr/local –enable-mbstring –with-openssl=/usr/local/ssl –with-jpeg=/usr/local/ –with-jpeg-dir=shared,/usr/local –with-png-dir=shared,/usr/local

# make && make install
# cp php.ini-dist /usr/local/apache2/conf/php.ini
# edit /usr/local/apache2/conf/php.ini
mysql.default_socket = /var/mysql/mysql.sock
short_open_tag = Off
register_globals = Off
allow_url_fopen = Off

# apachectl graceful
Install phpMyAdmin!

Paket yang diperlukan:
* phpMyAdmin-2.5.5.tar.gz

extract:
# tar -zxvf phpMyAdmin-2.5.5.tar.gz
# mv phpMyAdmin-2.5.5 /usr/local/apache2/htdocs/phpmyadmin (tergantung posisi DocumentRoot anda. Kadang ada di /var/www/html dsb)

# cd /usr/local/apache2/htdocs/phpmyadmin
# edit config.inc.php
$cfg['Servers'][$i]['host'] = ‘squid.stta’;
$cfg['Servers'][$i]['port'] = ”;
$cfg['Servers'][$i]['socket'] = ‘/var/mysql/mysql.sock’;
$cfg['Servers'][$i]['auth_type'] = ‘http’;
$cfg['Servers'][$i]['user'] = ‘root’;
$cfg['Servers'][$i]['password'] = ”;
$cfg['Servers'][$i]['only_db'] = ”;

Tambahkan baris berikut pada httpd.conf

AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps

Install Webmin!

# tar -zxvf webmin.xx.xx.tar.gz
# cd webmin.xx.xx
# ./setup.sh
# berikan username, password dan port yang digunakan
# berikan autostart
# jalankan pada client http://192.168.10.4:10000
# Jika database mysql tidak bisa dibuka, ubah module confignya. atur path untuk menjalankan mysql
# Jika apache tidak jalan, atur module confignya
# perhatikan bagian Path to httpd executable // yang ditanyakan dimana file apachectlnya : jawab /usr/local/apache2/bin/apachectl (tergantung posisi file executabel apachectl anda)

Finish (Dari Berbagai Sumber)!!

Seting Warnet dengan menggunakan modem D-Link untuk Speedy

Seting Warnet dengan menggunakan modem D-Link untuk Speedy.pdf

Sori dalam pdf. Banyak gambarnya soalnya. Males upload satu-satu. Smoga membantu…