CARA GABUNG DUA KONEKSI SPEEDY DI SATU ROUTER


Berikut contoh implementasi load balance dua koneksi sesuai judul di atas. Dijalankan di mesin OpenBSD sebagai NAT router dengan dua koneksi DSL Telkom, interface ethernet sk0 dan sk1.

1. Aktifkan forwarding di /etc/sysctl.conf

net.inet.ip.forwarding=1

2. Pastikan konfigurasi interface dan default routing kosong, hanya filename saja

# /etc/hosts.sk0
# /etc/hosts.sk1
# /etc/hostname.sk0
# /etc/hostname.sk1
# /etc/mygate

Script koneksi DSL Speedy, pppoe0 untuk koneksi pertama dan pppoe1 untuk koneksi kedua. Sesuaikan interface, username dan passwordnya. Jangan lupa, gunakan indent tab.

# /etc/ppp/ppp.conf
default:
        set log Phase Chat LCP IPCP CCP tun command
        set redial 15 0
        set reconnect 15 10000
pppoe0:
        set device "!/usr/sbin/pppoe -i sk0"
        disable acfcomp protocomp
        deny acfcomp
        set mtu max 1492
        set mru max 1492
        set crtscts off
        set speed sync
        enable lqr
        set lqrperiod 5
        set cd 5
        set dial
        set login
        set timeout 0
        set authname blahblahblah@telkom.net
        set authkey asaljangandejek
        add! default HISADDR
        enable dns
        enable mssfixup
pppoe1:
        set device "!/usr/sbin/pppoe -i sk1"
        disable acfcomp protocomp
        deny acfcomp
        set mtu max 1492
        set mru max 1492
        set crtscts off
        set speed sync
        enable lqr
        set lqrperiod 5
        set cd 5
        set dial
        set login
        set timeout 0
        set authname blahblahblah2@telkom.net
        set authkey vikingboneksamasaja
        add! default HISADDR
        enable dns
        enable mssfixup

3. Aktifkan interface sk0 dan sk1

# ifconfig sk0 up
# ifconfig sk1 up

4. Jalankan PPPoE, Point to Point Protocol over Ethernet.

# ppp -ddial pppoe0
# ppp -ddial pppoe1

5. Jika koneksi Speedy berhasil, IP address dari Speedy akan di-binding di interface tunneling tun0 dan tun1

# ifconfig
tun0: flags=8051 mtu 1492
        groups: tun egress
        inet 125.xxx.xxx.113 --> 125.163.72.1 netmask 0xffffffff
tun1: flags=8051 mtu 1492
        groups: tun
        inet 125.xxx.xxx.114 --> 125.163.72.1 netmask 0xffffffff

6. Dan default gateway akan aktif

# netstat -nr |more
Routing tables
Internet:
Destination        Gateway            Flags    Refs      Use    Mtu  Interface
default            125.163.72.1       UGS         7    17529      -   tun0

7. Serta konfigurasi resolver DNS pun akan terisi

# cat /etc/resolv.conf
lookup file bind
nameserver 202.134.2.5
nameserver 203.130.196.5

8. Aktifkan Packet Firewall pf

# /etc/rc.conf
pf=”YES”

9. Script Packet Firewall NAT dan balancing dengan round-robin (ganti round-robin dengan loadbalance jika lebih sesuai dengan kebutuhan anda). Baris yang di-indent masih termasuk baris di atasnya. Entah kenapa tag <pre> malah menghilangkan karakter backslash (\).

# /etc/pf.conf
lan_net = "10.0.0.0/8"
int_if  = "vr0"
ext_if1 = "tun0"
ext_if2 = "tun1"
ext_gw1 = "125.163.72.1"
ext_gw2 = "125.163.72.1"
# scrub all
scrub in all
#  nat outgoing connections on each internet interface
nat on $ext_if1 from $lan_net to any -> ($ext_if1)
nat on $ext_if2 from $lan_net to any -> ($ext_if2)
#  pass all outgoing packets on internal interface
pass out on $int_if from any to $lan_net
#  pass in quick any packets destined for the gateway itself
pass in quick on $int_if from $lan_net to $int_if
#  load balance outgoing tcp traffic from internal network.
pass in on $int_if route-to \
    { ($ext_if1 $ext_gw1), ($ext_if2 $ext_gw2) } round-robin \
    proto tcp from $lan_net to any flags S/SA modulate state
#  load balance outgoing udp and icmp traffic from internal network
pass in on $int_if route-to \
    { ($ext_if1 $ext_gw1), ($ext_if2 $ext_gw2) } round-robin \
    proto { udp, icmp } from $lan_net to any keep state
#  general "pass out" rules for external interfaces
pass out on $ext_if1 proto tcp from any to any flags S/SA modulate state
pass out on $ext_if1 proto { udp, icmp } from any to any keep state
pass out on $ext_if2 proto tcp from any to any flags S/SA modulate state
pass out on $ext_if2 proto { udp, icmp } from any to any keep state

10. Aktifkan script yang diperlukan di /etc/rc.local agar setiap reboot langsung bekerja.

ifconfig sk0 up
ifconfig sk1 up
# aktifkan speedy
ppp -ddial pppoe0
ppp -ddial pppoe1

PF akan langsung bekerja membaca /etc/pf.conf.
Jika harus me-restart koneksi DSL Speedy, pastikan pppoe dimatikan dulu

# pkill ppp

Jika tidak, maka ppp akan membuat tunneling baru menjadi tun2, tun3 dan seterusnya.

11. Untuk memantau fungsi nat pool round-robin di atas bekerja atau tidak, bisa menggunakan tools pftop yang bisa diambil di http://www.eee.metu.edu.tr/~canacar/pftop/

Jika anda mengoptimasikan koneksi jaringan juga dengan menggunakan proxy, misalnya Squid, maka proxy Squid jangan dipasang juga di mesin router NAT tersebut, sebab saat Squid mengakses halaman web ke internet; oleh PF dianggap bukan sebagai koneksi NAT, jadi tidak akan di-balance, dan akan stay mengambil interface utama dan default gateway pertama. Simpanlah mesin proxy/squid di belakang router NAT, agar koneksi proxy ke internet menjadi trafik NAT yang akan di-balance oleh script PF di atas.


Thanks to Starchie dan Hengky atas tutorial basic PF di OpenBSD

Untuk Lebih detail : Sumber http://yulian.firdaus.or.id/2007/09/07/load-balance-speedy/

Bisa juga bca disini : http://ferie-id.com/komputer/setting-loadbalancing-mikrotik

Iklan

BAGAIMANA MEMBAKAR AVI AND SUBTITLES KE DISC


BURNING TO CD

STEP 1: Open the folder containing the avi and/or the rar file containing

subtitles. Extract your subtitle language file if you choose to

include them on the CD-R.

STEP 2: Now you have 2 files; .avi, .srt

Rename you .srt file to the same as your .avi file.

Start any burning program that burns Data-CD’s.
Open a new project, and select Data-CD.

Add your file(s) to the project and burn away.

BURNING TO DVD

STEP 1: Open the folder containing the avi and/or the rar file containing

subtitles. Extract your subtitle language file if you choose to

include them on the DVD-R. In this case, rename you .srt file to the

same as your .avi file.

STEP 2: An effective program to use here is WinAVI.

Download this. Link in notes.

STEP 3: In WinAVI, convert your file(s) to DVD format.

This convertion program is very fast. Takes about 10min-1hour,

depending on you computer.

If you add the subtitle files to the convertion, it will promt an error.

Do not worry about this, it will work.

You will need DivX codec.

NOTES

To extract a .rar file you need a program like WinRAR.

You can download it here:

Windows:

http://www.rarlab.com/rar/wrar380.exe

Linux:

http://www.rarlab.com/rar/rarlinux-3.8.0.tar.gz

Mac:

http://www.rarlab.com/rar/rarosx-3.8.0.tar.gz

To convert your .avi file to DVD you need WinAVI.

You can download it here:

Windows: http://www3.winavi.com/download/WinAVI_Video_Converter.exe

http://www.torrentportal.com/download/1505590/WinAVI+Video+Converter+8.0+%2B+Keygen.rar.torrent

———————–

SELAmAT MenCOba