VPN Server – PPTP (Windows XP) & Mikrotik

Tutorial ini berguna untuk mengkoneksikan lan ke VPN server – Mikrotik dengan LAN local kantor

Langsung ajah:
Untuk mengkonfigurasi vpn server mikrotik :

  • Tambahkan bridge agar koneksi vpn client dari luar ke kantor bisa saling terintegrasi. Akses mikrotik menggunakan Winbox, lalu klik “Bridge” yang berada pada bagian kiri layar
  • Klik tombol “+” yang bertitle “Add” dan kasih nama bridge nya. Ubah “ARP” menjadi proxy-arp, lalu tekan tombol “OK”
  • Pada tab “Ports”, Klik tombol “+” yang bertitle “Add”
  • Pilih Interface dengan local kantor, lalu pilih bridge sesuai dengan yang di add sebelumnya. Klik tombol “OK”
  • Selanjutnya adalah menambahkan koneksi VPN nya. Klik “PPP” yang berada pada bagian kiri layar
  • Pilih tab “Interfaces”, Lalu klik “PPTP Server”
  • Klik checkbox “Enabled” yang terletak pada jendela PPTP Server, Lalu klik “OK”
  • Pada tab “Secrets”, Klik tombol “+” yang bertitle “Add”
  • Pada jendela “New PPP Secret”, Masukan Name “zhay”; Password “keren”; Service “pptp”;
  • Caller ID “202.x.x.x” atau dikosongin ajah sehingga bisa didial dari mana saja; Local Address “192.168.x.x” (cari ip kantor yang kosong untuk diberikan pada vpn server); Remote Address “192.168.x.x” (cari ip kantor yang kosong untuk diberikan pada vpn client), Lalu Klik “OK”
  • Setelah selesai, konfigurasikan Windows XP vpn clientnya agar dial ke vpn server mikrotik. Lalu pada mikrotik, buka tab “Active Connections” dan pastikan bahwa koneksi pptp nya sudah nyambung

Untuk kombinasi yang lainnya dapat disesuaikan dengan konfigurasi masing-masing.

Atur dahhh ….
๐Ÿ˜€

Ref :
http://wiki.mikrotik.com/wiki/PPTPServer
http://erwan.blogsome.com/2008/07/23/vpn-di-mikrotik-dengan-pptp

Iklan
Ditulis dalam Tutorial. 3 Comments »

Compiling PvPGN 1.8.3 + PvPGN-Support 1.3 from source on FreeBSD 7

source http://pvpgn.imigi.ro/index.php/Install_on_unix_from_sources
————————————————————————————————
This is a quick simple guide how to compile pvpgn-1.8.3 from source on FreeBSD 7.0

First we need to download the source file from

# cd /usr/local/src
# wget -c http://prdownload.berlios.de/pvpgn/pvpgn-1.8.3.tar.gz
# wget -c http://prdownload.berlios.de/pvpgn/pvpgn-support-1.3.tar.gz
# tar xvfz pvpgn-1.8.3.tar.gz
# tar xvfz pvpgn-support-1.3.tar.gz
# cd pvpgn-1.8.3/src

# ./configure –prefix=/usr/local/pvpgn –with-mysql

Then we compile using gmake
Klo gmakenya not found, maka harus diinstall terlebih dahulu di sysinstall

# gmake

Once compiled correctly with no errors we need to gmake install

# gmake install

Salin file ekstrakan pvpgn-support.
# cd ../../
# cd pvpgn-support-1.3
# cp * /usr/local/pvpgn/var/files

Now we sort out the permissions.
# cd /usr/local/pvpgn
# chown -R root .
# chgrp -R games .
# chown -R games var

Selanjutnya yaitu menambahkan database dan user untuk pvpgn menggunakan mysql.
Pastikan bahwa mysql-server sudah jalan, lalu ketik perintah berikut.
# /usr/local/mysql/bin/mysql โ€“u root โ€“p

Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.0.67-log Source distribution

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the buffer.

mysql>

mysql>CREATE DATABASE pvpgn;
mysql>GRANT ALL PRIVILEGES ON pvpgn.* TO ‘pvpgn’@’localhost’ IDENTIFIED BY ‘password_pvpgn’ WITH GRANT OPTION;
mysql>quit

Selanjutnya adalah ubah konfigurasi bnetd.conf agar support menggunakan mysql-server.
# ee etc/bnetd.conf

Ubah sesuai dengan dibawah ini.
# effective_user = games
# effective_group = games
storage_path = file:mode=plain;dir=
#pidfile = /usr/local/pvpgn/var/bnetd.pid

Menjadi.
effective_user = games
effective_group = games
#storage_path = file:mode=plain;dir=
pidfile = /usr/local/pvpgn/var/bnetd.pid

Dan tambahkan.
storage_path = sql:mode=mysql;host=127.0.0.1;name=pvpgn;user=pvpgn;pass=password_pvpgn;default=0;prefix=pvpgn_

Untuk konfigurasi yang lain dapat diubah sesuai dengan keinginan.

Now that is all done we are ready to start PvPGN Server for the first time.
# cd /usr/local/pvpgn
# sbin/bnetd

Apabila muncul error.
/libexec/ld-elf.so.1: Shared object “libmysqlclient.so.15” not found, required by “bnetd”

Maka, buat link libmysqlclient.so.15 ke direktori /lib
ln -s /usr/local/mysql/lib/mysql/libmysqlclient.so.15 /lib

Cek apakah PvPGN Server sudah jalan atau belum.
# ps axu | grep bnetd
games 93271 0.0 0.4 4780 3924 p0 S 6:41AM 0:00.05 sbin/bnetd
root 93274 0.0 0.1 1632 1004 p0 RL+ 6:41AM 0:00.00 grep bnetd

If you would like to start PvPGN when FreeBSD starts simply add a line to your /etc/rc.local file.

# echo โ€œ/usr/local/pvpgn/sbin/bnetdโ€ >> /etc/rc.local

And we are done!

Aturrr dahhhh

Ditulis dalam Tutorial. 4 Comments »

Compiling PHP 5 from source on FreeBSD 7

source http://pvpgn.imigi.ro/index.php/Install_apache_httpd_with_php_support
http://www.php.net/manual/en/install.unix.apache2.php
————————————————————————————————
This is a quick simple guide how to compile php-5.2.6 from source on FreeBSD 7.0

First we need to download the source file from

# cd /usr/local/src
# wget -c http://id2.php.net/get/php-5.2.6.tar.gz/from/this/mirror
# tar xvfz php-5.2.6.tar.gz
# cd php-5.2.6

Sebelumnya pastikan bahwa paket berikut udah terinstal lewat sysinstall ato pake pkg_add.
gd
libiconv
libxml2
libxslt
perl
png
libmcrypt

# ./configure –prefix=/usr/local/php –with-apxs2=/usr/local/apache2/bin/apxs –with-mysql=/usr/local/mysql –enable-fastcgi –enable-calendar –enable-bcmath –enable-exif –enable-mbstring –with-gettext –with-gd –with-pear –with-mcrypt

# make

Once compiled correctly with no errors we need to make install

# make install

Salin php.ini-recommended ke folder php/lib.
# cp php.ini-recommended /usr/local/php/lib/php.ini

Tambahkan directory /usr/local/php/include pada php.ini dibagian include_path
include_path = “.:/usr/local/php/include”

Apabila ada tambahan konfigurasi bisa edit langsung file /usr/local/php/lib/php.ini

Ubah konfigurasi file apache.
# ee /usr/local/apache2/conf/httpd.conf

Lalu pastikan dan tambahkan entry-an berikut kedalam file konfigurasi apache.
LoadModule php5_module modules/libphp5.so
# lihat seperti contoh di web ini http://www.php.net/manual/en/install.unix.apache2.php
# allow .php, .php2, .php3, .php4, .php5, .php6, and .phtml files to be executed as PHP
SetHandler application/x-httpd-php
# allow .phps files to be executed as PHP source files
SetHandler application/x-httpd-php-source

Lalu ubah entry-an berikut.

DirectoryIndex index.html

Menjadi.

DirectoryIndex index.php index.html

Now that is all done we are ready to restart Apache 2.
# cd /usr/local/apache2
# bin/apachectl restart

Apabila ada tambahan konfigurasi bisa edit langsung file conf/httpd.conf
Untuk mencoba script PHP, buat file index.php dengan contoh berikut.
# ee /usr/local/apache2/htdocs/index.php

Isikan dengan entry-an berikut.

Simpan, lalu buka browser dan arahkan ke http://localhost
Apabila berhasil, maka akan muncul phpinfo

Untuk meng-enable kan tag dapat mengubah isi file /usr/local/php/lib/php.ini
short_open_tag = Off

Menjadi.
short_open_tag = On

Lalu restart apache nya kembali.
# cd /usr/local/apache2
# bin/apachectl restart

And we are done!

Thanks tuk wimbo atas bantuannya ๐Ÿ˜›
Aturrr dahhhh

Ditulis dalam Tutorial. 1 Comment »

Compiling Apache 2 from source on FreeBSD 7

source http://pvpgn.imigi.ro/index.php/Install_apache_httpd_with_php_support
————————————————————————————————
This is a quick simple guide how to compile httpd-2.2.9 from source on FreeBSD 7.0

First we need to download the source file from

# cd /usr/local/src
# wget -c http://apache.the.net.id/httpd/httpd-2.2.9.tar.gz
# tar xvfz httpd-2.2.9.tar.gz
# cd httpd-2.2.9

# ./configure –prefix=/usr/local/apache2 –enable-mods-shared=most –enable-so –enable-cache –enable-file-cache –enable-disk-cache –enable-mem-cache

# make

Once compiled correctly with no errors we need to make install

# make install

Now we sort out the permissions.

# cd /usr/local/apache2
# chown -R root .
# chgrp -R daemon .
# chown -R daemon logs

Now that is all done we are ready to start Apache 2 for the first time.

# bin/apachectl start

Apabila ada tambahan konfigurasi bisa edit langsung file conf/httpd.conf

Ketika ada masalah pada Filter, maka tambahkan accf_http_load=”YES” pada /boot/loader.conf

# echo “accf_http_load=\”YES\”” >> /boot/loader.conf

And we are done!

To start MySQL at anytime simply issue the command

# /usr/local/apache2/bin/apachectl start

If you would like to start Apache when FreeBSD starts simply add a line to your /etc/rc.local file.

# echo โ€œ/usr/local/apache2/bin/apachectl startโ€ >> /etc/rc.local

Aturrr dahhhh

Compiling MySQL 5 from source on FreeBSD 7

source http://blog.bigboylemonade.com/2007/11/24/installing-mysql-5-from-source-on-freebsd-6/
http://dev.mysql.com/doc/refman/5.1/en/freebsd.html
————————————————————————————————————
This is a quick simple guide how to compile mysql-5.0.67 from source on FreeBSD 7.0

First we need to download the source file from

# cd /usr/local/src
# wget -c http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-5.0.67.tar.gz/from/http://mysql.mirror.redwire.net/
# tar xvfz mysql-5.0.67.tar.gz
# cd mysql-5.0.67

Pastikan bahwa menggunakan Bash SHELL
# CC=gcc CFLAGS=”-O2 -fno-strength-reduce” CXX=gcc CXXFLAGS=”-O2 -fno-rtti -fno-exceptions -felide-constructors -fno-strength-reduce”
# ./configure –prefix=/usr/local/mysql –enable-assembler

Then we compile using gmake
Klo gmakenya not found, maka harus diinstall terlebih dahulu di sysinstall

# gmake

Once compiled correctly with no errors we need to gmake install

# gmake install

Once this has been compiled correctly we now need to create a MySQL user.

First we use pw to add the mysql group.

# pw groupadd mysql

Then we create the MySQL user, add the user to the MySQL group and disable shell access.

# pw useradd mysql -g mysql -s /usr/sbin/nologin

Then we lock the account out for security purposes.

# pw lock mysql

Then inside the source directory we need to copy the my.cnf to the /etc directory to tune the different option we may want.

# cp support-files/my-medium.cnf /etc/my.cnf

Now we sort out the permissions and create the initial databases.

# cd /usr/local/mysql
# chown -R mysql .
# chgrp -R mysql .
# bin/mysql_install_db –user=mysql
# chown -R root .
# chown -R mysql var

Now that is all done we are ready to start MySQL for the first time.

# bin/mysqld_safe –user=mysql &

To finalise the installation we just need to set a MySQL root password to secure the database service.

# /usr/local/mysql/bin/mysqladmin -u root password ‘new-password’

And we are done!

To start MySQL at anytime simply issue the command

# /usr/local/mysql/bin/mysqld_safe –user=mysql &

If you would like to start MySQL when FreeBSD starts simply add a line to your /etc/rc.local file.

# echo “/usr/local/mysql/bin/mysqld_safe –user=mysql &” >> /etc/rc.local

Untuk tweaknya bisa menambahkan isian berikut pada /boot/loader.conf.
kern.maxdsiz=”1073741824″ # 1GB
kern.dfldsiz=”1073741824″ # 1GB
kern.maxssiz=”134217728″ # 128MB

Aturrr dahhhh

Ditulis dalam Tutorial. 2 Comments »