Jumat, 27 Juni 2008

Install XMMS on Ubuntu ( 8.04 ) Hardy Heron

digg_url="http://blog.sartek.net/2008/04/install-xmms-on-ubuntu-804-hardy-heron.html";
First: I'm not an Ubuntu user, but I would like to help newbies to get XMMS working on Ubuntu Hardy Heron.Why:

a) A guy entered #xmms on Freenode and wanted to install XMMS on him Ubuntu, so I tried to help him.
b) XMMS is still a good player, and if somebody wants to use it, why not help him?We will install XMMS from source, but there are alternatives though like:

1) change your distro
2) try gutsy packages

OK, let's start

First Step:

We need to download the required packages to compile XMMS

# sudo apt-get install autotools-dev automake1.9 libtool gettext libasound2-dev libaudiofile-dev \libgl1-mesa-dev libglib1.2-dev libgtk1.2-dev libesd0-dev libice-dev libmikmod2-dev libogg-dev \libsm-dev libvorbis-dev libxxf86vm-dev libxml-dev libssl-dev build-essential makeDepending on your internet connection and your machine this may take some minutes.

Second Step:

Prepare the XMMS for compilingCreate a directory in your HOME directory:

# mkdir ~/build
Change the working directory to it:
# cd ~/build
Download XMMS sources:
# wget http://xmms.org/files/1.2.x/xmms-1.2.11.tar.gz
Unpack it:
# tar xvf xmms-1.2.11.tar.gz

Change the working directory to the source directory:

# cd xmms-1.2.11/Third Step:Compiling it:This generates the necessary files, and checks your system:
# ./configure --prefix=/usr

The actually compiling

# make

Fourth Step:
Install it:
# sudo make install

After install we no longer need the source directory:

# cd# rm -rf ~/build

That's it, now we can run XMMS: press ALT+F2 write xmms there and hit enter and enjoy your music.
NOTE: many people say that XMMS is old, buggy,no UTF-8 support, etc. Yes maybe all is true, but it's an audio player not a media library organizer, so it plays music and you listen, that's all and it does that job.

UPDATE:
Flac Plugin
We need to get the build dependencies

# sudo apt-get build-dep flac

You already know what's this ;)

# mkdir ~/build
# cd ~/build

Get flac's sources

# apt-get source flacAnother well known step:)
# cd flac-1.2.1
# ./configure
# make

It's enough to copy the plugin, not to install the whole flac stuff, this is good if will be flac update, note, an update wont break the plugin.

# cp src/plugin_xmms/.libs/libxmms-flac.so ~/.xmms/Plugins
# cd
# rm -rf ~/build

Kamis, 26 Juni 2008

Ubuntu 8.04 (Hardy Heron) LAMP Server Setup






















In around 15 minutes, the time it takes to install Ubuntu Server Edition, you can have a LAMP (Linux, Apache, MySQL and PHP) server up and ready to go. This feature, exclusive to Ubuntu Server Edition, is available at the time of installation.
The LAMP option means you don’t have to install and integrate each of the four separate LAMP components, a process which can take hours and requires someone who is skilled in the installation and configuration of the individual applications. Instead, you get increased security, reduced time-to-install, and reduced risk of misconfiguration, all of which results in a lower cost of ownership.New pre-configured installation options have been added to the Ubuntu Server. Mail Server, File Server, Print Server, and Database Server options join existing LAMP and DNS options for pre-configured installations, easing the deployment of common server configurations.
Ubuntu LAMP server Install the following Versions
Ubuntu Hardy Heron 8.04
Apache 2.2.8
Mysql 5.0.51a
PHP 5.2.4


First you need to download server version of Ubuntu version from here after that you create a CD and start booting with the CD Once it starts booting you should see the following screen in this you need to select your language and press enter

Now you need to select “Install Ubuntu Server” and press enter

Now you need to select “Install Ubuntu Server” and press enter
Ubuntu Server CD is loading in Progress
Choose you language and press enter you can see we have selected english in the follwoing screen
Choose your location and press enter you can see we have have selected United Kingdom in the follwoing screen
If you want to try to have your keyboard layout detected by pressing a series of keys you need to select yes option and if you don’t want that and you want to choose from a list click no in this example we have selected no and press enter
Select Origin of keyboard and press enter
Select keyboard layout and press enter
Detecting hardware to find CD-ROM Drivers in progress
Scanning CD-ROM in Progress
Loading additional components progress bar
Detecting Network hardware is in progress
Configures the network with DHCP if there is a DHCP server in the network
Enter the Hostname of the system so in this example i enter here as ubuntulamp
Startingup the partitioner in progress
you have to partition your hard disk in this example i have selected use entire disk option if you want to edit manually you can choose manual and press enter
Warning message about data lost on your hard disk
Creating partitions in your hard disk is in progress
Write the changes to disk option here you need to select yes and press enter
Creating ext3 filesystem in progress
Installing base system is in progress
You need enter the Full name of the user you want to create for your server in this example i have created administrator user select continue and press enter
username for your account in this i have entered test select continue and press enter
Entered the password for test user select continue and press enter
Confirm the password for test user select continue and press enter
Configuring the package manager select continue and press enter
Configuring package mirror this will be related to your country option
Now it will start Installing software and here you need to select the server options here i have selected as LAMP and OpenSSH server for our LAMP server installation
At the time of software installation it will prompt for mysql server root password enter root password of your choice and select continue
Confirm mysql server root password and select continue
Software installation is in progress
Installing GRUB Boot loader in progress
Finishing installation in Progress
Installation complete message here you need to remove your CD select continue and press enter it will reboot your server
After rebooting you can see the following screen prompt for username
This will complete the Ubuntu LAMP Server Installation and your server is ready for installing applications which supports apache,mysql and php.
Configuring Static ip address in Ubuntu server
Ubuntu installer has configured our system to get its network settings via DHCP, Now we will change that to a static IP address for this you need to edit Edit /etc/network/interfaces and enter your ip address details (in this example setup I will use the IP address 172.19.0.10):
sudo vi /etc/network/interfaces
and enter the following save the file and exit
# The primary network interface
auto eth0iface eth0 inet staticaddress 172.19.0.10netmask 255.255.255.0network 172.19.0.0broadcast 172.19.0.255gateway 172.19.0.1
Now you need to restart your network services using the following command
sudo /etc/init.d/networking restart
You need to setup manually DNS servers in resolv.conf file when you are not using DHCP.
sudo vi /etc/resolv.conf
You need to add look something like this
search domain.com
nameserver xxx.xxx.xxx.xxx
GUI Installation for Ubuntu LAMP Server
Option1
If you are a new user and not familiar with command prompt you can install GUI for your ubuntu LAMP server for this you need to make sure you have enabled Universe and multiverse repositories in /etc/apt/sources.list file once you have enable you need to use the following command to install GUI
sudo apt-get update
sudo apt-get install ubuntu-desktop
The above command will install GNOME desktop if you want to install KDE desktop use the following command
sudo apt-get install kubuntu-desktop
Option2
Installing Webmin in Ubuntu Gutsy Gibbon
Webmin is a web-based interface for system administration for Unix. Using any modern web browser, you can setup user accounts, Apache, DNS, file sharing and much more. Webmin removes the need to manually edit Unix configuration files like /etc/passwd, and lets you manage a system from the console or remotely.
You can install webmin for your server web interface to configure apache,mysql servers.Now we will see how to install webmin in Ubuntu 8.04

Preparing your system
First you need to install the following packages

sudo apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl

Now download the latest webmin using the following command

Now we have webmin_1.420_all.deb package install this package using the following command

sudo dpkg -i webmin_1.420_all.deb

This will complete the installation.
Ubuntu in particular don’t allow logins by the root user by default. However, the user created at system installation time can use sudo to switch to root. Webmin will allow any user who has this sudo capability to login with full root privileges.
Now you need to open your web browser and enter the following
https://your-server-ip:10000/
Now you should see similar to the following Screen
After login if you want to configure Apache,Mysql server you need to click on Servers on your lefthand side you should many servers are ready to configure
This is very Easy to configure most of the servers and Enjoy your new Ubuntu Hardy Heron LAMP Server.

Ubuntu Server CD is loading in Progress

Choose you language and press enter you can see we have selected english in the follwoing screen


Choose your location and press enter you can see we have have selected United Kingdom in the follwoing screen


If you want to try to have your keyboard layout detected by pressing a series of keys you need to select yes option and if you don’t want that and you want to choose from a list click no in this example we have selected no and press enter

Select Origin of keyboard and press enter

Select keyboard layout and press enter


Detecting hardware to find CD-ROM Drivers in progress


Scanning CD-ROM in Progress


Loading additional components progress bar

Detecting Network hardware is in progress

Configures the network with DHCP if there is a DHCP server in the network
Enter the Hostname of the system so in this example i enter here as ubuntulamp


Startingup the partitioner in progress

you have to partition your hard disk in this example i have selected use entire disk option if you want to edit manually you can choose manual and press enter

Warning message about data lost on your hard disk


Creating partitions in your hard disk is in progress
Write the changes to disk option here you need to select yes and press enter


Creating ext3 filesystem in progress

Installing base system is in progress http://biangklik.co.cc/


You need enter the Full name of the user you want to create for your server in this example i have created administrator user select continue and press enter

username for your account in this i have entered test select continue and press enter
Entered the password for test user select continue and press enter


Confirm the password for test user select continue and press enter
Configuring the package manager select continue and press enter

Configuring package mirror this will be related to your country option

Now it will start Installing software and here you need to select the server options here i have selected as LAMP and OpenSSH server for our LAMP server installation

At the time of software installation it will prompt for mysql server root password enter root password of your choice and select continue
Confirm mysql server root password and select continue
Software installation is in progress
Installing GRUB Boot loader in progress
Finishing installation in Progress

Installation complete message here you need to remove your CD select continue and press enter it will reboot your server


After rebooting you can see the following screen prompt for username







This will complete the Ubuntu LAMP Server Installation and your server is ready for installing applications which supports apache,mysql and php.

Configuring Static ip address in Ubuntu
Ubuntu installer has configured our system to get its network settings via DHCP, Now we will change that to a static IP address for this you need to edit Edit /etc/network/interfaces and enter your ip address details (in this example setup I will use the IP address 172.19.0.10):


sudo vi /etc/network/interfaces

and enter the following save the file and exit

# The primary network interface
auto eth0
iface eth0 inet static
address 172.19.0.10
netmask 255.255.255.0
network 172.19.0.0
broadcast 172.19.0.255
gateway 172.19.0.1
Now you need to restart your network services using the following command
sudo /etc/init.d/networking restart

You need to setup manually DNS servers in resolv.conf file when you are not using DHCP.

sudo vi /etc/resolv.conf

You need to add look something like this
search domain.com
nameserver xxx.xxx.xxx.xxx
GUI Installation for Ubuntu LAMP Server
Option1

If you are a new user and not familiar with command prompt you can install GUI for your ubuntu LAMP server for this you need to make sure you have enabled Universe and multiverse repositories in /etc/apt/sources.list file once you have enable you need to use the following
command to install GUI
sudo apt-get update
sudo apt-get install ubuntu-desktop

The above command will install GNOME desktop if you want to install KDE desktop use the
following command
sudo apt-get install kubuntu-desktop

Option2

Installing Webmin in Ubuntu Gutsy Gibbon

Webmin is a web-based interface for system administration for Unix. Using any modern web browser, you can setup user accounts, Apache, DNS, file sharing and much more. Webmin removes the need to manually edit Unix configuration files like /etc/passwd, and lets you manage a system from the console or remotely.


You can install webmin for your server web interface to configure apache,mysql servers.Now we will see how to install webmin in Ubuntu 8.04
Preparing your system

First you need to install the following packages
sudo apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl

Now download the latest webmin using the following command

Now we have webmin_1.420_all.deb package install this package using the following command
sudo dpkg -i webmin_1.420_all.deb


This will complete the installation.
Ubuntu in particular don’t allow logins by the root user by default. However, the user created at system installation time can use sudo to switch to root. Webmin will allow any user who has this sudo capability to login with full root privileges.

Now you need to open your web browser and enter the following


Now you should see similar to the following Screen

After login if you want to configure Apache,Mysql server you need to click on Servers on your lefthand side you should many servers are ready to configure

This is very Easy to configure most of the servers and Enjoy your new Ubuntu Hardy Heron LAMP Server.

Senin, 26 Mei 2008

Linux sebagai Gateway Internet


Di tutorial jaringan komputer kali ini saya
akan menjelaskan proses installasi linux yang nantinya akan dijadikan sebagai
gateway internet.



Btw, gateway itu
sendiri memiliki definisi
sebuah komputer yang melayani konversi
protokol antara beberapa tipe yang berbeda dari suatu network atau program
aplikasi. Sebagai contoh, sebuah gateway dapat meng-convert sebuah paket TCP/IP
menjadi paket NetWare IPX atau dari Apple Talk menjadi DECnet, dan lain-lain. (
Andino-Kamus TI – Ilmukomputer.com )



Gateway inilah
yang nantinya akan menghubungkan jaringan local dalam hal ini LAN dengan
jaringan public yaitu internet.



Sebagai catatan
dalam percobaan ini penulis menggunakan Redhat Linux 9, dan Fedora Core 4. Menggunakan
koneksi ADSL speedy dengan IP Static ( penulis pun bingung, karena baru pertama
kali ini penulis diberikan koneksi ADSL speedy dengan IP Static. :D . Ini
nyata.)





Sebelumnya paket yang
kita butuhkan adalah :



rp-pppoe-3.5-27.i386.rpm





Tapi setahu
penulis paket tersebut sudah terinstall dalam distro tersebut, untuk mengetahui
apakah pake tersebut sudah terinstall didalamnya login sebagai root :



root@alk.root#rpm -qa | grep pppoe



rp-pppoe-3.5-27





Perlu diketahui komputer yang akan dijadikan sebagai gateway nanti
membutuhkan 2 ethernet card nantinya.





Yupz, langsung
aja kita menuju pokok pembahasannya.



Langkah awal yang
harus dilakukan adalah memeriksa apakah kedua ethernet card tersebut sudah
terdetek dengan baik:



root@alk.root#ifconfig



eth0 Link encap:Ethernet HWaddr 00:0C:29:EE:71:11



inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0



inet6 addr:
fe80::20c:29ff:feee:7111/64 Scope:Link



UP BROADCAST RUNNING MULTICAST MTU:1500
Metric:1



RX packets:61 errors:0 dropped:0
overruns:0 frame:0



TX packets:85 errors:0 dropped:0
overruns:0 carrier:0



collisions:0 txqueuelen:1000



RX bytes:6938 (6.7 KiB) TX bytes:10092 (9.8 KiB)



Interrupt:10 Base address:0x1080





eth1 Link encap:Ethernet HWaddr 00:0C:29:EE:71:1B



inet addr:192.168.100.1 Bcast:192.168.100.255 Mask:255.255.255.0



inet6 addr:
fe80::20c:29ff:feee:711b/64 Scope:Link



UP BROADCAST RUNNING MULTICAST MTU:1500
Metric:1



RX packets:0 errors:0 dropped:0
overruns:0 frame:0



TX packets:21 errors:0 dropped:0
overruns:0 carrier:0



collisions:0 txqueuelen:1000



RX bytes:0 (0.0 b) TX bytes:1796 (1.7 KiB)



Interrupt:9 Base address:0x1400





lo Link encap:Local Loopback



inet addr:127.0.0.1 Mask:255.0.0.0



inet6 addr: ::1/128 Scope:Host



UP LOOPBACK RUNNING MTU:16436
Metric:1



RX packets:35 errors:0 dropped:0
overruns:0 frame:0



TX packets:35 errors:0 dropped:0
overruns:0 carrier:0



collisions:0 txqueuelen:0



RX bytes:2190 (2.1 KiB) TX bytes:2190 (2.1 KiB)





Yup, jika anda
mendapatkan komentar seperti itu silahkan menuju ke tahap selanjutnya. Jika
tidak ? Silahkan googling :D~~~.





Langkah
berikutnya adalah mengkonfigurasi ethernet card tersebut. Agar nantinya
konfigurasi tersebut dapat dijalankan secara otomatis ketika boot. File
konfigurasi ethernet dalam linux memiliki penamaan ethx, x ini menandakan
pengurutan, jika terdapat 2 ethernet card dalam komputer anda maka, file
konfigurasinya adalah eth0 dan eth1. Letak file konfigurasi secara default
terdapat dalam :

/etc/sysconfig/network-scripts/ifcfg-ethx





Karena nantinya
kita akan menggunakan 2 lancard tersebut, maka file yang akan kita konfigurasi
adalah :



/etc/sysconfig/network-scripts/ifcfg-eth0 dan /etc/sysconfig/network-scripts/ifcfg-eth1





Sebagai contoh,
konfigurasi eth0 yang penulis gunakan adalah sebagai berikut :



DEVICE=eth0



BOOTPROTO=static



BROADCAST=192.168.1.255



HWADDR=00:0C:29:EE:71:11



IPADDR=192.168.1.1



NETMASK=255.255.255.0



NETWORK=192.168.1.0



ONBOOT=yes



TYPE=Ethernet





DEVICE : merupakan
ethernet apa yang akan dikonfigurasi.



BOOTPROTO :
status dari penggunaan ip address, apakah bersifat dynamic ( DHCP ) atau
static.



BROADCAST :
alamat broadcast jaringan yang digunakan.



HWADDR : alamat
fisik dari ethernet card tersebut, biasa disebut Mac Address.



IPADDR : alamat
ip yang nanti akan digunakan oleh gateway linux. Alamat ini yang nantinya akan
berhubungan langsung dengan protol tcp/ip.



NETMASK : subnet
mask yang digunakan oleh device eth0. subnet mask ini digunakan untuk membagi
jaringan menjadi lebih kecil.



ONBOOT : apakah
nanti akan diproses ketika BOOT ??





Dan konfigurasi
eth1 yang digunakan oleh penulis :



DEVICE=eth1



BOOTPROTO=static



BROADCAST=192.168.100.255



HWADDR=00:0C:29:EE:71:1B



IPADDR=192.168.100.1



NETMASK=255.255.255.0



NETWORK=192.168.100.0



ONBOOT=yes



TYPE=Ethernet





Kemudian restart
service network.



root@alk.root#/etc/init.d/network restart







Sebelum ke
langkah selanjutnya, perlu diketahui bahwa, anda diharuskan untuk mengaktifkan
mode bridge pada modem adsl.

Langkah
selanjutnya adalah konfigurasi ADSL-nya :



root@alk.root#adsl-setup



# pertama kali
akan ditanyakan username yang telah diberikan oleh pihak ISP anda











LOGIN NAME
Enter your Login
Name:
121303xxxxxx@telkom.net
#device yang berhubungan langsung
dengan modem adsl anda, dalam hal ini eth1







INTERFACE
Enter the Ethernet interface connected to the ADSL modem



For Solaris, this is likely to be something like /dev/hme0.



For Linux, it will be ethX, where 'X' is a number.







(default eth0):eth1

# kalo yang ini pilih no aja,
karena ketika demand diaktifkan maka anda tidak bisa



# menggunakan IP yang dynamic













Enter the demand value (default no): no
# DNS yang digunakan, bagian ini bisa diisi nanti. Lewat saja.
# password yang diberikan oleh ISP anda, berbarengan dengan diberikannya
username tadi







PASSWORD
Please enter your Password:xxxxxxxx







# pemberian akses kepada user
untuk menjalankan/mematikan adsl







USERCTRL
Please enter 'yes' (three letters, lower-case.) if you want to allow
normal user to start or stop DSL connection (default yes):
yes



















# langkah berikutnya adalah berkenaan dengan firewall disini penulis
memilih no 2
The firewall choices are:
0 - NONE: This script will not set any firewall rules. You are responsible
for ensuring the security of your
machine. You are STRONGLY
recommended to use some kind
of firewall rules.
1 - STANDALONE: Appropriate for a basic stand-alone web-surfing
workstation
2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway



for a LAN



Choose a type of firewall (0-2):2





# apakah
akan dijalankan secara otomatis ketika boot ?





Start this connection at boot time



Do you want to start this connection at boot time?





Please enter no or yes (default no):yes



Dan selanjutnya ketik y saja untuk mensave konfigurasi diatas.





Ada beberapa konfigurasi yang
perlu dilakukan. Penulis memberikan sedikit konfigurasi tambahan yang
diletakkan pada file /etc/rc.local





echo 1 > /proc/sys/net/ipv4/ip_forward



iptables -A POSTROUTING -j MASQUERADE -t nat -s
192.168.1.0/24 -o ppp0





konfigurasi tersebut digunakan
untuk meneruskan paket ip dan melakukan masquerade. Masquerade sendiri
merupakan proses membagi bandwith, karena pada dasarnya isp hanya memberikan
satu koneksi dengan satu ip, maka agar dapat digunakan secara beramai-ramai
maka perlu dilakukan masquerade.





Selanjutnya anda tinggal menambahkan
dns server yang diberikan oleh telkom pada file konfigurasi
/etc/resolv.conf, yang penulis gunakan adalah 202.134.0.155.



root@alk.root#echo nameserver 202.134.0.155 >
/etc/resolv.conf



root@alk.root#cat /etc/resolv.conf



nameserver
202.134.0.155





Selanjutnya anda tinggal
menjalankan adsl-start.



Selamat bersurfing ria. :D~

by : Al-k
alkemail@gmail.com
http://www.ilmuwebsite.com

Tutorial Jaringan Komputer
Sumber dari situs Ilmu Website dalam kategori jaringan dengan judul Konfigurasi Linux sebagai Gateway Internet

Rabu, 07 Mei 2008

KONFIGURASI SAMBA SERVER

SAMBA digunkan untuk proses sharing file antara linux dan windows, sebenarnya jika ingin belajar bagaimana agar mesin Windows dan Linux dapat berbagi resource (sharing), berarti tutorial ini cukup dibaca sampai disini saja karena ambisi saya menulis tutorial ini agar mereka yang mau membangun server menjadi tahu konfigurasi dasar yang dibutuhkan sebuah server.
beberapa pertanyaan yang mencakup settingan Samba dan keperluan penggunaan Samba:
1. Apa itu PDC? Mengapa perlu menggunakan PDC?
2. Apa keuntungan menggunakan server Samba?
3. Komputer client menggunakan PC dengan OS apa?
Nah, pertanyaan diatas sangat penting untuk diketahui, karena akan dibutuhkan untuk implementasi ke depan.
Q: Apa itu PDC ? Mengapa perlu menggunakan PDC?
A: PDC itu Primary Domain Controller, jelas dari kata-katanya yang berarti sesuatu yang mengatur domain dan menjadi pengatur domain utama karena itulah sangat dibutuhkan sesuatu yang mengatur beberapa jaringan dengan banyak domain, jadi demi keamanan jugalah PDC sangat diperlukan agar anggota-anggota / client-client dari domain lain ga bisa saling akses, gawat khan kalo domain web.daunpintu.net bisa mengakses secara penuh domain keuangan.daunpintu.net???
Q: Apa keuntungan menggunakan server Samba?
A: Jelas sangat menguntungkan, kenapa ?! Karena selain gratis (berlisensi Gnu Public License), riset membuktikan bahwa kecepatan server Samba ternyata lebih cepat 2 kali lipat dari Windows Server 2003. Pasti Anda tidak percaya, bukan?! Tenang, saya sudah siapkan buktinya, silakan lihat http://www.vnunet.com/news/1144289
Q: Komputer client menggunakan PC dengan OS apa?
A: Pertanyaan ini juga penting, karena ada perbedaan konfigurasi antara Windows 9x dan Windows NT/200x/XP, maka dari itu, pastikan dulu client Anda akan menggunakan OS Windows apa, nanti akan kita lalui bersama penderitaan berikutnya dalam men-setting Samba sebagai PDC.Baiklah, kita mulai saja penderitaan berikutnya, dari tadi soalnya basa-basi melulu
☺Konfigurasi file SAMBA terletak di /etc/samba/smb.confFile SMB.CONFFile ini berisi konfigurasi utama dari server samba,karena terlalu lama kalo gw tampilkan isi default dari smb.conf ini, ada baiknya kita backup dulu file smb.conf yang asli menjadi smb.conf.bak, agar jika suatu saat ada kesalahan atau Samba tidak berjalan semestinya, maka dapat langsung di recover
☺[root@server home]# cd /etc/samba/
[root@server samba]# cp smb.conf smb.conf.bak
[root@server samba]#Setelah di backup, silakan menyalin isi dari konfigurasi smb.conf yang sudah terkonfigurasi dengan PDC dibawah ini, jika ingin tahu prosesnya, kenapa bisa jadi seperti itu, Anda bisa membandingkannya dengan file smb.conf yang asli ☺
[root@server samba]# vi smb.conf
[global]
netbios name = LABOR
server string = Samba %v on %L
workgroup = daunpintu.net
os level = 65
prefered master = yes
domain master = yes
local master = yesdomain logons = yes
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_SNDBUF=8192 SO_RCVBUF=8129
time server = yes
hide dot files = yes
security = user
guest ok = no
invalid users = bin daemon sys man postfix mail ftpadmin
users = root
encrypt passwords = yes
log level = 2
log file = /var/log/samba/log.%L
debug timestamp = yessyslog = 1
# gunakan logon path untuk Windows NT/200x/XP
logon path = \\%L\profiles\%u
# gunakan logon home untuk Windows 9x
logon home = \\%L\profiles\%u
;logon script = logon.bat
[homes]
comment = Home Directories
browseable = nowriteable = yes
[netlogon]
path = /home/samba/
netlogon public = no
writeable = no
browseable = no
[profiles]path = /home/samba/profiles
writeable = yes
create mask = 0700
directory mask = 0700
browseable = no
kalo sudah diketik semua, simpan file tersebut dengan mengetikkan :wq (titik dua + w + q) tekan [enter]
[root@server samba]
#Berikut penjelasannya
:netbios name = LABOR
workgroup = daunpintu.net
netbios name artinya nama komputer yang dipake sebagai PDC dan nama domain disebutkan pada parameter workgroupos level = 65
prefered master = yes
domain master = yes
local master = yes
domain logons = yes
Parameter os level harus diisi dengan angka yang >32, angka 65 udah cukup, baris parameter domain master = yes
menunjukkan samba berlaku sebagai PDC.
hide dot files = yes
Berarti semua file berawalan "." akan disembunyikan.
security = user
Untuk membangun sebuah PDC, parameter security harus bernilai "user".Bila diperhatikan, ada bagian yang parameter depannya diberi tanda ";"
;logon script = logon.bat
File ini digunakan untuk menambah aksi-aksi tertentu, dan dapat disimpan dalam bentuk batch file, kalo mau mempelajari lebih dalam tentang script itu, bisa dicari via Google dengan query "samba script"Bagian
[global]
adalah konfigurasi utama yang akan mengeksekusi parameter-parameter didalamnya, sedangkan bagian
[profiles] merupakan bagian yang menunjukkan roaming profile, maksudnya server akan menyimpan profile-profile client yang login ke domain, dan meletakkannya di direktori /home/samba/profiles/
[nama client]
misal suatu client telah didaftarkan oleh Samba sebagai client untuk login ke domain daunpintu.net dengan nama user paijo, maka setiap paijo login ke domain daunpintu.net, profilenya akan disimpan di /home/samba/profiles/paijo. Setiap user paijo logout dari domain, server samba akan menyimpannya untuk di load kembali ketika user paijo sewaktu-waktuhendak login ke domain lagi .
Berdasarkan isi file smb.conf, ada beberapa hal yang harus dilakukan sebelum menjalankan samba:
1. Buat direktori netlogon di /home/samba/netlogon
[root@server samba]# cd /home
[root@server home]# mkdir samba
[root@server home]# lssamba lab
[root@server home]# mkdir samba/netlogon
[root@server home]# mkdir samba/profiles
[root@server home]# ls samba/netlogon profiles
2. Buat direktori profiles untuk tiap user dan memberikan kepemilikan direktori ke user yangbersangkutan (jangan lupa, user di sistem linux juga merupakan user Samba, jadi kalo Andaingin user di Windows sama dengan di Linux, tambahkan user di Linux lalu convert ke userSamba, nanti kita akan mempelajarinya, jadi tenanglah...☺
[root@server home]# cd /home/samba/profiles
[root@server profiles]# mkdir tomKalo sudah semua, restart si Samba ini dengan perintah:[root@server profiles]# service smb restart
Shutting down NMB services: [ OK ]
Shutting down SMB services: [ OK ]
Starting NMB services: [ OK ]Starting SMB services [ OK ]
[root@server profiles]#
Selanjutnya, kita akan menambahkan user yang akan digunakan komputer Windows (9x/ME, NT/200x, XP), perhatikan tahapan-tahapannya:1. Buat username Linux dengan perintah userad
d[root@server profiles]# useradd tom
[root@server profiles]# ls tom
[root@server profiles]# chown tom tom/
Pembuatan user baru ini tak perlu menggunakan password agar username tersebut tidak dapatdigunakan untuk telnet atau ssh ke server.Penggantian kepemilikandir milik tom, yang hanyadapat diakses oleh user tom.
2. Selanjutnya buat agar user name tersebut tersedia pada Samba server menggunakan perintah smbadduser seperti dibawah ini:
[root@server profiles]# smbadduser
----------------------------------------------------------
Written: Mike Zakharoff email:
1) Updates /etc/samba/smbpasswd
Copyright @ Postnix 2005 Postnix
2) Updates /etc/samba/smbusers
3) Executes smbpasswd for each new user
smbadduser unixid:ntid unixid:ntid ...
Example: smbadduser zak:zakharoffm johns:smithj
----------------------------------------------------------
[root@server profiles]# smbadduser tom:tom
Adding: tom to /etc/samba/smbpasswd
Added user tom.
----------------------------------------------------------
ENTER password for tom
New SMB password:
Retype new SMB password:
Password changed for user tom.
Password changed for user tom.
[root@server profiles]#
Gunakan perintah smbpasswd untuk mengganti password user samba, dan password di sistemLinux dengan di Server Samba dapat berbeda.Selanjutnya kita akan mengkonfigurasi workstation pada Windows 9x/ME, perhatikan lagi yah:
✔ Setting Client Windows 9x/ME Setting Client Windows 9x/MEKlik kanan pada icon Network Neighborhood (terletak di desktop) > Properties > Pilih Client forMicrosoft Networks (ada di drop-down Primary Network Logon) > Pilih Client for MicrosoftNetworks (yang ada di komponen network > Properties > Cek list “Log on to Windows NT Domain”> Isi juga domainnya, dalam contoh ini: daunpintu.net > klik OK lalu restartlah komputer Anda.Nanti setelah booting, kita akan disuruh memasukkan nama user, password, tapi dengan nama domain yang telah kita masukkan di settingan network. Tandanya, server Samba berhasil melakukan tugasnya sebagai PDC. Masukkan user tom, berikut dengan passwordnya untuk masuk ke domain daunpintu.net.Selesai, tugas Samba sebagai PDC pada client Windows 9x berhasil dilaksanakan dengan baik. Lalu bagaimana setting client pada OS Windows 200x/NT/XP?
✔ Setting Client Windows 200x/NT/XP Setting Client Windows 200x/NT/XPUntuk melakukan setting di Windows 200x/NT/XP, ada beberapa hal yang menjadi perhatian penting.Selain menggunakan user account, Windows 200x/NT/XP juga menggunakan machine account atau trust account dalam melakukan proses login ke PDC. Hal ini digunakan sebagai autentikasi agar tidak terjadi kerancuan apabila ada 2 komputer yang memiliki nama NetBIOS yang sama mencoba login ke server.
Oiya, ada satu hal yang perlu disampaikan bahwa pengguna OS keluarga Windows XP Home Edition (sangat disayangkan) tidak dapat bergabung dengan domain, karena keterbatasan kemampuan.Kalau masih memaksakan kemampuan Windows XP Home Edition yang terbatas, tentunya dengan segala resiko, silakan download tweakingnya di http://www.x-setup.net/downloads/home.aspHal yang perlu dilakukan adalah dengan menambahkan sebuah group pada sistem Linux yangmenjalankan Samba, membuat user yang mewakili tiap machine account workstation dan memasukkan user-user tersebut pada group yang dibuat.Langkah-langkah pembuatannya adalah seperti ini:[root@server tom]# groupadd machine
[root@server tom]# useradd -g machine -d /dev/null -s /bin/false winxp$
[root@server tom]# passwd -l winxp$Locking password for user winxp$.passwd: Success[root@server tom]# smbpasswd -a -m winxpAdded user winxp$.
[root@server tom]#
Bila diperhatikan, nama user yang mewakili machine account berakhir dengan tanda dollar($) dan khusus pada perintah smbpasswd nama user tidak diakhiri dengan dollar($). Supaya proses diatas tidak perlu diulangi lagi setiap komputer client mau login ke server Samba, maka ada script tambahan yang harus ditambahkan di file smb.conf.Tambahkan script berikut di bagian
[global] pada file smb.conf :add machine script = /usr/bin/useradd -d /dev/null -g samba-clients -s /bin/false -M %uScript diatas harus ditulis dalam satu baris yah...User root juga harus dimasukkan sebagai user Samba, caranya dengan perintah berikut:
[root@server tom]# smbpasswd -a rootNew SMB password:Retype new SMB password:Password changed for user root
[root@server tom]#
Password root di sistem Linux dengan password root di sistem Samba boleh beda, demi keamanan sebaiknya dibedakan, namun kalo Anda termasuk orang yang pelupa, lebih baik disamakan saja
☺Sekali lagi, OS dengan sistem Windows XP Home Edition tidak bisa gabung domain jadi kalau ada client yang terinstall Windows XP Home Edition, mending langsung uninstall Windowsnya, ganti dengan Windows 2000 (selain cepat, ringan, setting network juga mudah).
Hal yang harus dilakukan agar Windows XP Professional bisa gabung ke domain, perlu ditambahkan registry baru, perhatikan:
Buka regedit (Start > Run > ketik regedit) > HKEY_LOCAL_MACHINE > SYSTEM >CurrentControlSet > Services > Netlogon > Parameters > di window sebelah kanan, klik kanan > New > DWORD Value > beri nama requiresignorseal dengan value bernilai 0.
Kalo sudah ada registry dengan nama requiresignorseal, tinggal ganti valuenya dari 1 menjadi 0.Selanjutnya tutup regedit, kemudian restart komputernya.
Setelah itu, langkah-langkah berikutnya adalah:
Klik icon My Computer (biasanya ada di Desktop) > Properties > Pilih tab Computer Name > Pilih Change... > muncul window baru, isi domain dengan nama domain (dalam hal ini domainnya adalah daunpintu.net) > Keluar window baru yang akan menanyakan username dan password user yang bertanggung jawab terhadap domain daunpintu.net, isikan dengan user root dan passwordnya > nama komputer kita disini adalah winxp (sesuai dengan machine account yang ditambahkan pada group machine pada mesin Linux) > klik OK > Restart lagi komputernya.Selanjutnya pada saat komputer berhasil booting, maka akan keluar window yang akan menanyakan username dan password, namun hei..hei..ada opsi baru dibawahnya, yaitu pilihan Log On to.
Dengan munculnya opsi baru tersebut, maka komputer client telah berhasil login ke domain daunpintu.net, silakan masukkan username tom dan passwordnya, seperti yang telah kita tambahkan dengan menggunakan perintah smbadduser pada mesin Linux.
Oke, akhirnya selesai juga deh artikel ini. Saya mengucapkan banyak terima kasih banyak pada:– God with all HIS Talent and HIS big authority to all kind of life.– Linus Torvalds (linux creator)– Google.com , linux.or.id– RedHat 9 Operating System and all the team of RedHat.– VMware Workstations 5.50 (great software).– Buku-buku penunjang (ada diatas, prakata).– Semua kerabat yang, maaf, kalo ga kesebut..Thx all, saya juga masih mengerjakan artikel-artikel yang lainnya, jadi tunggu aja...

Kamis, 03 April 2008

PERHITUNGAN SUBNETING



Setelah anda membaca artikel Konsep Subnetting dan memahami konsep Subnetting dengan baik. Kali ini saatnya anda mempelajari teknik penghitungan subnetting. Penghitungan subnetting bisa dilakukan dengan dua cara, cara binary yang relatif lambat dan cara khusus yang lebih cepat. Pada hakekatnya semua pertanyaan tentang subnetting akan berkisar di empat masalah: Jumlah Subnet, Jumlah Host per Subnet, Blok Subnet, dan Alamat Host- Broadcast.

Penulisan IP address umumnya adalah dengan 192.168.1.2. Namun adakalanya ditulis dengan 192.168.1.2/24, apa ini artinya? Artinya bahwa IP address 192.168.1.2 dengan subnet mask 255.255.255.0. Lho kok bisa seperti itu? Ya, /24 diambil dari penghitungan bahwa 24 bit subnet mask diselubung dengan binari 1. Atau dengan kata lain, subnet masknya adalah: 11111111.11111111.11111111.00000000 (255.255.255.0). Konsep ini yang disebut dengan CIDR (Classless Inter-Domain Routing) yang diperkenalkan pertama kali tahun 1992 oleh IEFT.
Pertanyaan berikutnya adalah Subnet Mask berapa saja yang bisa digunakan untuk melakukan subnetting? Ini terjawab dengan tabel di bawah:
Subnet Mask Nilai CIDR
255.128.0.0/9
255.192.0.0/10
255.224.0.0/11
255.240.0.0/12
255.248.0.0/13
255.252.0.0/14
255.254.0.0/15
255.255.0.0/16
255.255.128.0/17
255.255.192.0/18
255.255.224.0/19

Subnet Mask Nilai CIDR
255.255.240.0/20
255.255.248.0/21
255.255.252.0/22
255.255.254.0/23
255.255.255.0/24
255.255.255.128/25
255.255.255.192/26
255.255.255.224/27
255.255.255.240/28
255.255.255.248/29
255.255.255.252/30

SUBNETTING PADA IP ADDRESS CLASS C
Ok, sekarang mari langsung latihan saja. Subnetting seperti apa yang terjadi dengan sebuah NETWORK ADDRESS 192.168.1.0/26 ?
Analisa: 192.168.1.0 berarti kelas C dengan Subnet Mask /26 berarti 11111111.11111111.11111111.11000000 (255.255.255.192).
Penghitungan: Seperti sudah saya sebutkan sebelumnya semua pertanyaan tentang subnetting akan berpusat di 4 hal, jumlah subnet, jumlah host per subnet, blok subnet, alamat host dan broadcast yang valid. Jadi kita selesaikan dengan urutan seperti itu:
Jumlah Subnet = 2x, dimana x adalah banyaknya binari 1 pada oktet terakhir subnet mask (2 oktet terakhir untuk kelas B, dan 3 oktet terakhir untuk kelas A). Jadi Jumlah Subnet adalah 22 = 4 subnet
Jumlah Host per Subnet = 2y - 2, dimana y adalah adalah kebalikan dari x yaitu banyaknya binari 0 pada oktet terakhir subnet. Jadi jumlah host per subnet adalah 26 - 2 = 62 host
Blok Subnet = 256 - 192 (nilai oktet terakhir subnet mask) = 64. Subnet berikutnya adalah 64 + 64 = 128, dan 128+64=192. Jadi total subnetnya adalah 0, 64, 128, 192.
Bagaimana dengan alamat host dan broadcast yang valid? Kita langsung buat tabelnya. Sebagai catatan, host pertama adalah 1 angka setelah subnet, dan broadcast adalah 1 angka sebelum subnet berikutnya.

Subnet
192.168.1.0
192.168.1.64
192.168.1.128
192.168.1.192
Host Pertama
192.168.1.1
192.168.1.65
192.168.1.129
192.168.1.193
Host Terakhir
192.168.1.62
192.168.1.126
192.168.1.190
192.168.1.254
Broadcast
192.168.1.63
192.168.1.127
192.168.1.191
192.168.1.255

Kita sudah selesaikan subnetting untuk IP address Class C. Dan kita bisa melanjutkan lagi untuk subnet mask yang lain, dengan konsep dan teknik yang sama. Subnet mask yang bisa digunakan untuk subnetting class C adalah:
Subnet Mask Nilai CIDR
255.255.255.128/25
255.255.255.192/26
255.255.255.224/27
255.255.255.240/28
255.255.255.248/29
255.255.255.252/30

SUBNETTING PADA IP ADDRESS CLASS B
Berikutnya kita akan mencoba melakukan subnetting untuk IP address class B. Pertama, subnet mask yang bisa digunakan untuk subnetting class B adalah:
Subnet Mask Nilai CIDR
255.255.128.0/17
255.255.192.0/18
255.255.224.0/19
255.255.240.0/20
255.255.248.0/21
255.255.252.0/22
255.255.254.0/23
Subnet Mask Nilai CIDR
255.255.255.0/24
255.255.255.128/25
255.255.255.192/26
255.255.255.224/27
255.255.255.240/28
255.255.255.248/29
255.255.255.252/30

Ok, kita coba satu soal untuk Class B dengan network address 172.16.0.0/18.
Analisa: 172.16.0.0 berarti kelas B, dengan Subnet Mask /18 berarti 11111111.11111111.11000000.00000000 (255.255.192.0).
Penghitungan:
Jumlah Subnet = 2x, dimana x adalah banyaknya binari 1 pada 2 oktet terakhir. Jadi Jumlah Subnet adalah 22 = 4 subnet
Jumlah Host per Subnet = 2y - 2, dimana y adalah adalah kebalikan dari x yaitu banyaknya binari 0 pada 2 oktet terakhir. Jadi jumlah host per subnet adalah 214 - 2 = 16.382 host
Blok Subnet = 256 - 192 = 64. Subnet berikutnya adalah 64 + 64 = 128, dan 128+64=192. Jadi total subnetnya adalah 0, 64, 128, 192.
Alamat host dan broadcast yang valid?
Subnet
172.16.0.0
172.16.64.0
172.16.128.0
172.16.192.0
Host Pertama
172.16.0.1
172.16.64.1
172.16.128.1
172.16.192.1
Host Terakhir
172.16.63.254
172.16.127.254
172.16.191.254
172.16.255.254
Broadcast
172.16.63.255
172.16.127.255
172.16.191.255
172.16..255.255

Masih bingung? Ok kita coba satu lagi untuk Class B.Bagaimana dengan network address 172.16.0.0/25.
Analisa: 172.16.0.0 berarti kelas B, dengan Subnet Mask /25 berarti 11111111.11111111.11111111.10000000 (255.255.255.128).

Penghitungan:
Jumlah Subnet = 29 = 512 subnet
Jumlah Host per Subnet = 27 - 2 = 126 host
Blok Subnet = 256 - 128 = 128.
Alamat host dan broadcast yang valid?
Subnet
172.16.0.0
172.16.0.128
172.16.1.0

172.16.255.128
Host Pertama
172.16.0.1
172.16.0.129
172.16.1.1

172.16.255.129
Host Terakhir
172.16.0.126
172.16.0.254
172.16.1.126

172.16.255.254
Broadcast
172.16.0.127
172.16.0.255
172.16.1.127

172.16.255.255

Masih bingung juga? Ok sebelum masuk ke Class A, coba ulangi lagi dari Class C, dan baca pelan-pelan

SUBNETTING PADA IP ADDRESS CLASS A
Kalau sudah mantab dan paham, kita lanjut ke Class A. Konsepnya semua sama saja. Perbedaannya adalah di OKTET mana kita mainkan blok subnet. Kalau Class C di oktet ke 4 (terakhir), kelas B di Oktet 3 dan 4 (2 oktet terakhir), kalau Class A di oktet 2, 3 dan 4 (3 oktet terakhir). Kemudian subnet mask yang bisa digunakan untuk subnetting class A adalah semua subnet mask dari CIDR /8 sampai /30.
Kita coba latihan untuk network address 10.0.0.0/16.
Analisa: 10.0.0.0 berarti kelas A, dengan Subnet Mask /16 berarti 11111111.11111111.00000000.00000000 (255.255.0.0).

Penghitungan:
Jumlah Subnet = 28 = 256 subnet
Jumlah Host per Subnet = 216 - 2 = 65534 host
Blok Subnet = 256 - 255 = 1. Jadi subnet lengkapnya: 0,1,2,3,4, etc.
Alamat host dan broadcast yang valid?
Subnet
10.0.0.0
10.1.0.0

10.254.0.0
10.255.0.0
Host Pertama
10.0.0.1
10.1.0.1

10.254.0.1
10.255.0.1
Host Terakhir
10.0.255.254
10.1.255.254

10.254.255.254
10.255.255.254
Broadcast
10.0.255.255
10.1.255.255

10.254.255.255
10.255.255.255

Mudah-mudahan sudah setelah anda membaca paragraf terakhir ini, anda sudah memahami penghitungan subnetting dengan baik. Kalaupun belum paham juga, anda ulangi terus artikel ini pelan-pelan dari atas. Untuk teknik hapalan subnetting yang lebih cepat, tunggu di artikel berikutnya
Catatan: Semua penghitungan subnet diatas berasumsikan bahwa IP Subnet-Zeroes (dan IP Subnet-Ones) dihitung secara default. Buku versi terbaru Todd Lamle dan juga CCNA setelah 2005 sudah mengakomodasi masalah IP Subnet-Zeroes (dan IP Subnet-Ones) ini. CCNA pre-2005 tidak memasukkannya secara default (meskipun di kenyataan kita bisa mengaktifkannya dengan command ip subnet-zeroes), sehingga mungkin dalam beberapa buku tentang CCNA serta soal-soal test CNAP, anda masih menemukan rumus penghitungan Jumlah Subnet = 2x - 2

REFERENSI
Todd Lamle, CCNA Study Guide 5th Edition, Sybex, 2005.
Module CCNA 1 Chapter 9-10, Cisco Networking Academy Program (CNAP), Cisco Systems.
Hendra Wijaya, Cisco Router, Elex Media Komputindo, 2004.

ROMY SATRIOWAHONO

Selasa, 15 Januari 2008

MEMBACKUP EMAIL KE HARDISK/FLASHDISK

1. BUKA MENU Tools – Options – Maintenance
2. Klik Store Folder
3. Klik tombol Change Tentukan lokasi penyimpanan missal di Flashdisk
4. pilih folder data email
5. Klik OK
6. Restart Komputer , untuk memulai menyalin file tersebut

- Jika computer anda tidak di restart file belum dapat di copy
Sebelum ada membackup email buat dulu folder di flashdisk/hardisk

MEMIINDAHKAN EMAIL DARI FLASHDISK/HARDISK KE OULOOK EXPRESS
7. KLIK FILE – IMPORT –Messages
8. Pilih Microsoft Outlook Express 6
9. Klik Next
10. Pilih Import mail frm an OE6 Store directory
11. Klik OK
12. Klik tombol Browse
13. Pilih Lokasi Folder yang akan di copy missal : Data Email
14. Klik OK
15. Klik OK
16. Pilih All Folder
17. Klik Next , Selanjutnya Outlook Express menyalin semua file
18.Klik Finish , lihat hasilnya

semoga berhasil



















Pilih

Senin, 14 Januari 2008

MEMBUAT ROUTER DENGAN REDHAT9

I. PRA INSTALASI
^^^^^^^^^^^^^^^^
Edit BIOS:
- urutan boot CDROM pertama.
- matikan soundcard & modem onboard jika ada.
- matikan serial port & usb jika dianggap perlu, karena mungkin tidak digunakan.
- matikan ‘Halt on error’ dengan ‘no error’ jika perlu, -> utk boot tanpa keyboard.

II. INSTALASI
^^^^^^^^^^^^^
1. Boot dari CD#1 RH9, tekan enter.
Note: mode grafis lebih memudahkan untuk melakukan setup selanjutnya menggunakan mouse.
2. SKIP testing cd media.
3. NEXT, Pilih Language = English default.
4. NEXT, pilih Keyboard = U.S. English.
5. NEXT, pilih Mouse, default PS2 3 tombol.
Note: pada saat operasional (mode teks) mouse/gpm tidak perlu dijalankan.
6. NEXT, pilih tipe instalasi CUSTOM.
7. NEXT, Manually partition with Disk Druid.
8. NEXT, sebaiknya buat partisi terpisah untuk /boot, /tmp, /var, dan /
/boot = memisahkan file2 boot linux agar berada di partisi awal dan proses booting lebih cepat
/tmp dan /var berisi file temporary, log dsb yg cenderung bertambah,.. harus dikarantina.
Ukuran partisi:
/boot sekitar 100 MByte
/tmp sekitar 300 MByte
/ sekitar 1,5 GByte
Swap normalnya sebesar 2 kali ukuran RAM. Misal RAM=128MB -> Swap=256MB.
/Var bisa dihabiskan untuk ruang hardisk yang tersisa.
Tetapi pembagian partisi ini tergantung selera.
Note: Pilih opsi “check bad blocks” jika perlu. Direktori default tempat Squid Cache berada di /var.
9. NEXT, pilih boot loader default = GRUB.
Note: konfigurasi grub dapat langsung diaktifkan dengan mengedit file /boot/grub/grub.conf
10. NEXT, Network Configuration, ganti DHCP pada eth0 & eth1 dengan ip statik yang telah ditentukan sebelumnya.
11. NEXT, pilih konfigurasi firewall = NO FIREWALL.
Note: konfigurasi firewall & NAT dilakukan secara manual setelah instalasi.
12. NEXT, Additional Language Support = English (USA), default.
13. NEXT, Time Zone Selection = Asia/Jakarta.
14. NEXT, Masukkan password ROOT 2 kali!
15. NEXT, Authentication Configuration gunakan default, enable MD5 dan Shadow.
16. NEXT, Package Group Selection.
Hilangkan Paket berikut ini:
- X Window System
- Gnome Desktop Environtment
- Graphical Internet
- Office/Productivity
- Sound and Video
- Graphics
- Printing Support
- dan paket2 lain yang berhubungan dengan grafis x-windows yang mungkin terinstall.
Pilih instalasi paket-paket berikut ini:
- Text-based Internet
Detail:
- lynx -> bisa untuk keperluan pengujian bandwidth
- pine -> editor yang ‘relatif’ lebih manusiawi dibanding VI
- paket yang lain bisa dihilangkan.
- Web Server
Pilih default Detail, sudah termasuk di dalamnya SQUID.
- Windows File Server = Samba, jika diinginkan.
- DNS Name Server, sebaiknya digunakan untuk Client link Internasional.
- FTP Server, jika diinginkan.
- Network Server, jika ingin menjadikan server DHCP, Telnet, dll.
- Development Tools, sebaiknya diinstall jika dirasakan ada program luar tambahan yg perlu diinstall dan di-compile.
- Kernel Development, jika ingin meng-compile kernel.
- System Tools.
pilih details:
- Ethereal -> networking tool
- mc -> Shell yang user-friendly
- nmap -> networking tool
- shapecfg -> untuk traffic shaper
Kemudian pilih (checklist) Select Individual Packages.
Tujuannya untuk menambahkan beberapa paket penting lainnya yang tidak dicantumkan pada daftar global paket di atas,
yaitu SNMP-Client, MRTG, dan IPTRAF.
- MRTG -> pilih di kelompok Applications - Internet - mrtg
- IPTRAF -> pilih di kelompok Applications - System - iptraf
- SNMP-Client -> pilih di kelompok Applications - System - net-snmp-utils
17. NEXT, Unresolved Dependency pilih Install packages to satisfy dependency. Dalam hal ini paket PERL-URI.
18. NEXT, Siap menginstall
19. NEXT, Proses instalasi berlangsung……. masukkan CD#2 dan CD#3 jika diminta.
20. NEXT, No I do not want to create a boot diskette
21. NEXT, Reboot - keluarkan CD Instalasi.
III. PASCA INSTALASI
^^^^^^^^^^^^^^^^^^^^
1. Login root.
2. Pastikan kedua Ethernet Card sudah terinstall benar termasuk default gateway-nya.
Cek menggunakan perintah: ‘ifcfg’ dan ‘route -n’. Asumsi eth0 untuk koneksi keluar (ke radio)
dan eth1 untuk dihubungkan ke internal LAN client.
3. Konfigurasi minimal Network Address Translation (NAT) untuk internal.
- vi /etc/sysctl.conf -> net.ipv4.ip_forward = 1
- sysctl -p
- iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
- chkconfig iptables on
- iptables-save > /etc/sysconfig/iptables
Sampai di sini Server sudah bisa digunakan untuk mengkoneksikan client ke internet.
4. Konfigurasi Squid dan Transparent Proxy
- vi /etc/squid/squid.conf
# NETWORK OPTIONS
http_port 8080
# OPTIONS WHICH AFFECT THE CACHE SIZE
cache_mem xxx MB
-> xxx= seperempat ukuran RAM, jadi utk RAM 128 maka xxx=32
# LOGFILE PATHNAMES AND CACHE DIRECTORIES
cache_dir ufs /var/spool/squid xxx 16 256
-> xxxx = kapasitas total cache yang diinginkan dalam MByte.
# ACCESS CONTROLS
acl our_networks src 192.168.0.0/24
-> jika network internal adalah 192.168.0.0/24
http_access allow our_networks
# HTTPD-ACCELERATOR OPTIONS
httpd_accel_host virtual
httpd_accel_port 80
httpd_accel_with_proxy on
httpd_accel_uses_host_header on
- service squid start
- chkconfig squid on
- iptables -t nat -A PREROUTING -i eth0 -p tcp -m tcp –dport 80 -j REDIRECT –to-ports 8080
5. Proteksi lanjut mencegah serangan Denial of Service (DoS Attack)
Anti serangan PING Flood
- iptables -A INPUT -p icmp –icmp-type echo-request -m limit –limit 5/s –limit-burst 10 -j ACCEPT
- iptables -A INPUT -p icmp –icmp-type echo-request -j DROP
- iptables -A INPUT -p icmp –icmp-type ! echo-request -j ACCEPT
Anti serangan TCP SYN Flood
- iptables -A INPUT -p tcp –syn -m limit –limit 5/s –limit-burst 10 -j ACCEPT
- iptables -A INPUT -p tcp –syn -j DROP
- iptables -A INPUT -p tcp ! –syn -j ACCEPT
Aturan FORWARD anti DoS dari manual iptables
- iptables -A FORWARD -p tcp -m tcp –tcp-flags SYN,RST SYN -j TCPMSS –clamp-mss-to-pmtu
6. Simpan konfigurasi IPTABLES secara permanen menggunakan perintah:
- iptables-save > /etc/sysconfig/iptables
7. Matikan service yang tidak diperlukan, misalnya:
- chkconfig –level 2345 netfs off
- chkconfig –level 2345 rawdevices off
- chkconfig –level 2345 atd off
- chkconfig –level 2345 gpm off
- chkconfig –level 2345 portmap off
- chkconfig –level 2345 sendmail off
- chkconfig –level 2345 isdn off
- chkconfig –level 2345 rhnsd off
- chkconfig –level 2345 anacron off
- chkconfig –level 2345 nfslock off
- chkconfig –level 2345 xinetd off
8. Percepat delay boot GRUB pada saat booting:
- vi /boot/grub/grub.conf
-> ganti “timeout=10″ menjadi “timeout=1″
9. Konfigurasi Web Server
Hidupkan Web Server:
- chkconfig httpd on
- service httpd start
Note: Halaman muka Web Server berada pada direktori /var/www/html
Ganti/buat file ‘index.html’ jika perlu, untuk menyembunyikan informasi.
Untuk menguji, jalankan “lynx localhost”.
10. Konfigurasi SNMP agent dan MRTG
- vi /sbin/mrtg-gen
- kemudian copy script berikut ke file /sbin/mrtg-gen
dengan perintah pada mode edit (tanpa tanda “+”) : Esc + i + Esc + insert :
————————-potong dibawah ini——————————–
#!/bin/sh
clear
if [ “$1″ = “” ]
then
echo | date
echo “”
echo -e “\a”
echo “MRTG Auto Compiler v.2 by rizky.md@gmail.com”
echo “”
echo “———————————————-”
echo “Cara penggunaan :”
echo “./mrtg-gen snmp — untuk setting snmp “
echo “./mrtg-gen config — untuk bikin config file “
echo “./mrtg-gen index — untuk generate html file “
echo “./mrtg-gen exe — untuk file executor “
echo “———————————————-”
echo “Tested on Redhat,CentOS,IGOS,FEDORA & RHEL try yours ….”
echo “”
echo “Have a nice day …”
echo -e “\a”
exit
fi
if [ “$1″ = “snmp” ]
then
echo “Inputkan community string ( contoh : kentang ) :”
read CM
echo “Inputkan file config snmp ( contoh : /etc/snmp/snmpd.conf ) :”
read SMLOC
echo “Inputkan contact person system ( contoh : Rizky M. Dinata ) :”
read SYC
echo “Inputkan lokasi system ( contoh : Australia 33th Avenue DH BLD 4th floor ) :”
read SYAD
echo “Inputkan identitas system ( contoh : My-BlackboX ) :”
read SYID
echo “rocommunity $CM
syslocation $SYAD
sysname $SYID
syscontact $SYC” > $SMLOC
echo “Service snmp di restart …”
echo “”
service snmpd restart
exit
fi
echo “Inputkan lokasi file MRTG ( contoh : /var/www/html/mrtg ) :”
read GLB
echo “Inputkan community string snmp target ( contoh : public ) :”
read NAMA
echo “Inputkan IP address target ( contoh : 192.168.0.1 ) :”
read ALA
echo “Inputkan lokasi file configurasi MRTG ( contoh : /etc/mrtg ) :”
read KON
echo “Inputkan nama file configurasi MRTG ( contoh : test.cfg ) :”
read CFG
if [ “$1″ = “exe” ]
then
echo “
killall mrtg
rm $KON/*.pid
mrtg $KON/$CFG ” > /etc/mrtg-run
chmod 755 /etc/mrtg-run
ln -s /etc/mrtg-run /etc/init.d/mrtg-run
ln -s /etc/mrtg-run /etc/rc.d/rc3.d/K80mrtg-run
ln -s /etc/mrtg-run /etc/rc.d/rc3.d/S80mrtg-run
echo -e “\a”
echo “Konfigurasi eksekutor selesai .”
echo “Untuk menjalankan secara manual :”
echo “cukup running script : /etc/mrtg-run”
exit
fi
if [ “$1″ = “config” ]
then
cfgmaker –global “WorkDir: $GLB” –global “Options[_]: growright,bits” –global “RunAsDaemon:Yes” –global “Interval:5″ –global “Refresh:300″ $NAMA@$ALA > $KON/$CFG 2>/dev/null
echo -e “\a”
echo “File konfigurasi MRTG telah selesai dibuat.”
echo “lokasi file configurasi anda : $KON/$CFG “
echo “Lanjutkan dengan membuat index file.”
exit
fi
if [ “$1″ = “index” ]
then
indexmaker –columns=1 –show=day –pagetop=MRTG-GEN-V2 –title=Network-Traffic-Analysis –output=$GLB/index.html $KON/$CFG 2>/dev/null
rm $KON/*.pid
mrtg $KON/$CFG
echo -e “\a”
echo “File index telah selesai dibuat.”
echo “lokasi file index anda : $GLB “
echo “Proses MRTG telah berjalan.”
exit
fi
##########################################
# The world will never know … #
# and i will never understand #
# losing my grip … slepted away #
# tryin’ to find my way back #
# to the main purposes why GOD create me #
##########################################
——————————akhir diatas ini—————————————
Untuk mengakhiri mode edit (tanpa tanda “+”) : Esc + : + wq
kemudian ubah atribut file ke mode Executable : chmod 755 /sbin/mrtg-gen
jalankan script dengan perintah : /sbin/mrtg-gen
isi konfigurasi yang ditanyakan sesuai dengan kebutuhan setting anda.
Berikut disertakan script untuk melakukan konfigurasi secara lengkap
pada router dengan system operasi RedHat 9 dengan beberapa langkah mudah.
1. vi /sbin/konfigurasi
2. copy script berikut ke file /sbin/konfigurasi
dengan perintah pada mode edit (tanpa tanda “+”) : Esc + i + Esc + insert :
—————————-mulai dibawah ini ———————————
#!/bin/sh
############################
# Assalamualaikum WR.WB #
# cara menjalankan cript #
# ./konfigurasi #
# configurasi script tidak #
# perlu dirubah , tapi #
# silahkan untuk di #
# kembangkan sesuai dengan #
# kreativitas anda, karena #
# ini hanya script #
# sederhana …. #
############################
echo -e “####################################”
echo -e “######## BASIC ROUTER SETUP ########”
echo -e “####################################”
echo -e “####### by rizky.md@gmail.com ######”
echo -e “####################################”
echo “Not an ADVANCE setup only default ../n”
echo “Masukkan device ( contoh : eth0 ) ?”
read dev
echo “Masukkan IP eth0″
read ip
echo “Masukkan netmask”
read net
echo “Masukkan Gateway”
read gw
echo -e “DEVICE=$dev/nBOOTPROTO=static/nONBOOT=yes/nIPADDR=$ip/nNETMASK=$net/nGATEWAY=$gw/n” > /etc/sysconfig/network-scripts/ifcfg-eth0
echo “Masukkan device ( contoh : eth1 ) ?”
read dev2
echo “Masukkan IP eth1″
read ip2
echo “Masukkan netmask”
read net2
echo “Masukkan Gateway”
read gw2
echo -e “DEVICE=$dev2/nBOOTPROTO=static/nONBOOT=yes/nIPADDR=$ip2/nNETMASK=$net2/nGATEWAY=$gw2/n” > /etc/sysconfig/network-scripts/ifcfg-eth1
echo -e “/nKonfigurasi Interface Jaringan selesai !/a… ok/n”
echo “Masukkan DNS primary “
read ns1
echo “Masukkan DNS secondary “
read ns2
echo -e”nameserver $ns1/nnameserver $ns2″ > /etc/resolv.conf
echo -e “/nKonfigurasi DNS selesai !/a… ok/n”
echo “Aktifkan Network ( yes / no )”
read act
echo “Masukkan Hostname “
read hst
echo -e “NETWORKING=$act/nHOSTNAME=$hst.quasar.net.id” > /etc/sysconfig/hosts
echo -e “/nKonfigurasi Host selesai !/a… ok/n”
echo -e “——- Router $hst NET ———/n— configured with oto-conf —/n
ip eth0 = $ip/n
ip eth1 = $ip2/n
DNS = $ns1/n” > /etc/motd
echo -e “/nKonfigurasi Pesan Login selesai !/a… ok/n”
echo -e “net.ipv4.ip_forward = 1/nnet.ipv4.conf.default.rp_filter = 1/nkernel.sysrq = 0/nkernel.core_uses_pid = 1″ > /etc/sysctl.conf
echo -e “/nKonfigurasi IP Forwarding selesai !/a… ok/n”
echo “Masukkan network ip lokal untuk di NAT ( contoh : 192.168.1.0/24 ) : “
read IPLOKNAT
/sbin/iptables -A POSTROUTING -t nat -s $IPLOKNAT -j MASQUERADE
/etc/init.d/iptables save
/etc/init.d/iptables restart
echo -e “/nKonfigurasi IP NAT selesai !/a… ok/n”
echo “Masukkan nama Community SNMP: “
read SNMPDN
echo “Masukkan lokasi router : “
read SNMPDLOC
echo “Masukkan nama admin system : “
read SNMPDADD
echo -e “rocommunity $SMPDN/nsyslocation $SNMPDLOC/nsyscontact $SNMPDADD” > /etc/sysconfig/snmpd.conf
cp /etc/motd /etc/issue /etc/issue
#######################
# Simple need … #
#######################
——————————selesai diatas ini ————————————————-
Untuk mengakhiri mode edit (tanpa tanda “+”) : Esc + : + wq
kemudian ubah atribut file ke mode Executable : chmod 755 /sbin/konfigurasi
jalankan script dengan perintah : /sbin/konfigurasi
IV. PERINTAH TAMBAHAN
^^^^^^^^^^^^^^^^^^^^^
Berikut adalah perintah yang mungkin dibutuhkan untuk melakukan setting pada router linux Red Hat 9
1. Command untuk install aplikasi di linux :
- Melakukan install aplikasi
rpm -ivh [nama-paket-installasi]
contoh installasi paket aplikasi IFTOP untuk check traffic :
rpm -ivh iftop-0.16-0.i386.rpm
- Melakukan uninstall aplikasi
rpm -e [nama-paket-installasi]
contoh installasi paket aplikasi IFTOP untuk check traffic :
rpm -e iftop-0.16-0.i386
- Melakukan check aplikasi terinstall
rpm -qa |grep [nama aplikasi]
contoh melakukan check aplikasi iftop :
rpm -qa |grep iftop
2. Command untuk Firewall (NAT,ACCEPT,DROP) :
# NAT :
- Untuk menambahkan nat dari blok ip lokal tertentu :
iptables -A POSTROUTING -t nat -s [blok-ip] -j MASQUERADE
contoh untuk client lokal blok ip 192.168.1.0/24 : iptables -A POSTROUTING -t nat -s 192.168.1.0/24 -j MASQUERADE
- Untuk mengurangi nat dari blok ip lokal tertentu :
iptables -D POSTROUTING -t nat -s [blok-ip] -j MASQUERADE
contoh untuk client lokal blok ip 192.168.1.0/24 : iptables -D POSTROUTING -t nat -s 192.168.1.0/24 -j MASQUERADE
contoh melihat NAT pada ip 10.75.3.23 : iptables -vnL -t nat |grep 10.75.3.23
contoh melihat list keseluruhan NAT : iptables -vnL -t nat
# DROP (MENOLAK) :
- Untuk menambahkan BLOCK dari ip tertentu :
iptables -A INPUT -s [ip-asal] -j DROP
- Untuk mengurangi BLOCK dari ip tertentu :
iptables -D INPUT -s [ip-asal] -j DROP
- Untuk menambahkan BLOCK ke ip tertentu :
iptables -A OUTPUT -d [ip-tujuan] -j DROP
- Untuk mengurangi BLOCK dari blok ip tertentu :
iptables -D OUTPUT -d [ip-tujuan] -j DROP
# ACCEPT (MENERIMA) :
- Untuk menambahkan BLOCK dari ip tertentu :
iptables -A INPUT -s [ip-asal] -j ACCEPT
- Untuk mengurangi BLOCK dari ip tertentu :
iptables -D INPUT -s [ip-asal] -j ACCEPT
- Untuk menambahkan BLOCK ke ip tertentu :
iptables -A OUTPUT -d [ip-tujuan] -j ACCEPT
- Untuk mengurangi BLOCK dari blok ip tertentu :
iptables -D OUTPUT -d [ip-tujuan] -j ACCEPT
# Untuk menampilkan konfigurasi firewall keseluruhan :
iptables -vnL -> untuk aturan INPUT, OUTPUT dan FORWARD
iptables -vnL -t nat -> untuk aturan NAT
# Untuk melakukan restore (load-ulang) iptables :
iptables-restore /etc/sysconfig/nama-file-iptables
service iptables save
service iptables restart
3. Command untuk routing :
- Menambahkan default gateway :
route add default gw [ip_gateway]
contoh gateway 10.75.3.254 : route add default gw 10.75.3.254
- Menghapus default gateway :
route del default gw [ip_gateway]
contoh gateway 10.75.3.254 : route del default gw 10.75.3.254
4. Melakukan check atau alokasi ip address :
- melakukan check ip :
ifconfig [nama-interface]
contoh : ifconfig eth0
- memberi IP pada interface tertentu :
ifconfig [nama-interface] [ip-address] netmask [netmask] broadcast [broadcast-address] up
contoh : ifconfig eth0 10.75.3.23 netmask 255.255.255.0 broadcast 10.75.3.255 up
- memberi IP pada interface yang sudah memiliki IP :
ifconfig [nama-interface:alias] [ip-address] netmask [netmask] broadcast [broadcast-address] up
contoh : ifconfig eth0:1 10.75.3.24netmask 255.255.255.0 broadcast 10.75.3.255 up
nama alias tidak boleh sama, begitu juga IP yang dialokasikan tidak boleh sama juga.
5. Check traffic dengan IPTRAF :
iptraf -d [nama-interface]
contoh : iptraf -d eth0
6. Melakukan check link untuk melihat trouble pada node yang dilalui :
traceroute [ip-destinasi]
contoh : traceroute www.ragnarok.co.id
7. Melakukan check fungsi DNS :
nslookup [nama-domain]
contoh : nslookup www.google.com
bila domain tidak dapat di resolve, coba ping ke ip domain, bila ping ke nama domain tidak bisa
tetapi ping ke ip domain bisa, maka trouble ada di DNS server ( coba ping DNS server ).
8. Melakukan check traffic dengan iftop :
- Untuk melakukan check traffic pada interface tertentu :
iftop -i [interface-terhubung]
contoh interface eth1 : iftop -i eth1
- Untuk melakukan check traffic IP tertentu :
iftop -F [ip-address/netmask] -i [interface-terhubung]
contoh traffic ip 10.75.3.23 : iftop -F 10.75.3.23/32 -i eth1
- Untuk melakukan check traffic network IP tertentu :
iftop -F [network-address/netmask] -i [interface-terhubung]
contoh traffic ip 10.75.3.23 : iftop -F 10.75.3.0/24 -i eth1
9. Melakukan check servis snmp berjalan atau tidak :
snmpwalk -c [community-name] -v 1 [ip-host]
contoh untuk ip 10.75.3.23 dengan community name cl13nt :
snmpwalk -c cl13nt -v 1 10.75.3.23
10.Melakukan check ping :
ping -c [jumlah-check] -s [besar-packet] [ip-address]
contoh untuk check ping ke ip 10.75.3.23 sebanyak 50 kali dengan paket 1400 :
ping -c 50 -s 1400 10.75.3.23