Friday, 28 June 2013

How To Delete VLAN Configuration

Often times, many students ask me how they can delete their Vlan configuration.
 

Of course! I know its a little trciky.
 

For some reasons that I don't know, Cisco decided not to keep Vlan information in the NVRAM like every other Switch/Router configuration, but I'm sure they have a very good reason.

NOTE: Vlan Database is not stored in the NVRAM.

Hence, when you erase configuration in the Switch, you find out that your previous Vlan config still remains.

Do not panic, there is no course for alarm. Its simple!

Vlan database is stored on the Flash and the name of the database file is vlan.dat

Below is the syntax to successfully delete your vlan database (you do this in the User Privilege mode):

delete flash:vlan.dat


or
delete flash
vlan.dat 
Mind you, the configuration is not totally erased until you reload the Switch.
So, reload the switch and check again.

I hope this has been helpful.
Thank you.

You can also see here: http://adaptiveit.blogspot.com/2013/06/how-to-delete-vlan-configuration.html

Thursday, 27 June 2013

Before a Router routes

Routing is actually what makes our internet what it is, without the router, no packet can travel beyond its local network(switched network). Hence, routing is an indispensable part of the internet.

After all, would it not have been silly to have this huge number of computers around us today and yet they cannot communicate? They can't gist, they can't share resources, they can't ask a friend for something. There is a Yoruba saying that says "one tree cannot make a forest", and truly the forest is what we need to survive, so also, computers need to be able to connect to other computers for them to fully display their rich capability.
 

Imagine this scenario with me;
 

I just moved into Port Harcourt City yesterday for an interview slated for this morning. I'm new and I don't know anywhere.
 

This morning, I woke up in Abuloma area and I am supposed to go to Adaptive IT located in Artillery for my interview.
 

NOTE: For the rest of this theory, know that I and my neighbor are both routers. 
So, currently I have 2 information,
 

1. My current location (Abuloma), that is my source address
2. Where I am going to (Artillery), this is my destination address
 

But i still have other information that I need before I can get to my destination - I need to know the road (path) that will get me to my destination.
 

So what i will do next is to dress up, step out and walk up to my neighbor's door. I give a knock on his door and he steps out to attend to me. We exchange pleasantries, then I ask him, "Sir, please how do I get to Artillery?"
 

He answers me, and says "Friend there are 3 paths (roads) you can take to get to Artillery."
1. You can go through Garrison      - Farther route
2. You can go through Mothercat    - Far route
3. You can go through Slaughter     - Short route
 

So now that my neighbor has provided me this information, what is left for me is to choose the best route which is Slaughter road to get to Artillery on time. (Best always wins).
 

From that simple analogy, let's draw out certain essentials and relate it to the routing world;
 

1. I had a need to move from my current location to another location - this talks about the source address and destination address.
2. I didn't know how to get there so I asked a friend - my friend and I, are both Routers.
3. I had to establish a relationship with my friend(neighbor), so we exchanged pleasantries - this talks about how routers form adjacency with neighbors in order to get routing information.
4. We also exchanged pleasantries so that we can continue to be friends - this talks about how routers must maintain relationship so as to always get updates about routes learnt from those neighbors.
 

Hence, this brings us to where we were actually going: The Router must have the following 5 information before it can route.
 

1. It must know both the source and destination addresses.
2. It must know neighbors from which it can learn routes (remote networks) from
3. It must know all possible routes to the destination
4. It must know the best route to the destination
5. it must know how to maintain and verify routing information
 

Now, the routing process can begin.
 
I believe this write up has been very helpful.
Thank you.

Wednesday, 26 June 2013

Simple IP Subnetting (with real world scenario illustration)

As commonly assumed by most students pursuing their career in any phase of IP Networking, subnetting - an integral part of efficient network design and management is a herculean task.

Based on this assumption and my fight-to-finish to help people understand and make IP subnetting to be at their beck and call, I have structured out this simple way of getting it over with.


Now, let’s delve into the topic.


To properly understand this topic we have to quickly be reminded of some basics;

A Network – simply, group of interconnected devices communicating and sharing resources on the same segment.


SUBNET – Owing to the definition above, we can simply refer to SUBNET as separate groups of interconnected devices carved out of the already existing one large group.


IP ADDRESS – An IP Address is used to identify individual devices on a network. You can picture it as NAME of a person in a Family. Hence, in a Family everyone must have a name, and the name must be unique. Likewise, in a Network every device (PC etc.) must have a unique IP address.

In order to help you understand the concept, I am going to approach the topic using my hypothetical Family story theory.

Let’s get started;


An IP Address is made of 4 octets or bytes containing 8 bits of information each. This makes the 32bits size of an average IP Address. Also, every IP address is made of TWO portions; Network & Host portions – this is determined by the Subnet mask of that IP Address.

It takes this format:
For the rest of this note, please endeavor to take note of the correlation below:
 
Computer Network
Human Network
Network
Family
Network portion of the IP address
Surname
Host portion of the IP address
First name






Going by my hypothetical family story, there is a Mr. Onifade who has 3 sonsOnifade John, Onifade James, and Onifade Mark. After many years, these 3 sons grew up and gave birth to their own sons too.

Onifade John gave birth to Onifade John Ade and Onifade John Wale

Onifade James gave birth to Onifade James Bade and Onifade James sola

So also, Onifade Mark gave birth to Onifade Mark Mary and Onifade Mark Rose


From the diagram above, we see that everyone on the network has Onifade in a portion of their names, which means they all belong to that network at the 1st level. This level contains the 192.168.X.X network


At the 2nd level we have 3 different sub-networks (SUBNETS) – showing us that the network has been subnetted or in other words sub-divided into 3 groups. This level has the 192.168.10.X, 192.168.11.X, and 192.168.12.X networks.

Simply put, the rule of the thumb is that for computers to know and be able to speak with other computers on the network, they must have some portions of their IP addresses similar, and this similarity is justified by the Subnet Mask.


The Subnet Mask tells the computer or any network device which portions of their IP Address is the Network and which portion is the Host.


The Subnet Mask also state the range or pool of address (network) that device belongs.
  

Having understood my story, I know the question still remains – how really do we subnet?


Ok! Let’s find out…


HOW TO SUBNET

The whole concept of Subnetting is actually the act and art of logically creating more networks from a single network. But before we start digging deep, let’s have a look at a few mathematical concept that we need to be able to effortlessly subnet.


MATHEMATICAL RECALL

I like to bring to your remembrance our little mathematical friend – Binary. Binary is the expression of values in the base 2 (typically, 1s and 0s). As human we have 10 fingers so we easily relate with figures using the base 10.


Now let’s try to bring some devotedness between these two – Binary and Decimal.


Taking 56 for example;

Decimal = 56       -              Binary = 0 0 1 1 1 0 0 0


How is that true?


Recall that 1 byte = 8 bits

That is; 1 byte = X  X  X  X  X  X  X  X


Also recall that to convert a figure from Binary to Decimal and vice versa you have to know this;


So, for 56 the translation looks like this;


For 104, it looks like this;

THE INCREMENT a.k.a BLOCK SIZE

To aid your ability to subnet you have to know this by heart.

The Block size otherwise called Increment is resulting exponential of 2 at every position within the 8 bits of Binary.

And all of the 8 bits when converted to the base 10 sums up to 255. Hence each of the octets of IP address can only be any number between 0 and 255.
Recall that each octet contains 8 bit of data:




Hence the address 192.168.10.1 takes this form;

SUBNET MASK IN BINARY FORM

Since you now understand the IP address from the binary point of view, now let’s see Subnet Mask from a Binary point of view as well.


We have 3 Classes of Default Subnets:

Class A =              255.0.0.0              CIDR= /8

Class B =               255.255.0.0         CIDR = /16

Class C =             255.255.255.0     CIDR = /24


CIDR above means Classless Inter-Domain Routing, and is conceptually the same as VLSM – Variable Length Subnet Mask.


In Subnet Mask 255 represents Network, while 0 represents Host, and when viewed from the binary point of view, 1 is Network while 0 is Host i.e. ;

CIDR NOTATION

This is the simplest part of this topic. This notation is concise way of telling you what the subnet mask of a Network Address looks like.

When you see /24, it simply is telling you that; out of the 32 bits in the IP Address structure, the first 24 counting from the left are “on” which means they are all “1s”.

It’s easy to relate with what happened in the /24 above, but looking at the next item /27, things start getting cloudy         Hey! You, don’t worry, that’s why I’m here!        


Remember that the IP Address format contains 4 Bytes or Octets (x . x . x . x), and that each octet contains 8 bits which can be either 1 or 0.


Also recall that in Subnet Mask, to get the value of an octet you have to get the corresponding value of each bit in decimal and then sum together the decimal value of only the places where the bits are turned “on” (places whose values are 1), as below;


The figure above shows how the value 224 in the 4th octet of the /27 of our previous example was obtained.

If you repeat the process in the figure above then you will find out that that same process led to how other values in the other octets were obtained as well.

Ok!


ART OF SUBNETTING

Since you have grabbed all the information above, let us go into steps to take in order to successfully subnet networks.


STEPS:

·         Know how much networks are needed, and how much hosts per network is required

·         Determine the block size that best fits the host size for your network

·         Increment your network address using the determined block size

·         Ensure you begin your subnetting with the network with the largest number of hosts, and continue in descending order till you get to the finish


REAL WORLD SCENARIO

Company A after several meeting with the heads of department and the CEO has decided that its one large network connecting every departments together should be separated into different sub networks to enforce security and help structure the organization for scalability and other important features.


Company A must use this network address – 192.168.100.0


Company A currently has 5 departments (Admin, Accounts, Sales, Productions and Engineering).

The derived network requirement for Company A goes thus;


From the above description we already have the first information i.e. we already know how many networks are needed – the answer is 5.


So also, each network will have the following number of hosts/users;


Admin                   -              5 hosts

Accounts             -              23 hosts

Sales                      -              45 hosts

Productions        -              12 hosts

Engineering        -              14 hosts


Let us get started;


Remember our Steps:

Starting from the largest, means we’ll have to start with Sales, then Accounts, Engineering, Productions, and Admin.


Starting with Sales….


Recall Block size / Increment
 


The first question you need to ask yourself is; what block size can carry up to 45 hosts?

From above, 32 will be too small but 64 will be ok, although we’ll still have about 17 unused IP addresses but at least we have been able save a lot that would have got wasted if we used a default boundary subnet mask like /24 .


Hence, we’ll increment the given network address number with our selected block size – 64. Another important thing to note is the octet where we’ll be doing the addition, in this case it’s the 4th octet. This will result in the below;


Also, to get the subnet just do the block size addition for every 1s in all octets, for example – 

Sales Subnet Mask looks thus;


1 1 1 1 1 1 1 1 . 1 1 1 1 1 1 1 1 . 1 1 1 1 1 1 1 1 . 1 1 0 0 0 0 0 0

       255             .            255        .            255        .           192                     =      /26


NOTE: As described in the figure below, the Network and Broadcast of each address pool are not useable because they are the boundary of the network.


I believe this write up was helpful!

Thank you.


You can see here also: http://adaptiveit.blogspot.com/