Professional Documents
Culture Documents
Tutorial DNS-web Server-Mail Server
Tutorial DNS-web Server-Mail Server
Opsi konfigurasi :
1. IP Address
a. smk.sch.id = 200.100.4.65/27
b. www.smk.sch.id = 200.100.4.66/27
c. mail.smk.sch.id = 200.100.4.67/27
2. DNS Server
a. Sistem Operasi = OS Linux
b. Domain = smk.sch.id
c. Email Admin = nama_peserta@smk.sch.id
d. Sub Domain = www.smk.sch.id
mail.smk.sch.id
1
Untuk Kalangan Sendiri
Membangun DNS SERVER dan MAIL SERVER
IP ADDRESS
# /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces (5).
auto eth0:0
iface eth0:0 inet static
address 200.100.4.66
netmask 255.255.255.224
network 200.100.4.64
broadcast 200.100.4.95
gateway 200.100.4.65
auto eth0:1
iface eth0:1 inet static
address 200.100.4.67
netmask 255.255.255.224
network 200.100.4.64
broadcast 200.100.4.95
gateway 200.100.4.65
2
Untuk Kalangan Sendiri
Membangun DNS SERVER dan MAIL SERVER
DNS SERVER
ukk : /# apt-get install bind9
reading package list … Done
Building dependency tree
Do you want to continue [Y/N] Y
# /etc/bind/named.conf.local
zone “smk.sch.id” {
type master;
file “/etc/bind/db.forward”;
};
Zone “4.100.200.in-addr.arpa” {
Type master;
File “/etc/bind/db.reverse”;
};
# /var/chace/bind/db.forward
;
; BIND data file for local loopback interface
;
$TTL 604800
@ IN SOA smk.sch.id. suli.smk.sch.id. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative cache TTL
;
@ IN NS smk.sch.id.
IN A 200.100.4.65
www IN A 200.100.4.66
mail IN A 200.100.4.67
# /var/chace/bind/db.reverse
;
; BIND reverse file for local loopback interface
;
$TTL 604800
@ IN SOA smk.sch.id. suli.smk.sch.id. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative cache TTL
;
@ IN NS smk.sch.id.
65 IN PTR smk.sch.id.
66 IN PTR www.smk.sch.id.
67 IN PTR mail.smk.sch.id.
CEK DNS
ukk: /# nslookup
> 200.100.4.65
server : 200.100.4.65
addres : 200.100.4.65#53
65.4.100.200.in-addr.arpa name = smk.sch.id.
> smk.sch.id
server : 200.100.4.65
address: 200.100.4.65#53
name = smk.sch.id
addres: 200.100.4.65
> 200 .100.4.66
server : 200.100.4.65
address: 200.100.4.65#53
66.4.100.200.in-addr.arpa name = www.smk.sch.id.
3
Untuk Kalangan Sendiri
Membangun DNS SERVER dan MAIL SERVER
> www.smk.sch.id
server : 200.100.4.65
address: 200.100.4.65#53
name = www.smk.sch.id.
Address : 200.100.4.66
> 200.100.4.67
server : 200.100.4.65
address: 200.100.4.65#53
67.4.100.200.in-addr.arpa name =mail.smk.sch.id.
> mail.smk.sch.id
server : 200.100.4.65
address: 200.100.4.65#53
name : mail.smk.sch.id.
Address : 200.100.4.66
WEB SERVER
# apt-get install apache2 php5 links
Reading package list …. Done
Building dpendency tree
Do you want to continue [Y/N] y
# /etc/apache2/site-enabled/webmail
NameVirtualHost 200.100.4.66:80
<VirtualHost *:80>
ServerName www.smk.sch.id
DocumentRoot /home/suli/public_html
</VirtualHost>
ukk: ~# mkdir /etc/skel/public_html
ukk:~# adduser suli
adduser: the user ‘suli’ already exist
ukk:~# adduser suli2
adding user ‘suli2’ ….
Adding new group ‘suli2’ (1002) ….
Adding new user ‘suli2’ (1002) with group ‘suli1’ ….
Creating home directory ‘/home/suli2’ ……
Copying file from ‘/etc/skel’ …..
Enter new UNIX password :
Retype new UNIX password :
Passwd: password update successfully
Changing the user information for suli2
Enter the new value, or press ENTER for the default
Full Name [] :
Room Number[] :
Work Phone [] :
Home phone [] :
Other [] :
Is the information correct? [Y/N] y
ukk:~# /etc/init.d/apache2 restart
ukk:~# links www.smk.sch.id
index of /
index of /
# /etc/postfix/main.cf
# see /usr/share/postfix/main.cf.dist for a commented, more complete version
4
Untuk Kalangan Sendiri
Membangun DNS SERVER dan MAIL SERVER
Redme_directory = no
# TLS parameters
smtpd_tls_cert_file =/etc/ssl/cert/ssl-cert-snakeoil.pem
smtpd_tls_key_file=/etc/ssl/private/ssl-sert-snakeoil.key
smpd_use_tls=yes
smtpd_tls_session_chace_database = btree:${data_directory}/smtpd_schace
smtp_tls_session_chace_database = btree:${data_directory}/smtp_schace
myhostname = ukk.smk.sch.id
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/alilases
myorigin = ukk.smk.sch.id
mydestination = smk.sch.id, ukk.smk.sch.id, localhost.smk.sch.id, localhost,
localhost.localdomain
relayhost =
mynetwork = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 200.100.4.64/27
# mailbox_command = procmail –a “SEXTENTION”
mailbox_size_limit = 0
recipient_dilimeter = +
inet_interfaces = all
home_mailbox = Maildir/
suli:~# /etc/squirrelmail/conf.pl
SquirrelMail Configuration : Read : config.php (1.4.0)
Main Menu - - -
1. Organizatian Preferences
2. Servers settings
Q Qiut
commad >> 2
5
Untuk Kalangan Sendiri
Membangun DNS SERVER dan MAIL SERVER
The domain name is the suffix at the end of all email addresses. If for example, your email
addrss is jdoe@example.com, then your domain would be example.com
[ trim (implode ( ‘ ‘ ,
file (‘/etc/’. (file_exists(‘/etc/mailname’) ?’mail’ : ‘host’). ‘name’)))]: smk.sch.id
Command >> r
C Turn color on
S Save data
Q Quit
Command >> d
Imap_server_type = courier
Default_folder-prefix = INBOX
Trash_folder = Trash
Sent_folder = Sent
Draft_folder = Drafts
Show_prefix_option = false
Default_sub_of_inbox = false
Show_contain-subfolders-option = false
Optional_delimeter =.
Delete_folder = true
C Turn color on
S Save data
Q Quit
command >> s
C Turn color on
S Save data
Q Quit
command >> q
# /etc/apache2/conf.d/squirrelmail.conf
7
Untuk Kalangan Sendiri