cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
965
Views
4
Helpful
7
Replies

Help configuring Router as a DHCP server

Jangelides
Level 1
Level 1

Guys I am well and truly stuck. I have a Virgin vable modem with static IP addresses and a cisco Router and a Cisco switch. I have setup the router to provide IP addresses to various VLANs on the switch which works fine but it will not allow me access to the internet via the superhub.

2 Accepted Solutions

Accepted Solutions

Hi,

Enable NAT on each subinterfaces:

 

int f0/0

no ip address

int f0/0.5

ip address 192.168.0.1 255.255.255.0

ip nat inside

no access-list 1

access-list 1 permit 192.168.0.0 0.0.255.255

View solution in original post

Forgot to add:

int f0/0.5

encapsulation dot1q 5

 

CSC app won't let me edit nicely. It's i. HTML format.

View solution in original post

7 Replies 7

johnlloyd_13
Level 9
Level 9
Hi, Do you have NAT configured on the router? Kindly post 'show run'

Current configuration : 8897 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname SunrayR
!
boot-start-marker
boot-end-marker
!
enable secret 5 $1$Yf.I$lVkEX0tKPPW4bUrP7OE8h1
!
no aaa new-model
!
resource policy
!
mmi polling-interval 60
no mmi auto-configure
no mmi pvc
mmi snmp-timeout 180
ip cef
!
!
no ip dhcp use vrf connected
ip dhcp excluded-address 192.168.20.1
ip dhcp excluded-address 192.168.30.1
ip dhcp excluded-address 192.168.40.1
ip dhcp excluded-address 192.168.50.1
ip dhcp excluded-address 192.168.60.1
ip dhcp excluded-address 192.168.70.1
ip dhcp excluded-address 192.168.80.1
ip dhcp excluded-address 192.168.90.1
ip dhcp excluded-address 192.168.100.1
ip dhcp excluded-address 192.168.110.1
ip dhcp excluded-address 192.168.120.1
ip dhcp excluded-address 192.168.130.1
ip dhcp excluded-address 192.168.140.1
ip dhcp excluded-address 192.168.150.1
ip dhcp excluded-address 192.168.160.1
ip dhcp excluded-address 192.168.170.1
ip dhcp excluded-address 192.168.180.1
ip dhcp excluded-address 192.168.190.1
ip dhcp excluded-address 192.168.200.1
ip dhcp excluded-address 192.168.210.1
ip dhcp excluded-address 192.168.220.1
ip dhcp excluded-address 192.168.230.1
ip dhcp excluded-address 192.168.240.1
ip dhcp excluded-address 192.168.10.1
ip dhcp excluded-address 192.168.1.1
!
ip dhcp pool LAN10
   network 192.168.10.0 255.255.255.0
   default-router 192.168.10.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN20
   network 192.168.20.0 255.255.255.0
   default-router 192.168.20.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN30
   network 192.168.30.0 255.255.255.0
   default-router 192.168.30.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN40
   network 192.168.40.0 255.255.255.0
   default-router 192.168.40.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN50
   network 192.168.50.0 255.255.255.0
   default-router 192.168.50.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN60
   network 192.168.60.0 255.255.255.0
   default-router 192.168.60.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN70
   network 192.168.70.0 255.255.255.0
   default-router 192.168.70.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN80
   network 192.168.80.0 255.255.255.0
   default-router 192.168.80.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN90
   network 192.168.90.0 255.255.255.0
   default-router 192.168.90.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN100
   network 192.168.100.0 255.255.255.0
   default-router 192.168.100.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN110
   network 192.168.110.0 255.255.255.0
   default-router 192.168.110.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN120
   network 192.168.120.0 255.255.255.0
   default-router 192.168.120.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN130
   network 192.168.130.0 255.255.255.0
   default-router 192.168.130.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN140
   network 192.168.140.0 255.255.255.0
   default-router 192.168.140.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN150
   network 192.168.150.0 255.255.255.0
   default-router 192.168.150.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN160
   network 192.168.160.0 255.255.255.0
   default-router 192.168.160.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN170
   network 192.168.170.0 255.255.255.0
   default-router 192.168.170.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN180
   network 192.168.180.0 255.255.255.0
   default-router 192.168.180.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN190
   network 192.168.190.0 255.255.255.0
   default-router 192.168.190.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN200
   network 192.168.200.0 255.255.255.0
   default-router 192.168.200.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN210
   network 192.168.210.0 255.255.255.0
   default-router 192.168.210.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN220
   network 192.168.220.0 255.255.255.0
   default-router 192.168.220.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN230
   network 192.168.230.0 255.255.255.0
   default-router 192.168.230.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN240
   network 192.168.240.0 255.255.255.0
   default-router 192.168.240.1
   dns-server 194.168.4.123 194.168.8.123
!
ip dhcp pool LAN1
   network 192.168.1.0 255.255.255.0
   default-router 192.168.1.1
   dns-server 194.168.4.123 194.168.8.123
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
username secret password 0 secret
!
!
!
!
!
!
interface FastEthernet0/0
 description 'Connected To The Internal LAN'
 ip address 192.168.0.1 255.255.255.0
 ip nat inside
 ip virtual-reassembly
 speed 100
 full-duplex
!
interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 192.168.1.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.10
 encapsulation dot1Q 10
 ip address 192.168.10.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.20
 encapsulation dot1Q 20
 ip address 192.168.20.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.30
 encapsulation dot1Q 30
 ip address 192.168.30.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.40
 encapsulation dot1Q 40
 ip address 192.168.40.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.50
 encapsulation dot1Q 50
 ip address 192.168.50.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.60
 encapsulation dot1Q 60
 ip address 192.168.60.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.70
 encapsulation dot1Q 70
 ip address 192.168.70.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.80
 encapsulation dot1Q 80
 ip address 192.168.80.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.90
 encapsulation dot1Q 90
 ip address 192.168.90.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.100
 encapsulation dot1Q 100
 ip address 192.168.100.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.110
 encapsulation dot1Q 110
 ip address 192.168.110.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.120
 encapsulation dot1Q 120
 ip address 192.168.120.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.130
 encapsulation dot1Q 130
 ip address 192.168.130.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.140
 encapsulation dot1Q 140
 ip address 192.168.140.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.150
 encapsulation dot1Q 150
 ip address 192.168.150.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.160
 encapsulation dot1Q 160
 ip address 192.168.160.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.170
 encapsulation dot1Q 170
 ip address 192.168.170.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.180
 encapsulation dot1Q 180
 ip address 192.168.180.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.190
 encapsulation dot1Q 190
 ip address 192.168.190.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.200
 encapsulation dot1Q 200
 ip address 192.168.200.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.210
 encapsulation dot1Q 210
 ip address 192.168.210.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.220
 encapsulation dot1Q 220
 ip address 192.168.220.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.230
 encapsulation dot1Q 230
 ip address 192.168.230.1 255.255.255.0
 no snmp trap link-status
!
interface FastEthernet0/0.240
 encapsulation dot1Q 240
 ip address 192.168.240.1 255.255.255.0
 no snmp trap link-status
!
interface Serial0/0
 no ip address
 shutdown
!
interface Ethernet1/0
 description 'Connected to the ISP'
 ip address 82.53.119.11 255.255.255.248
 ip nat outside
 ip virtual-reassembly
 full-duplex
!
ip route 0.0.0.0 0.0.0.0 82.53.119.9
!
!
no ip http server
no ip http secure-server
ip nat pool sunraypool 82.53.119.9 82.53.119.9 netmask 255.255.255.248
ip nat inside source list 1 pool sunraypool overload
!
access-list 1 permit 192.168.1.0 0.0.0.255
access-list 1 permit 192.168.10.0 0.0.0.255
access-list 1 permit 192.168.0.0 0.0.255.255
no cdp log mismatch duplex
!
!
control-plane
!
!
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 login local
line aux 0
line vty 0 4
 exec-timeout 0 0
 logging synchronous
 login local
 transport input ssh
line vty 5 15
 exec-timeout 0 0
 logging synchronous
 login local
 transport input ssh
!
end

Hi,

Enable NAT on each subinterfaces:

 

int f0/0

no ip address

int f0/0.5

ip address 192.168.0.1 255.255.255.0

ip nat inside

no access-list 1

access-list 1 permit 192.168.0.0 0.0.255.255

Forgot to add:

int f0/0.5

encapsulation dot1q 5

 

CSC app won't let me edit nicely. It's i. HTML format.

Thank you Johnlloyd. I'll give that a try tomorrow and let you know how I get on. Very much appreciated.

Hi Johnlloyd,

 

why would i remove the ip address for the physical f0/0 port, it would need an ip address to connect to the switch would it not. Also is the above 'int f0/0.5' there as an example or are you telling me to configure that subinterface??

nevermind Johnlloyd, you are a friggin genius and I am very grateful for your help.  You have made my weekend.

Review Cisco Networking products for a $25 gift card