Archive for the 'FreeBsd' Category

Jun 25 2009

Membuat DNS local dengan freebsd

Published by under FreeBsd

Huh cari cari tutorial ngk dapet-dapet untuk ada temen yang mo
sharing...coba2  dewe akhire bisa deeeh....... tapi ngk tau juga...
sapa mo nyoba silahkan...ni sekali coba bisa sih..tapi    
besok mo coba lagi hehehee......langkah2 nya...

1. di /etc/resolf.conf ~ ditambahi nameserver (iplocal)
   yang mo di  jadiin dns

2. di /etc/host.conf ~ dibalik jadi 1.dns 2.hosts

3. conf /etc/namedb/named.conf

terutama di bagian....

// If named is being used only as a local resolver, this is a safe 
   default.

// For named to be accessible to the network, comment this option, 
   specify

// the proper IP address, or delete this option. listen-on 
{ 127.0.0.1;172.10.16.11; };(ditambahi ip local yng mo dijadiin DNS)
(sama nambah zone baru) coontohnya
zone "16.10.172.in-addr.arpa" {

         type master;

         file "master/16.10.172.in-addr.arpa";

        };

zone "angga.net.id" {         

         type master;         

         file "master/angga.net.id";        

         };  
Format ini ada contohnya di /etc/named.conf

4 jalankan sh make-localhost

   Letaknya di /etc/named

Edit filenya 16.10.172.in-addr.arpa yang letaknya di
/etc/namaed/master(untuk contoh aja)

; From: @(#)localhost.rev 5.1 (Berkeley) 6/30/90

; $FreeBSD: src/etc/namedb/PROTO.localhost.rev,v 1.6 
  2000/01/10 15:31:40 peter E

; This file is automatically edited by the `make-localhost' script in

; the /etc/namedb directory.

;
$TTL 3600
@         IN       SOA   angga.net.id. root.angga.net.id. (

                                 20070720 ; Serial

                                 3600 ; Refresh

                                 900 ; Retry

                                 3600000 ; Expire

                                 3600 ) ; Minimum

          IN       NS    ns1.angga.net.id.

          IN       NS    ns2.angga.net.id.

1         IN       PTR   ro.angga.net.id. (angka 3 dan 1
identitas ip gatewaynya ato yang mo dijadikan DNS ip 
belakangnya berapa)

11         IN       PTR   angga.net.id.

2) angga.net.id

   ; From: @(#)localhost.rev 5.1 (Berkeley) 6/30/90

   ; $FreeBSD: src/etc/namedb/PROTO.localhost.rev,v 1.6 
     2000/01/10 15:31:40 peter E

   ;

   ; This file is automatically edited by the `make-localhost' script in

   ; the /etc/namedb directory.

   ;

$TTL 3600

@         IN       SOA   angga.net.id. root.angga.net.id. (

                                 20070720 ; Serial

                                 3600 ; Refresh

                                 900 ; Retry

                                 3600000 ; Expire

                                 3600 ) ; Minimum

          IN       NS    ns1.cobacoba.net.id.

          IN       NS    ns2.cobacoba.net.id.

@         IN       A     172.10.16.11 

web         IN       A     172.26.78.29

Format ini ada contohnya di /etc/named/master
(tinggal di edit aja sesuai keinginan....wah wah wah..cobawoba lagi aahhhh)
5. jgn lupa di /etc/rc.conf di tambahi named_enable="YES"
6. rndc reload dijalankan....moga sukses.....
7. historinya.ip 172.26.78.29 ibaratnya ip publik, dia jadi gateway
ke ip 172.10.16.1....Terus 1p 172.10.16.11 DNS nya....
bis itu di restart aja..moga bisa..selamat mencoba oke boss....
wis aq meh bobox    sik...jane yo ngk ngantuk..capek deeh......

Comments Off on Membuat DNS local dengan freebsd

Jun 25 2009

Lupa Pasword Root freebsd

Published by under FreeBsd

Lupa Password Root FreeBSD

BSDPernahkah anda lupa password root ? , saya pernah mengalami nya
faktor penyebab lupa password biasanya disebabkan karena terlalu
banyak server yang di tangani, terlalu banyak password yang di gunakan,
terlalu rumit dan bukan merupakan password yang biasa kita ingat.
Dalam kasus lain saya pernah mereset password root dikarenakan
yang menginstall freebsd adalah orang lain dan saya harus melanjutkan
install sesuatu di dalam nya , sedangkan sang penginstall tidak bisa dihubungi
atau ditanyai password nya, atau untuk mempersingkat waktu dari pada tanya sana sini password nya apa.

mari kita coba praktekan bagaimana cara me reset password root di freebsd .

pertama tama yang dilakukan adalah merestart komputer anda

ketika proses booting di mulai maka tampilan nya adalah sebagai berikut :

Hit [Enter] to boot immediately, or any other key for command prompt.
Booting [kernel] in 10 seconds…

lalu Tekan tombol spacebar, dan akan tampil pada monitor

Type ‘?’ for a list of commands, or ‘help’ for more detailed help.
ok

boot -s dan tekan tombol ENTER untuk masuk ke dalam single user mode.

Setelah system booting akan terlihat seperti ini di monitor anda :

Enter full pathname of shell or RETURN for /bin/sh

Tekan tomnbol ENTER dan kita akan masuk ke # shell

bisa masuk tanpa password bukan ?

tapi perlu di ingat anda belum bisa melakukan apa apa pada # shell ini

karena file system yang di mount adalah read only .

gimana supaya kita bisa mengakses file system seperti biasa dan bisa merubah password ?

caranya adalah mount filesystem secara keseluruhan, yang perlu di lakukan adalah

# mount -t ufs -a

nah setelah itu barulah kita bisa me reset password root tesebut.

#passwd

New password:selamat
Retype new password:selamat

passwd: updating the database…
passwd: done

setelah itu jangan lupa restart untuk masuk ke dalam mode multiuser seperti biasa

# reboot

nah sekarang coba password baru anda

freebsd login : root

password : selamat

#

selamat anda gak perlu install ulang gara gara lupa password root

Comments Off on Lupa Pasword Root freebsd

Jun 25 2009

Merubah tanggal Di Freebsd

Published by under FreeBsd

jalankan perintah ntpdate :
Sekarang set ke tanggal yang benar dengan ntp client:

# ntpdate -v -b in.pool.ntp.org

Anda dapat memverifikasi kebenaran tanggal tsb:

# date

Atau dengan cara lain…

# date 0703271823

date dirubah jadi tanggal 27 bulan 3 tahun 2007 jam 18 lebih 23 menit

Comments Off on Merubah tanggal Di Freebsd

Jun 11 2009

Membuat Mrtg dengan perantara snmp Mikrotik

Published by under FreeBsd

Sebelum berinjak ke Caranya lebih baik saya jelaskan terlebih dahulu yang sudah harus terinstall di Mikrotik,
salah satu syarat utamanya ya di mikrotiknya harus udah ada bw limiternya sehingga ada oid trafik yang nanti nya dapat dibaja di MRTGnya. oke langsung aja….

Langkah langkahnya
1. pastikan snmp di mikrotik jalan ,….oke bosssssss
ya untuk liat dah jalan pa belum langsung aja masuk ke menu snmp…liat apakan udah di enable belum dan inget2 namanya snmp yang iku nanti buat login masuk mrtgnya….
2. pastikan di freebsd udah terinstall mrtgnya
#/usr/ports/net-mgmt/mrtg/
3. setelah itu jalankan mrtgnya dengan oid yang ada di winbox…
cara mengambil oid di winbox,…….
ketik menu newterminal ketikkan

#/queue simple print
ni untuk melihat bw limiternya urutan berapa,…
ketik

#/queue simple print oid
untuk melihat oidnya

Setelah kita dapet oid nya baru kita pastekan di setingan mrtg.cfg nya pada tulisan
#ee /usr/local/etc/mrtg/mrtg.cfg
##################################
System: EkonomiRouterOS
# Description:
# Contact: support@fekonomi.com
# Location: solo.id
##################################
### Interface 1 >> Descr: ‘ether1’ | Name: ‘ether1’ | Ip: ” | Eth: ” ###

Target[STEREAM_DOWN]: .1.3.6.1.4.1.14988.1.1.2.1.1.8.7&.1.3.6.1.4.1.14988.1.1.2.1.1.9.7
:ekonomi@10.100.100.1:
SetEnv[STEREAM_DOWN]: MRTG_INT_IP=”” MRTG_INT_DESCR=”ether1″
MaxBytes[STEREAM_DOWN]: 256000
Title[STEREAM_DOWN]: Traffic Analysis for Hotspot
PageTop[STEREAM_DOWN]: <h1>.:: Traffic Analysis for Hotspot ::.</h1>

yang warna merah merupakan oidnya dari mikrotik dari down dipisah & terus up nya sedangakn yang warna biru merupakan login snmp dari mikrotik

kemudian tulis di ee /etc/crontab
*/5 * * * * root /usr/local/bin/mrtg /usr/local/etc/mrtg/mrtg.cfg > /dev/null 2>&1

Yang warna pink letak dari mrtg.cfgnya sehingga akan diproses secara otomatis oleh mrtgnya

buat indek dulu seperti di mrtg sebelumnya
/usr/local/bin/indexmaker /usr/local/etc/mrtg/mrtg.cfg > /usr/local/apache/htdocs/web/mrtg/index.html

mungkin sedikit membingungkan ya….wong aku aja yang nulis bingung je…..heheheeeee tapi sedikit tak jelaske….jadi sebelum freebsd yang sudah terinstall mrtg, harus juga sudah terinstall webserver dimana nanti digunakan untuk membuka mrtgnya.

Kemudian script yang tak pake untuk membuat index seperti yang berwarna ijo di atas diletakkan pada folder sesuai dari letak Document Root pada webserver apachenya.

Mungkin itu dulu penjelasanku semoga mudeng dan membuat mudeng…heheheeee seee…u

Comments Off on Membuat Mrtg dengan perantara snmp Mikrotik

Jun 11 2009

Install Mrtg Di FREEBSD

Published by under FreeBsd

Langkah – langkah mambuat mrtg ayuuuuuuk
– pertama menginstal snmp dulu caranya bagaimana,…
instal using ports
#cd /usr/ports/net-mgmt/net-snmp
#make install clean
tambahkan di /etc/rc.conf
snmpd_enable=”YES”
terus edit snmpd.conf di
#ee /usr/local/share/snmp/snmpd.conf
tambahkan configurasi
####################################
#
# snmpd.conf
#
# – created by the snmpconf configuration program
#
####################################
# SECTION: System Information Setup
#
# This section defines some of the information reported in
# the “system” mib group in the mibII tree.

# syslocation: The [typically physical] location of the system.
# Note that setting this value here means that when trying to
# perform an snmp SET operation to the sysLocation.0 variable will make
# the agent return the “notWritable” error code. IE, including
# this token in the snmpd.conf file will disable write access to
# the variable.
# arguments: location_string

syslocation “Jakarta, Indonesia” —> suka suka

# syscontact: The contact information for the administrator
# Note that setting this value here means that when trying to
# perform an snmp SET operation to the sysContact.0 variable will make
# the agent return the “notWritable” error code. IE, including
# this token in the snmpd.conf file will disable write access to
# the variable.
# arguments: contact_string

syscontact oktobrima@yahoo.com —> suka suka

# sysservices: The proper value for the sysServices object.
# arguments: sysservices_number

sysservices 79

#####################################
# SECTION: Access Control Setup
#
# This section defines who is allowed to talk to your running
# snmp agent.

# rwuser: a SNMPv3 read-write user
# arguments: user [noauth|auth|priv] [restriction_oid]

rwuser proxy –> sesuai jalannya snmpd

# rouser: a SNMPv3 read-only user
# arguments: user [noauth|auth|priv] [restriction_oid]

rouser proxy –> sesuai jalannya snmpd

# rocommunity: a SNMPv1/SNMPv2c read-only access community name
# arguments: community [default|hostname|network/bits] [oid]

rocommunity proxy –> sesuai jalannya snmpd

# rwcommunity: a SNMPv1/SNMPv2c read-write access community name
# arguments: community [default|hostname|network/bits] [oid]

rwcommunity proxy –> sesuai jalannya snmpd

jalankan snmp
#/usr/local/etc/rc.d/snmpd start

setalh itu install mrtg lewat port
#cd /usr/ports/net-mgmt/mrtg/
#make install clean
setelah itu configurasi apache/conf/htdocs.conf tambah configurasi seperti ini
——————————————————————————

#
# This may also be “None”, “All”, or any combination of “Indexes”,
# “Includes”, “FollowSymLinks”, “ExecCGI”, or “MultiViews”.
#
# Note that “MultiViews” must be named *explicitly* — “Options All”
# doesn’t give it to you.
#
Options Indexes FollowSymLinks MultiViews

#
# This controls which options the .htaccess files in directories can
# override. Can also be “All”, or any combination of “Options”, “FileInfo”,
# “AuthConfig”, and “Limit”
#
AllowOverride All

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all

—————————————————————————-dari sini

#
# This may also be “None”, “All”, or any combination of “Indexes”,
# “Includes”, “FollowSymLinks”, “ExecCGI”, or “MultiViews”.
#
# Note that “MultiViews” must be named *explicitly* — “Options All”
# doesn’t give it to you.
#
Options Indexes FollowSymLinks MultiViews +ExecCGI

#
# This controls which options the .htaccess files in directories can
# override. Can also be “All”, or any combination of “Options”, “FileInfo”,
# “AuthConfig”, and “Limit”
#
AllowOverride Options AuthConfig

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all

—————————————————————————-sampek sini
setelah itu save dan restar apachenya
#/usr/local/apache/bin/apachetl restart
setelah itu jalankan script ini
#/usr/local/bin/cfgmaker –global ‘WorkDir: /usr/local/apache/htdocs/web/mrtg’ –global ‘Options[_]: bits,growright’ –output /usr/local/etc/mrtg/mrtg.cfg localhost@localhost

inget untuk cfgmaker disesuaikan dengan letaknya untuk workdir disesuaikan dengan letak index.html dan mrtg.conf jga disesuaikan dengan letaknya.untuk localhost@localhost..ii disesuaokan dengan konfigurasi di snmpd.conf untuk community dan rwuser..oke bosss…dicerna dulu ae…oke

langkah selanjutnya membuat file index.html
#/usr/local/bin/indexmaker –output /usr/local/apache/htdocs/web/mrtg/index.html /usr/local/etc/mrtg/mrtg.cfg

diperhatikan untuk letak indexmaker dan index.html serta mrtg.cfg, harus sama ketika kita menjalankan cfgmaker oke bosss
setalah itu sebelm menjalankan mrtg jalankan crontab duluw
#crontab -e
tambahkan scritp seperti dibawah ini
#*/5 * * * * /usr/local/bin/mrtg /usr/local/etc/mrtg/mrtg.cfg

jalankan mrtg
#/usr/local/bin/mrtg /usr/local/etc/mrtg/mrtg.cfg
#/usr/local/bin/mrtg /usr/local/etc/mrtg/mrtg.cfg
#/usr/local/bin/mrtg /usr/local/etc/mrtg/mrtg.cfg

mrtg udah jadi tingal jalankan di webbrowser sesuai ip servernya weks
bagussssss
Klo ada masalah,….email aq ya…ato posting aja messege heheheeeee

Comments Off on Install Mrtg Di FREEBSD

« Prev - Next »