tinydns: fatal: unable to bind UDP socket: address not available

February 26, 2008 by gregorgede · 1 Comment
Filed under: djbdns 

if your tinydns service stop working and you find ” tinydns: fatal: unable to bind UDP socket: address not available” line in the log file, you will probably should do this :

1. $ /sbin/ifconfig or $ /sbin/ip addr
2. $ cat /service/tinydns/env/IP

make sure that result from number 2 is the same as the result from number 1.

phpmyadmin login screen for multiuser

February 25, 2008 by gregorgede · Leave a Comment
Filed under: PHP, phpmyadmin 

I got this somewhere from the internet but don’t remember the url. I translate it into indonesian, here it is :

untuk multiuser login screen, phpmyadmin mendukung 2 jenis otentikasi yaitu cookie dan http. untuk menggunakannya, pertama-tama harus membuat sebuah account/user dengan permission yang terbatas yang gunanya untuk melakukan pemeriksaan otentikasi oleh phpmyadmin.

1. Buat user dengan permission terbatas
anda dapat membuat user tersebut lewat phpmyadmin atau dari console mysql. pada contoh ini user dan password yang digunakan adalah SECURE.

mysql>GRANT USAGE ON mysql.* TO SECURE@localhost IDENTIFIED BY “SECURE”;
mysql>GRANT SELECT (

Host, User, Select_priv, Insert_priv, Update_priv, Delete_priv,

Create_priv, Drop_priv, Reload_priv, Shutdown_priv, Process_priv,

File_priv, Grant_priv, References_priv, Index_priv, Alter_priv,

Show_db_priv, Super_priv, Create_tmp_table_priv, Lock_tables_priv,

Execute_priv, Repl_slave_priv, Repl_client_priv

) ON mysql.user TO SECURE@localhost;

mysql>GRANT SELECT ON mysql.db TO SECURE@localhost;
mysql>GRANT SELECT ON mysql.host TO SECURE@localhost;
mysql>GRANT SELECT (Host, Db, User, Table_name, Table_priv, Column_priv) ON mysql.tables_priv TO SECURE@localhost;

2. Tentukan tipe otentikasi mana yang anda inginkan dan ikuti petunjuk yang sesuai berikut ini :

2a. OTENTIKASI DENGAN COOKIE
buka file config.inc.php dan cari variabel controluser dan controlpass dan sesuaikan seperti berikut ini :

$cfg['blowfish_secret'] = ‘FISHY’;

$cfg['Servers'][$i]['host'] = ‘localhost’; // MySQL hostname
$cfg['Servers'][$i]['port'] = ”; // MySQL port - leave blank for default port
$cfg['Servers'][$i]['socket'] = ”; // Path to the socket - leave blank for default socket
$cfg['Servers'][$i]['auth_type'] = ‘cookie’; // Authentication method
$cfg['Servers'][$i]['user'] = ”; // MySQL user
$cfg['Servers'][$i]['password'] = ”; // MySQL password
$cfg['Servers'][$i]['controluser'] = ‘SECURE’; // MySQL control user settings
$cfg['Servers'][$i]['controlpass'] = ‘SECURE’;// access to the grant tables

jangan lupa untuk mengosongkan user dan password seperti yang terlihat pada contoh diatas. variabel blowfish_secret dapat anda ganti sesuai keinginan.
bukalah phpmyadmin anda dari browser dan coba login dengan account yang biasanya anda pakai.

2b. OTENTIKASI HTTP
buka file config.inc.php dan cari variabel controluser dan controlpass dan sesuaikan seperti berikut ini :

$cfg['blowfish_secret'] = ‘FISHY’;

$cfg['Servers'][$i]['host'] = ‘localhost’; // MySQL hostname
$cfg['Servers'][$i]['port'] = ”; // MySQL port - leave blank for default port
$cfg['Servers'][$i]['socket'] = ”; // Path to the socket - leave blank for default socket
$cfg['Servers'][$i]['auth_type'] = ‘HTTP’; // Authentication method
$cfg['Servers'][$i]['user'] = ”; // MySQL user
$cfg['Servers'][$i]['password'] = ”; // MySQL password
$cfg['Servers'][$i]['controluser'] = ‘SECURE’; // MySQL control user settings
$cfg['Servers'][$i]['controlpass'] = ‘SECURE’;// access to the grant tables

jangan lupa untuk mengosongkan user dan password seperti yang terlihat pada contoh diatas. variabel blowfish_secret dapat anda ganti sesuai keinginan.
bukalah phpmyadmin anda dari browser dan coba login dengan account yang biasanya anda pakai.

quality of allied telesyn switch

February 2, 2008 by gregorgede · 2 Comments
Filed under: Uncategorized 

most of switches used in my organization are allied telesyn. recently i have a strange experience with our servers at dmz. upload files via ftp is very slow and never completed at all, but the download is fine and normal. i’ve tried sftp too but also had the same problem. slow upload but normal download.
i suspected the problem was on our mikrotik router which using HP desktop. i thought may be it was the LAN card. i even built a new mikrotik router using IBM thinkcenter to replace the HP. but did not have the chance to replace it because i had another thought that it could be the switch allied telesyn AT-FSW716 who caused the problem.
so i took a cross cable, plug it to connect the mikrotik and a server directly, then do ftp again from a computer on LAN zone. the result was very good, upload is very fast as it was the download. so my guess was right that it could be the switch who caused the problem.
so then i took a new switch from our supply, it’s AT-FS750/16 and installed it on the rackmount under the troubled AT-FSW716… move all cables to the new switch and rip off the troubled switch from the rack…. :)
test upload and download again, the result was very well… :) what’s the lesson in this? do not use AT-FSW716 ever again…….

Backtrack 2 kismet with usb DWL-G122 B1

February 2, 2008 by gregorgede · Leave a Comment
Filed under: backtrack, kismet 

This is about using kismet in backtrack 2 with dlink usb wireless, here’s what i did to make it work :
1. boot backtrack 2 live cd, login, do startx and open a terminal window.
2. $ vi /etc/kismet/kismet.conf and find the line source= and change it to this :
source=rt2500,rausb0,rausb0
save the file and then run
$ kismet
on kismet console press h button on your keyboard to get help

Now to connect to a wireless access point with wpa:

1. get out from kismet with shift+q
2. this is assuming the access point provides dhcp. do :
$ vi iwconfig
press i button on your keyboard and then write these lines :
#!/bin/bash
ifconfig rausb0 up
iwpriv rausb0 enc 3
iwpriv rausb0 auth 3
iwconfig rausb0 essid “The_AP_Essid”
sleep 1
iwpriv rausb0 wpapsk “The_Passphrase”
sleep 1
iwconfig rausb0 essid “The_AP_Essid”
iwconfig rausb0 mode managed
dhcpcd rausb0
ifconfig -a

press escape button and then save the file and get out by giving :wq command

3. $ chmod 755 iwconfig
4. $ ./iwconfig

it should work. i’ve also tried this on ubuntu feisty and it work, but sometimes the connection dies, so need to run the script again. btw, on ubuntu you need to add sudo in front of every lines in the script except #!/bin/bash