Let me assume that the interface of the router connected to the Cisco 3750 switch is FastEthernet 0/0, and the interface connected to internet is FastEthernet 0/1
The following router configuration would suffice for connectivity to the internet and inter-vlan communications :
! interface FastEthernet0/0 ip address 192.168.1.100 255.255.255.0 ip nat inside ! interface FastEthernet0/0.2 encapsulation dot1Q 2 ip address 192.168.2.100 255.255.255.0 ip nat inside ! interface FastEthernet0/0.3 encapsulation dot1Q 3 ip address 192.168.3.100 255.255.255.0 ip nat inside ! interface FastEthernet0/0.4 encapsulation dot1Q 4 ip address 192.168.4.100 255.255.255.0 ip nat inside ! interface FastEthernet0/1 ip address 170.150.160.100 255.255.0.0 ip nat outside ! ! ip nat inside source list 10 interface FastEthernet0/1 overload ip classless ! ! access-list 10 permit 192.168.0.0 0.0.255.255 ! !
The DHCP on the switch must be as given bellow (its made to match the above router configuration) :
! ip dhcp pool p1 network 192.168.1.0 255.255.255.0 default-router 192.168.1.100 ip dhcp pool p2 network 192.168.2.0 255.255.255.0 default-router 192.168.2.100 ip dhcp pool p3 network 192.168.3.0 255.255.255.0 default-router 192.168.3.100 ip dhcp pool p4 network 192.168.4.0 255.255.255.0 default-router 192.168.4.100 ! ! interface Vlan1 ip address 192.168.1.1 255.255.255.0 ! interface Vlan2 ip address 192.168.2.1 255.255.255.0 ! interface Vlan3 ip address 192.168.3.1 255.255.255.0 ! interface Vlan4 ip address 192.168.4.1 255.255.255.0 ! !
NOTE : I have removed commands irrelevant to our context.
You can copy-paste the above configuration at the Global Configuration Mode of the respective devices if you wish