Re: [ILUG] Linux Certification Exam Question

From: John Bolger (jbolger at domain cliste.net)
Date: Tue 04 Jun 2002 - 10:02:16 IST


On Tue, Jun 04, 2002 at 04:36:35PM +0800, Kieran OSullivan wrote:
> In the SAIR Linux and GNU networking exam there are usually questions about calcualting the subnet
> address of a network given its net mask and the host address.
>
> E.g. If a host has an IP address of 192.168.0.1 and a mask of 255.255.255.248 what is the network address of the subnet.
>
> It takes binary maths to work this one out (rather simple if you have the time) but in the exam you just don't have time to go down to that level so I was wondering if anyone has come up with a trick using decimal numbers which would give the same answer or a prity good guess at one of the choices offered.
>
Subtract the last number from 256 (in this case 256-248). This gives an answer
of 16, which will always be the size of the subnet (including network address
and broadcast address).

Next get a list in your head of products of this number (in this case they
will be 0,16,32,48,64, etc.). These are your possible network addresses.

At that point is obivious which network your host belongs to (0, as 0<1<15).
So your answer is 192.168.0.0

Well thats how I do it. The big limitation with this method include the fact
that it only works up to class C sized subnets and if your given a netmask like /28 you would have to convert it to a dotted quad netmask first.

>
> Cheers
> --
> _______________________________________________
> Get your premium email from http://www.ireland.com/email
>
>
> --
> Irish Linux Users' Group: ilug at domain linux.ie
> http://www.linux.ie/mailman/listinfo/ilug for (un)subscription information.
> List maintainer: listmaster at domain linux.ie



This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:17:04 GMT