Kamis, 19 Januari 2023

CCNA


 SUBNETTING

Jawab :
172.16.3.0/23

IP Base :
23-24 = 1 = 2^1 = 2
(0-1)(2-3)
172.16.2.0/23

Vlan 10
63 Host
IP Network = 172.16.3.0/25
Range IP yang dapat digunkan = 172.16.3.1 - 172.16.3.126
Broadcast 172.16.3.127
Subnet mask = 255.255.255.128

Vlan 20
127 Host
IP Network = 172.16.2.0/24
Range IP yang dapat digunakan = 172.16.2.1 - 172.16.2.254
Broadcast = 172.16.2.255
Subnet mask = 255.255.255.0

Vlan 30
31 Host
IP Network = 172.16.3.128/26
Range IP yang dapat digunakan = 172.16.3.129 - 172.16.3.190
Broadcast 172.16.3.191
Subnet mask = 255.255.255.192

Bit        Bit        CIDR    Subnet    Net Mask            Host    Host Per
Masked    Host ID                                        Max        Network
0        8        /24        1        255.255.255.0        254        254
1        7        /25        2        255.255.255.128        252        126
2        6        /26        4        255.255.255.192        248        62
3        5        /27        8        255.255.255.224        240        30
4        4        /28        16        255.255.255.240        224        14
5        3        /29        32        255.255.255.248        192        6
6        2        /30        64        255.255.255.252        128        2



#SW-0
en
conf t
enable secret cisco
exit
vlan database
vlan 10
vlan 20
vlan 30
ex
conf t
int f0/1
sw mo trunk
sw trunk allowed vlan all
ex
int f0/2
sw mo access
sw access vlan 10
ex
int f0/3
sw mo access
sw access vlan 20
ex
int f0/4
sw mo access
sw access vlan 30
ex

#Router0
en
conf t
enable secret cisco
line vty 0 4
password cisca
login
exit
int g0/0
no sh
exit
int g0/1
ip add 202.100.2.1 255.255.255.0
no sh
exit
int g0/0.10
encapsulation dot1Q 10
ip add 172.16.3.1 255.255.255.128
exit
int g0/0.20
encapsulation dot1Q 20
ip add 172.16.2.1 255.255.255.0
exit
int g0/0.30
encapsulation dot1Q 30
ip add 172.16.3.129 255.255.255.192
exit
ip dhcp excluded-address 172.16.3.129
ip dhcp pool vlan30
network 172.16.3.135 255.255.255.192
default-router 172.16.3.129
exit
access-list 20 deny 172.16.2.0 0.0.0.255
access-list 20 permit any
line vty 0 4
login
access-class 20 in
exit
ip route 0.0.0.0 0.0.0.0 202.100.2.2
ip nat inside source list 100 interface g0/1 overload
access-list 100 permit ip any any
int g0/1
ip nat outside
exit
int g0/0.10
ip nat inside
exit
int g0/0.20
ip nat inside
exit
int g0/0.30
ip nat inside
exit

#Router1
en
conf t
enable secret cisco
int g0/0
ip add 202.100.2.2 255.255.255.0
no sh
exit
int g0/1
ip add 202.100.1.1 255.255.255.0
no sh
exit
router rip
network 202.100.2.0
network 202.100.1.0
network 202.100.0.0
network 172.16.2.0
network 172.16.3.0
exit

#Router2
en
conf t
enable secret cisco
int g0/0
ip add 202.100.1.2 255.255.255.0
no sh
exit
int g0/1
ip add 202.100.0.1 255.255.255.0
no sh
exit
router rip
network 202.100.0.0
network 202.100.1.0
network 202.100.2.0
network 172.16.2.0
network 172.16.3.0
exit

#Vlan 10
CMD
telnet 172.16.3.1
cisca
en
cisco

#Vlan 20
CMD
telnet 172.16.2.1

#Vlan 30
CMD
telnet 172.16.3.129
cisca
en
cisco

0 komentar:

Posting Komentar