Showing posts with label Router. Show all posts
Showing posts with label Router. Show all posts

Saturday, 8 March 2014

Router-on-a-stick is a term frequently used to describe a setup up that consists of a router and switch connected using one Ethernet link configured as an 802.1q trunk link. In this setup, the switch is configured with multiple VLANs and the router performs all routing between the different networks/VLANs. It's a very popular term and commonly used in networks where no layer-3 switch exists.


Inter-vlan using router on a stick method.

Solution: The given topology is:



Steps:
Configuring steps for PC1:
VLAN 2: Sales
Ip address: 192.168.10.2
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.10

Configuring steps for PC2:
VLAN 2: Sales
Ip address: 192.168.10.3
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.10

Configuring steps for PC0:
VLAN 2: Sales
Ip address: 192.168.10.4
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.10

Configuring steps for PC3:
VLAN 3: Accounts
Ip address: 192.168.10.33
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.40

Configuring steps for PC4:
VLAN 3: Accounts
Ip address: 192.168.10.34
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.40

Configuring steps for PC5:
VLAN 3: Accounts
Ip address: 192.168.10.35
Subnet mask: 255.255.255.224
Default gateway: 192.168.10.40

Configuring steps for switch0:
Switch>enable
Switch#config terminal
Switch(config)#vlan 2
Switch(config-vlan)#name sales
Switch(config-vlan)#interface range fa0/2 – fa0/4
Switch(config-if-range)# switchport mode access
Switch(config-if-range)#switchport access vlan 2
Switch(config-if-range)#exit
Switch(config)# vlan 3
Switch(config-vlan)# name account
Switch(config-vlan)# interface range fa0/5-fa0/7
Switch(config-if-range)# switchport mode access
Switch(config-if-range)# switchport access vlan 3
Switch(config-if-range)# exit
Switch(config)#interface fa0/1
Switch(config-if)# switchport mode trunk
Switch(config-if)# exit
Switch(config)#

Configuring steps for router:

Router0>enable
Router0#config terminal
Router0(config)#interface fa0/0
Router0(config-if)# interface fa0/0.1
Router0(config-subif)# encapsulation dot1Q 2
Router0(config-subif)# ip address 192.168.10.10 255.255.255.224
Router0(config-subif)# exit
Router0(config)# interface fa0/0
Router0(config-if)# interface fa0/0.2
Router0(config-subif)# encapsulation dot1Q 3
Router0(config-subif)# ip address 192.168.10.40 255.255.255.224
Router0(config-subif)# exit
Router0(config)#

Output:
Ping command from PC1 to PC5:

                       

Thursday, 6 March 2014

On 06:38 by Unknown in , , , ,    No comments
Hello there, Welcome to our blog. How you all are, Hope you all doing great. On our blog you will find support for tech, hacking and social tweaks. We provide networking solutions for any type of problem. You can contact us through this blog. We will do whatever we can do for your problem. 


Have you ever wanted to port-forward? Wanted to change router settings? And you do not know username or password? Many people cannot access their router through a web browser, because they either forgot a password/username or do not have a router manual at all. Well, there is a little trick I discovered about a month ago, this is how you can access your router with full Super User rights.

Accessing router if you forgot password and username. 


Simply follow the steps.


  1. 1
    Go to START on bottom left corner of the screen.
    1. 2
      Search for Run.
    2. 3
      Type "cmd" in Run (without quotes) and hit Enter.
    3. 4
      When a Command Prompt opens up, type in "ipconfig" (without quotes) and hit enter.
    4. 5
      Locate your Default Gateway under Ethernet Adapter (Local Area Connection), mark and copy that address.
    5. 6
      Go to your web browser and paste the previously copied address in the URL search bar, hit Enter.
    6. 7
      It will asks you for Username and Password.
    7. 8
      Go to your modem (physical object).
    8. 9
      Below, on bottom of the modem try to locate "Modem Access Code", memorise or write down the code.
    9. 10
      Go back to your PC and web browser on the tab you were previously on trying to access your router.
    10. 11
      Write or paste your Modem Access Code you previously wrote down or memorised in the Password section.
    11. 12
      For Username try these inputs: "user", "admin" "000", "administrator" or blank or any other default Username you could think of (without quotes).
    12. 13
      Congratulations! You now should have a full access to your Router/Modem.

Friday, 28 February 2014


Hello there, Welcome to our blog. How you all are, Hope you all doing great. On our blog you will find support for tech, hacking and social tweaks. We provide networking solutions for any type of problem. You can contact us through this blog. We will do whatever we can do for your problem. 

First of all we will have a look at how dhcp work basically, what sort of messages or queries it include.


How DHCP work. 

Schema of a typical DHCP session
  • DHCP uses the same two IANA assigned ports as BOOTP: 67/udp for the server side, and 68/udp for the client side.
  • DHCP operations fall into four basic phases. These phases are IP lease request, IP lease offer, IP lease selection, and IP lease acknowledgement.
  • After the client obtained an IP address, the client may start an address resolution query to prevent IP conflicts caused by address poll overlapping of DHCP servers.
DHCP discovery
  • The client broadcasts on the local physical subnet to find available servers. Network administrators can configure a local router to forward DHCP packets to a DHCP server on a different subnet. This client-implementation creates a UDP packet with the broadcast destination of 255.255.255.255 or subnet broadcast address.
  • A client can also request its last-known IP address (in the example below, 192.168.1.100). If the client is still in a network where this IP is valid, the server might grant the request. Otherwise, it depends whether the server is set up as authoritative or not. An authoritative server will deny the request, making the client ask for a new IP immediately. A non-authoritative server simply ignores the request, leading to an implementation dependent time out for the client to give up on the request and ask for a new IP.

DHCP offers

  • When a DHCP server receives an IP lease request from a client, it extends an IP lease offer. This is done by reserving an IP address for the client and sending a DHCP OFFER message across the network to the client. This message contains the client's MAC address, followed by the IP address that the server is offering, the subnet mask, the lease duration, and the IP address of the DHCP server making the offer.
  • The server determines the configuration, based on the client's hardware address as specified in the CHADDR field. Here the server, 192.168.1.1, specifies the IP address in the YIADDR field.
DHCP requests

  • When the client PC receives an IP lease offer, it must tell all the other DHCP servers that it has accepted an offer. To do this, the client broadcasts a DHCP REQUEST message containing the IP address of the server that made the offer. When the other DHCP servers receive this message, they withdraw any offers that they might have made to the client. 
  • They then return the address that they had reserved for the client back to the pool of valid addresses that they can offer to another computer. Any number of DHCP servers can respond to an IP lease request, but the client can only accept one offer per network interface card.
DHCP acknowledgement

  • When the DHCP server receives the DHCP REQUEST message from the client, it initiates the final phase of the configuration process. This acknowledgement phase involves sending a DHCPACK packet to the client. This packet includes the lease duration and any other configuration information that the client might have requested. At this point, the TCP/IP configuration process is complete.
  • The server acknowledges the request and sends the acknowledgement to the client. The system as a whole expects the client to configure its network interface with the supplied options.
DHCP on Packet Tracer.


  • This tutorial is about how to configure dhcp on cisco router in packet tracer. The Dynamic Host Configuration Protocol (DHCP) is a network protocol that is used to configure network devices. DHCP allows a computer to join an IP-based network without having a pre-configured IP address. DHCP is a protocol that assigns unique IP addresses to devices, then releases and renews these addresses as devices leave and re-join the network. 
  • Internet Service Providers (ISPs) usually use DHCP to allow customers to join the Internet with minimum effort. The DHCP server maintains a database of available IP addresses and configuration information. When it receives a request from a client, the DHCP server determines the network to which the DHCP client is connected, and then allocates an IP address. DHCP servers typically grant IP addresses to clients only for a limited interval.
  • Lets apply DHCP on packet tracer.First, let us make a topology with one router on which we will apply DHCP and several client PCs. More like this one,




Now, we will apply DHCP on the router.
The commands in sequence are as follows.


  • In the following command “ip dhcp pool cisco”, we are creating a pool for DHCP called cisco. cisco is the name here and we can name it whatever we want.
  • Similarly, in the command “default-router “ we are telling the DHCP about the default route to follow.Notice, after we exit from DHCP mode, we are excluding some IP addresses by applying this command “ip dhcp excluded-addresses x-x”, where x is the starting and ending IP address respectively. We are basically reserving some IPs for our use. It can be used to attach printers, or assign it to some specific users for security purposes. You can also give dns address in dhcp by using the following command.
  • dns-server 192.168.1.15.
Now, open the PC.
  • Switch to ip configuration Tab.
  • Then you will see two options static and DHCP.
  • Check DHCP radio button.



Wednesday, 26 February 2014

Classful Network


let's first know little bit about classful network, what it is, how to implement it. A classful network is a network addressing architecture used in the Internet from 1981 until the introduction of Classless Inter-Domain Routing in 1993. The method divides the address space for Internet Protocol Version 4 (IPv4) into five address classes. Each class, coded in the first four bits of the address, defines either a different network size, i.e. number of hosts for unicast addresses (classes A, B, C), or a multicast network (class D). The fifth class (E) address range is reserved for future or experimental purposes.

Classful addressing, formally adopted as part of the Internet Protocol (IP) in RFC 791, was the Internet's first major addressing scheme. The IP address was 32 bits in size, just as today, but was managed considerably differently.

There were three address classes to chose from: A, B, or C, corresponding to 8-bit, 16-bit, or 24-bit prefixes. No other prefix lengths were allowed, and there was no concept of nesting a group of 24-bit prefixes, for example, within a 16-bit prefix.

ClassLeading
bits
Size of network
number
 bit field
Size of rest
bit field
Number
of networks
Addresses
per network
Start addressEnd address
Class A    0    8    24    128 (27)    16,777,216 (224)0.0.0.0127.255.255.255
Class B    10    16    16    16,384 (214)    65,536 (216)128.0.0.0191.255.255.255
Class C    110    24    8    2,097,152 (221)    256 (28)192.0.0.0223.255.255.255
Class D (multicast)    1110    not defined    not defined    not defined    not defined224.0.0.0239.255.255.255
Class E (reserved)    1111    not defined    not defined    not defined    not defined240.0.0.0255.255.255.255

Configure the routers with class full network with RIP1

Description: The Routing Information Protocol (RIP) is a distance-vector protocol that uses hop count as it’s metric. RIP is widely used for routing traffic in the global Internet and is an interior gateway protocol, which means that it performs routing within a single autonomous system. Using RIP, a gateway host (with a router) sends its entire routing table to its closest neighbour host every 30 seconds. The neighbour host in turn will pass the information on to its next neighbour and so on until all hosts within the network have the same knowledge of routing paths, a state known as network convergence. RIP uses a hop count as a way to determine network distance.

Solution: The given topology is:


Steps:
Configuring steps for router0:

Router>enable
Router#config t
Router(config)#interface fa0/0
Router(config-if)#ip address 10.0.0.1 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#interface se2/0
Router(config-if)#ip address 20.0.0.1 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#router rip
Router(config-router)#network 10.0.0.0
Router(config-router)#network 20.0.0.0
Router(config-router)#exit

Configuring steps for router1:

Router>enable
Router#config t
Router(config)#interface fa0/0
Router(config-if)#ip address 30.0.0.1 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#interface se2/0
Router(config-if)#ip address 20.0.0.2 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#router rip
Router(config-router)#network 20.0.0.0
Router(config-router)#network 30.0.0.0
Router(config-router)#exit

Configuring steps for router2:

Router>enable
Router#config t
Router(config)#interface fa0/0
Router(config-if)#ip address 50.0.0.1 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#interface se2/0
Router(config-if)#ip address 40.0.0.2 255.0.0.0
Router(config-if)#no shutdown
Router(config-if)#exit
Router(config)#router rip
Router(config-router)#network 40.0.0.0
Router(config-router)#network 50.0.0.0
Router(config-router)#exit

Output:
Ping command from PC5 to PC1


Basic router configuration

following commands are used in basic router configuration. Have a look at them and grasp them quickly.

Following are the basic commands:
1.        Naming the router
Use: Specifies the name for the router.
Steps:
Router>enable
Router# configure terminal
Router# hostname bca
bca>

Output:


2.        Setting passwords
·         Secret password
Use: Specifies an encrypted password to prevent unauthorized access to the router.
Steps:
bca(config)# enable secret chitkara
Output:

·         Setting console terminal password
Use: Enters line configuration mode, and specifies the console type of line then give unique password for line and enable password checking at terminal session login.
Steps:
bca(config)# line console 0
bca(config-line)# password abc
bca(config-line)# login
bca(config-line)# exit
bca(config)#
Output:

·         Setting virtual terminal password
Use: Specifies a virtual terminal for remote console access.
Steps:
bca(config)# line vty 0 4
bca(config-line)# password def
bca(config-line)# login
bca(config-line)# exit
bca(config)#
Output:

3.        Configuring interfaces
·         Fast Ethernet interface
Use: Enters interface mode and then give ip address, subnet mask.
Steps:
bca(config)# interface fa0/0
bca(config-if)# ip address 192.168.10.1 255.255.0.0
bca(config-if)# no shutdown
bca(config-if)# exit
Output:

·         Serial interface
Use: Enters serial interface mode and then give ip address, subnet mask and clock rate. Clock rate will be given only if the serial port is DCE.
Steps:
bca(config)# interface se0/0
bca(config-if)#ip address 192.168.30.1 255.255.0.0
bca(config-if)#no shutdown
bca(config-if)# clockrate 6400
bca(config-if)#exit
Output:

4.        Message of the banner
Use: Message will be shown when we enter the command line interface of the router.
Steps:
bca(config)# banner motd %message....%
bca(config)#
Output:

Output:
Ping command from PC1 to router