Berikut adalah konfigurasi sederhana pada Mikrotik ROS yang diminta oleh rekan saya, berfungsi untuk memisahkan layanan Client LAN meskipun menggunakan 1 upstream dengan layanan yang sama (SP**DY ADSL).
INTERNET --- ROUTER --- CLIENT ( IIX Only dan MIX )
Konfigurasi :
MODEM ADSL = 192.168.1.1/24
Router to ADSL modem : 192.168.1.2/24
Router to LAN : 192.168.0.1/24
***** Konfigurasi *****
/interface set ether1 name=uplink disabled=no
/interface set ether2 name=downlink disabled=no
/ip address add address=192.168.1.2/24 interface=uplink comment="UPLINK"
/ip address add address=192.168.0.1/24 interface=downlink comment="DOWNLINK"
/ip route add gateway=192.168.1.1 comment="TO-MODEM" disabled=no
/ip firewall address-list add address=32.0.0.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.168.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.170.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.171.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.172.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.173.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=32.234.175.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.0.0.0/8 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.240.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.241.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.242.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.244.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.245.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.246.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.65.247.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.168.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.169.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.170.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.171.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.172.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.173.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.174.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.145.175.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.188.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.0/29 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.24/29 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.32/29 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.44/30 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.48/29 list=iix-sp8 disabled=no
/ip firewall address-list add address=58.147.191.64/27 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.0.0.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.96.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.97.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.98.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.99.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.100.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.101.0/24 list=iix-sp8 disabled=no
/ip firewall address-list add address=60.253.102.0/24 list=iix-sp8 disabled=no
[ address list selengkapnya bisa di download di sini ]
/ip firewall address-list add address=192.168.0.10-192.168.0.20 list=svc-iix disabled=no
/ip firewall address-list add address=192.168.0.30-192.168.0.40 list=svc-intl disabled=no
/ip firewall address-list add address=192.168.1.1-192.168.1.2 list=MGMT disabled=no
/ip firewall address-list add address=192.168.0.1 list=MGMT disabled=no
/system note set note="\n\n\n********** config generated by spikecursed **********\n\n\n" show-at-login=yes
/ip firewall filter add chain=forward dst-address-list=MGMT protocol=tcp action=accept comment="ALLOW-TCP-ANY2MGMT"
/ip firewall filter add chain=forward dst-address-list=MGMT protocol=icmp action=accept comment="ALLOW-ICMP-ANY2MGMT"
/ip firewall filter add chain=forward src-address-list=svc-iix dst-address-list=iix-sp8 action=accept comment="ALLOW-IIX2IIX"
/ip firewall filter add chain=forward src-address-list=svc-intl dst-address-list=iix-sp8 action=accept comment="ALLOW-INTL2IIX"
/ip firewall filter add chain=forward src-address-list=svc-intl dst-address-list=!iix-sp8 action=accept comment="ALLOW-INTL2ANY"
/ip firewall filter add chain=forward src-address-list=svc-iix dst-address-list=!iix-sp8 action=drop comment="NO-IIX2ANY"
/ip firewall filter add chain=forward src-address-list=svc-iix dst-address-list=svc-intl action=drop comment="NO-SLICE"
/ip firewall nat add chain=srcnat action=masquerade out-interface=uplink
Set IP Address pada sisi client untuk menggunakan ip sesuai dengan layanan yang telah di deskripsikan pada address list untuk client (svc-iix atau svc-intl).
Semoga informasi sederhana ini dapat bermanfaat.
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network\Connections\StatMon]
“ShowLanErrors”=dword:00000001
*** KEBUTUHAN PAKET :
- OS Linux dengan paket library yang memadai.
- mysql-cluster-XXX-VERSION-OS.tar.gz
- PC Hardware : (1 pc) Management Server (2 pc) Node Server
- Login setara root pada masing masing system.
- Konektivitas jaringan (TCP/IP).
*** DESAIN SYSTEM :
- SYS-A ~ MANAGEMENT SERVER ~ 192.168.24.10
- SYS-B ~ DATABASE SERVER ~ 192.168.24.20
- SYS-C ~ DATABASE SERVER ~ 192.168.24.30
*** INSTALASI & KONFIGURASI :
A. Installasi MySQL ( 192.168.24.[10/20/30] ) ;
Copy paket mysql-cluster-XXX-VERSION-OS.tar.gz ke /home directory anda, kemudian lakukan 'sudo -i' atau login setara 'root', selanjutnya :
[root@localhost ~]# tar -xvzf mysql-cluster-XXX-VERSION-OS.tar.gz
[root@localhost ~]# mv mysql-cluster-XXX-VERSION-OS /usr/local
[root@localhost ~]# ln -s /usr/local/mysql-cluster-XXX-VERSION-OS /usr/local/mysql
[root@localhost ~]# groupadd mysql
[root@localhost ~]# useradd -g mysql mysql
[root@localhost ~]# cd /usr/local/mysql
[root@localhost ~]# chown -R mysql .
[root@localhost ~]# chgrp -R mysql .
[root@localhost ~]# scripts/mysql_install_db --user=mysql
[root@localhost ~]# chown -R root .
[root@localhost ~]# chown -R mysql data
[root@localhost ~]# cp /usr/local/mysql/support-files/my-large.cnf /etc/my.cnf
[root@localhost ~]# cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysqld
[root@localhost ~]# chmod 755 /etc/init.d/mysqld
[root@localhost ~]# bin/mysqld_safe --user=mysql &
Lakukan penggantian password dengan menjalankan perintah ;
[root@localhost ~]# bin/mysqladmin -u root password 'password-baru-anda'
Lakukan check terhadap proses installasi dan daemon mysql yang telah dijalankan ;
[root@localhost ~]# ps -ax | grep mysql
14815 pts/0 S+ 0:00 grep mysql
23508 ? S 0:00 /bin/sh ./bin/mysqld_safe --datadir=/usr/local/mysql/data --pid-file=/usr/local/mysql/data/localhost.pid
24632 ? Sl 0:12 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=mysql --log-error=/usr/local/mysql/data/localhost.err --pid-file=/usr/local/mysql/data/localhost.pid --socket=/var/lib/mysql/mysql.sock --port=3306
Lakukan proses installasi diatas pada masing masing system.
B. Konfigurasi MYSQL CLUSTER MANAGEMENT SERVER ( 192.168.24.10 ) ;
Pada MANAGEMENT SERVER sebenarnya tidaklah memerlukan installasi paket MySQL, dan hanya membutuhkan PC dengan hardware requirement yang relatif rendah dibanding dengan DATABASE SERVER, MANAGEMENT SERVER dapat di shutdown setelah DATABASE CLUSTER aktif / berjalan dengan baik, namun hal ini mengakibatkan fungsi redudancy database tidak berjalan secara realtime, dan hilangnya fungsi control pada DATABASE CLUSTER.
Konfigurasi ;
[root@localhost ~]# cd /usr/local/mysql
[root@localhost ~]# ln -s /usr/local/mysql/bin/ndb_mgm /sbin/ndb_mgm
[root@localhost ~]# ln -s /usr/local/mysql/bin/ndb_mgmd /sbin/ndb_mgmd
[root@localhost ~]# mkdir mysql-cluster
[root@localhost ~]# ln -s /usr/local/mysql/mysql-cluster /var/lib/mysql-cluster
Edit file konfigurasi MANAGEMENT SERVER ;
[root@localhost ~]# vi /usr/local/mysql/mysql-cluster/config.ini
Isi file config.ini ;
[NDBD DEFAULT]
NoOfReplicas=2
[MYSQLD DEFAULT]
[NDB_MGMD DEFAULT]
[TCP DEFAULT]
# MANAGEMENT SERVER
[NDB_MGMD]
HostName=192.168.24.10 # IP MANAGEMENT SERVER
# DATABASE SERVER
[NDBD]
HostName=192.168.24.20 # IP DATABASE SERVER 1
DataDir= /usr/local/mysql/mysql-cluster
[NDBD]
HostName=192.168.24.30 # IP DATABASE SERVER 2
DataDir=/usr/local/mysql/mysql-cluster
# 2 DATABASE SERVER
[MYSQLD]
[MYSQLD]
Jalankan MANAGEMENT SERVER ;
[root@localhost ~]# /sbin/ndb_mgmd -f /usr/local/mysql/mysql-cluster/config.ini
Proses eksekusi perintah diatas tidak memberikan feedback apapun pada console.
Check proses MANAGEMENT SERVER ;
[root@localhost ~]# ps -ax | grep mysql-cluster
23487 ? Ssl 2:42 ndb_mgmd -f /usr/local/mysql/mysql-cluster/config.ini
Check akses MANAGEMENT CONSOLE ;
[root@localhost ~]# /sbin/ndb_mgm
ndb_mgm> HELP
---------------------------------------------------------------------------
NDB Cluster -- Management Client -- Help
---------------------------------------------------------------------------
HELP Print help text
HELP COMMAND Print detailed help for COMMAND(e.g. SHOW)
SHOW Print information about cluster
CREATE NODEGROUP <id>,<id>... Add a Nodegroup containing nodes
DROP NODEGROUP <NG> Drop nodegroup with id NG
START BACKUP [NOWAIT | WAIT STARTED | WAIT COMPLETED]
START BACKUP [<backup id>] [NOWAIT | WAIT STARTED | WAIT COMPLETED]
START BACKUP [<backup id>] [SNAPSHOTSTART | SNAPSHOTEND] [NOWAIT | WAIT STARTED | WAIT COMPLETED]
Start backup (default WAIT COMPLETED,SNAPSHOTEND)
ABORT BACKUP <backup id> Abort backup
SHUTDOWN Shutdown all processes in cluster
CLUSTERLOG ON [<severity>] ... Enable Clus
<severity> = ALERT | CRITICAL | ERROR | WARNING | INFO | DEBUG
<category> = STARTUP | SHUTDOWN | STATISTICS | CHECKPOINT | NODERESTART | CONNECTION | INFO | ERROR | CONGESTION | DEBUG | BACKUP
<level> = 0 - 15
<id> = ALL | Any database node id
For detailed help on COMMAND, use HELP COMMAND.
ndb_mgm>
ndb_mgm> exit
[root@localhost ~]#
C. Konfigurasi MYSQL CLUSTER DATABASE SERVER ( 192.168.24.[20/30] ) ;
CLUSTER berfungsi sebagai media penyimpanan database dimana fungsi cluster dijalankan, jalankan konfigurasi berikut ini pada kedua DATABASE SERVER.
Edit file konfigurasi CLUSTER DATABASE SERVER ;
[root@localhost ~]# vi /etc/my.cnf
Isi file my.cnf ;
[mysqld]
ndbcluster
ndb-connectstring=192.168.24.10 # IP MANAGEMENT SERVER
[mysql_cluster]
ndb-connectstring=192.168.24.10 # IP MANAGEMENT SERVER
Membuat directory data ;
[root@localhost ~]# cd /usr/local/mysql
[root@localhost ~]# mkdir mysql-cluster
[root@localhost ~]# ln -s /usr/local/mysql/mysql-cluster /var/lib/mysql-cluster
Hentikan proses MySQL yang dalam kondisi aktif ;
[root@localhost ~]# /etc/init.d/mysqld stop
Jalankan CLUSTER DATABASE SERVER dan MySQL;
[root@localhost ~]# cd /usr/local/mysql/mysql-cluster
[root@localhost ~]# ln -s /usr/local/mysql/bin/ndbd /sbin/ndbd
[root@localhost ~]# /sbin/ndbd --initial
[root@localhost ~]# /etc/init.d/mysqld start
Untuk eksekusi perintah "/sbin/ndbd --initial" hanya dilakukan pada proses awal inisialisasi saja, selanjutnya cukup menggunakan perintah "/sbin/ndbd".
*** CHECK KINERJA :
Untuk melakukan pemeriksaan pada kinerja MYSQL-CLUSTER, dimulai dari MANAGEMENT SERVER sebagai berikut ;
Check melalui MANAGEMENT CONSOLE ( 192.168.24.10 ) ;
[root@localhost ~]# /sbin/ndb_mgm
-- NDB Cluster -- Management Client --
ndb_mgm> show
Connected to Management Server at: localhost:1186
Cluster Configuration
---------------------
[ndbd(NDB)] 2 node(s)
id=2 @192.168.24.20 (mysql-5.1.34 ndb-7.0.6, Nodegroup: 0, Master)
id=3 @192.168.24.30 (mysql-5.1.34 ndb-7.0.6, Nodegroup: 0)
[ndb_mgmd(MGM)] 1 node(s)
id=1 @192.168.24.10 (mysql-5.1.34 ndb-7.0.6)
[mysqld(API)] 2 node(s)
id=4 @192.168.24.30 (mysql-5.1.34 ndb-7.0.6)
id=5 @192.168.24.20 (mysql-5.1.34 ndb-7.0.6)
ndb_mgm>exit
[root@localhost ~]#
Fungsi CLUSTER berjalan dengan baik apabila indikator diatas terpenuhi, dimana seluruh node database (NDB) telah dikenali dan tersambung pada MANAGEMENT SERVER, bila anda menemukan informasi berikut ;
not connected, accepting connect from 192.168.24.20 atau,
not connected, accepting connect from 192.168.24.30
pada 2 baris awal (NDB) atau 2 baris akhir (API) menandakan adanya kendala pada proses CLUSTER, lakukan check pada konektivitas jaringan dan konfigurasi pada system tersebut.
Check melalui DATABASE SERVER ( 192.168.24.[20/30] ) ;
Akses pada MySQL Console SYS-B dan SYS-C dan lakukan test insert dan query pada database.
SYS-B ( 192.168.24.20 ) ;
[root@localhost ~]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.1.34-ndb-7.0.6-cluster-gpl-log MySQL Cluster Server (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>use test;
mysql> CREATE TABLE rtest (author CHAR(50)) ENGINE=NDBCLUSTER;
Query OK, 0 rows affected (1.11 sec)
mysql> INSERT INTO rtest () VALUES ('rizky.md@gmail.com');
Query OK, 1 row affected (0.03 sec)
mysql> select * from rtest;
+--------------------+
| author |
+--------------------+
| rizky.md@gmail.com |
+--------------------+
1 row in set (0.00 sec)
mysql>
SYS-C ( 192.168.24.30 ) ;
mysql> use test;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> select * from rtest ;
+--------------------+
| author |
+--------------------+
| rizky.md@gmail.com |
+--------------------+
1 row in set (0.00 sec)
mysql>
Bila database pada SYS-C terupdate sesuai dengan database pada SYS-B secara realtime (vice versa), maka fungsi cluster telah berjalan dengan baik, lakukan hal yang sama pada SYS-C untuk melakukan pemeriksaan terhadap fungsi CLUSTER. Anda dapat juga melakukan test redundancy dengan memutuskan koneksi jaringan pada salah satu DATABASE SERVER.
*** MENGGUNAKAN ENGINE CLUSTER :
Untuk membuat table baru dengan Engine NDBCLUSTER, perintah yang digunakan ;
CREATE TABLE 'NAMA-TABLE' 'PARAMETER' ENGINE=NDBCLUSTER;
Contoh :
[root@localhost ~]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.1.34-ndb-7.0.6-cluster-gpl-log MySQL Cluster Server (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> CREATE DATABASE rmdtest ;
mysql> use rmdtest ;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> CREATE TABLE VPNUSER (nama CHAR(50), password CHAR(50)) ENGINE=NDBCLUSTER;
Query OK, 0 rows affected (1.26 sec)
mysql> INSERT INTO VPNUSER () VALUES ('admin' ,'r1zky');
Query OK, 1 row affected (0.03 sec)
mysql> select * from VPNUSER;
+-------+----------+
| nama | password |
+-------+----------+
| admin | r1zky |
+-------+----------+
1 row in set (0.00 sec)
mysql>
Untuk menggunakan fungsi cluster pada table yang sudah ada diperlukan konversi dari Engine MyISAM ke Engine NDBCLUSTER, perintah yang digunakan ;
ALTER TABLE 'NAMA-TABLE' ENGINE=NDBCLUSTER;
Contoh :
[root@localhost ~]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.1.34-ndb-7.0.6-cluster-gpl-log MySQL Cluster Server (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> use rmdtest ;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> show tables;
+-------------------+
| Tables_in_rmdtest |
+-------------------+
| VPNUSER |
+-------------------+
1 row in set (0.06 sec)
mysql> ALTER TABLE VPNUSER ENGINE=NDBCLUSTER;
Query OK, 1 row affected (2.85 sec)
Records: 1 Duplicates: 0 Warnings: 0
mysql> select * from VPNUSER;
+-------+----------+
| nama | password |
+-------+----------+
| admin | r1zky |
+-------+----------+
1 row in set (0.07 sec)
mysql>
*** INFORMASI TAMBAHAN :
Untuk menambahkan DATABASE SERVER (NDB) edit config.ini pada MANAGEMENT SERVER, sebagai contoh menambahkan 2 node NDB sehingga menjadi 4 DATABASE SERVER ;
[NDBD DEFAULT]
NoOfReplicas=4
[MYSQLD DEFAULT]
[NDB_MGMD DEFAULT]
[TCP DEFAULT]
# MANAGEMENT SERVER
[NDB_MGMD]
HostName=192.168.24.10 # IP MANAGEMENT SERVER
# DATABASE SERVER
[NDBD]
HostName=192.168.24.20 # IP DATABASE SERVER 1
DataDir= /usr/local/mysql/mysql-cluster
[NDBD]
HostName=192.168.24.30 # IP DATABASE SERVER 2
DataDir=/usr/local/mysql/mysql-cluster
[NDBD]
HostName=192.168.24.40 # IP DATABASE SERVER 3
DataDir=/usr/local/mysql/mysql-cluster
[NDBD]
HostName=192.168.24.50 # IP DATABASE SERVER 4
DataDir=/usr/local/mysql/mysql-cluster
# 2 DATABASE SERVER
[MYSQLD]
[MYSQLD]
[MYSQLD]
[MYSQLD]
Kemudian lakukan 'RELOAD' proses MANAGEMENT SERVER ( 192.168.24.10 ) ;
[root@localhost ~]# killall ndb_mgmd
[root@localhost ~]# /sbin/ndb_mgmd -f /usr/local/mysql/mysql-cluster/config.ini
Shutdown proses CLUSTER melalui MANAGEMENT SERVER CONSOLE ( 192.168.24.10 ) ;
[root@localhost ~]# /sbin/ndb_mgm
-- NDB Cluster -- Management Client --
ndb_mgm> SHUTDOWN
ndb_mgm> EXIT
Kemudian lakukan 'RELOAD' pada tiap DATABASE SERVER ( 192.168.24.[20/30/40/50] ) ;
[root@localhost ~]# /etc/init.d/mysqld stop
[root@localhost ~]# killall ndbd
[root@localhost ~]# /sbin/ndbd
[root@localhost ~]# /etc/init.d/mysqld start
Lakukan 'RELOAD' setiap kali terjadi perubahan pada 'config.ini' MANAGEMENT SERVER.
Implementasikan MYSQL CLUSTER pada kondisi Network yang aman dan tertutup, semisal melalui link VPN atau Internal network yang terlindungi firewall dan fungsi keamanan yang memadai.
Penulis : rizky.md@gmail.com
Referensi :
- http://spikecursed.blogsome.com/2009/01/29/mysql-cluster-database-redundancy/

another take down ... i still can do it.
Banyak rekan rekan yang menanyakan cara untuk registrasi domain .co.cc, berikut ini cara registrasinya :
1. Kunjungi site www.co.cc
untuk melakukan registrasi.
2. Anda akan diminta melakukan pemilihan nama domain, setelah itu server akan melakukan verifikasi ketersediaan nama domain yang anda pilih, lakukan pengisian pada field isian antara "www." dan ".co.cc", kemudian pilih "Check Availability".
3. Bila selanjutnya proses verifikasi menghasilkan "www.nama-domain-anda.co.cc is available" ,berarti nama domain tersedia dan dapat dipergunakan, lanjutkan dengan memilih "Continue to registration".
4. Pada halaman proses registrasi, Pilih "Create an account now".
5. Isi form registrasi, dan beri tanda check pada "I accept the Terms of Service".
6. Pilih "Create an account now", hingga proses registrasi selesai secara keseluruhan.
7. Selanjutnya melakukan pengaturan pada domain "Manage Domain", kemudian pilih fungsi "URL Forwarding", pada "Redirect To" isi dengan URL yang ingin anda gunakan pada nama domain anda, "Page Title" diisi dengan informasi judul page, kemudian pilih "Set up" hingga ditampilkan pesan "Your change has been submitted." pilih "OK".
8. Selanjutnya buka browser dan lakukan akses ke site www.domain-anda.co.cc.
Sekian semoga bermanfaat
.


Jakarta Time


































