Tag Archive: GNS3


Best-practices for configuring GNS3.

I’ve answered some frequently asked questions in my last blog post already, but of course there are other questions that keep returning. Many of them are related to GNS3, a graphical network emulator using Cisco IOS images. I’m going to explain how to best set up GNS3 in a Windows environment, as that is what most people do. Linux should give better results, but I’m still researching that.

GNS3 does not provide IOS images. There’s also no legal way to use IOS images in GNS3, apart from perhaps making a service contract with Cisco. So you’ll have to find the best way to use them yourself. Try to get a 37xx or 36xx IOS, because these seem to be the most stable in GNS3. Most people start with 26xx IOSes because they are most familiar with these, but they’re actually the least stable ones, so try to avoid them. Of course, the more advanced the IOS the more you’ll be able to do with it. After installing GNS3, go to ‘Edit’, then ‘IOS images and hypervisors’. There you can import the IOSes you have. Also, try to give them the memory they need, but not more, it will not be used (especially not in a lab environment) and will take more resources from your host computer.

Next, go to the tap ‘External hypervisors’ in the ‘IOS images and hypervisors’ screen. Here, leave the ‘host’ field on 127.0.0.1, choose a port, UDP and console. The default settings should be okay: +5000 for port, +10000 for UDP, +2000 for console. Also, choose a working directory, which is a personal preference. Click ‘save’ just as many times as you have threads on your CPU(s): this will allow some multithreading for GNS3, which will improve performance on a multicore system. So if you have a dual core CPU with hyperthreading for a total of four threads, make sure four instances are created.

Next, in ‘Preferences’, under ‘Dynamips’, check the ‘Enable ghost IOS feature’, as this will reduce resources needed. GNS3 will now run multiple copies of the same IOS image. Note that in a rare case, in some topologies, I have noticed instabilities here, especially when using different memory on routers using the same IOS image (which is not needed anyway).
Beneath this there’s ‘Enable sparse memory feature’. Enabling it will cause GNS3 to use a paging file more aggressively, slowing down performance. If you have enough RAM, disable it.
Additionally, take your time to look through the other options as well: you can link to Wireshark, allowing you to capture on any interface, specify a capture directory, and do the same for console software.

Now one of the most important things: start up one router with an image you will be using, and after it booted, right-clock on it, and choose ‘Calculate Idle-PC’. Then choose a value from the list, preferably one with * in front of it. This will make the emulator not calculate idle cycles of the emulated image, greatly reducing CPU stress.

And finally: never start all routers at once with the big ‘Play’ button on top. Start them one by one, and open a console after starting each one and check if you can get the basic prompt, ‘R1>_’. This takes a bit longer, but you can boot significantly more routers before everything becomes unstable.

So this way, if done properly, you can get bigger topologies running. This is a basic configuration post, in the future, I hope to explain how to get more stuff running in GNS3, and how to distribute it between different computers.

Advertisement

Advice for recurring questions.

It’s probably time for a post about questions that are often asked on fora, discussion groups and me personally about networking. Here is some general advice to aid in networking for anyone interested in the technology or pursuing a certification (Comptia Network+, CCENT, CCNA).

I’ve completed CCNA. What should I choose now: Voice, Security, …?
An often asked question on fora, but I don’t get why. If you’re interested in something, go for it. If you’re interested in money only, it doesn’t matter what you choose, as all these jobs have similar pay.  If you honestly can’t choose because of the broad interest (as me), go for CCNP if you feel up to the task. Or choose something you know will benefit you at your current or future job. Nice indicators are the used materials: if your work has IP Phones, CCNA Voice may be an interesting option. If they have a wireless deployment, consider CCNA Wireless. If they care about security (and they usually do), CCNA Security can help. If they use Junipers, consider a Juniper certificate, because that’s a known certification too.

Why do you need IP addresses if MAC addresses are already unique? Why not use them?
A surprisingly often asked question. Granted this is a silly question from the perspective of a network engineer but I can understand it’s not clear to someone without experience in the field of networking.
MAC addresses are unique, but not logical. It would be impossible for every router to keep track of all MAC addresses on the planet, and keep updating their location. That would be well over 5-6 billion entries at this point, if not double. By comparison, a modern ISP core router has a route table pointing to networks, not individual devices. With over 350,000 routes in a BGP routing table these days, that’s still impressive and very demanding of a router, but not impossible.

I’ve for an urgent problem with Packet Tracer
Stop. Right. There. There’s no such thing as Packet Tracer and urgent. I’m just mentioning it because it’s not fun if someone mails you saying it’s urgent, you try to help out a little, and in the end it’s a simulation, which is unreliable and not urgent. I’m happy to help out but priorities are important, of course. Which brings me to the next question:

Why does command not work in Packet Tracer?
Because it’s a simulation program, and only contains the commands necessary for CCNA. It’s a great program to learn about networking, and I’ll even go as far as saying that you can get a CCNA certificate by practicing using only this software and no real equipment, but keep in mind it’s not the real equipment, and there are differences. If something doesn’t work as expected (especially layer 2 stuff), it might work fine on real hardware.

I’m studying for CCNP. How do I simulate/emulate switches?
Unfortunately you can’t. I see this question at least once a week somewhere. Packet Tracer only supports basic PVST+ and VTP, and trunking. GNS3 cannot emulate the ASICs used by Catalyst switches properly. With the NM-16ESW module you can do basic Spanning-Tree and I’ve even heard of people getting VTP running, but that’s about it. I’ve never tried other simulators/emulators (Boson, IOU)  but people have reported to me that there was no improvement in the layer 2 stuff. So for switching, you’ll need a real switch. My personal recommendation for the smallest budget is a Cisco 3550, that will get you a long way towards the exam.

Is fiber faster than Ethernet, and does cable length influence latency?
Data over fiber travels at light speed, over Ethernet it’s a bit slower. But bandwidth is the same: a 1Gbps fiber can do 1Gbps, just like a 1Gbps UTP. Also, theoretically cable length does have an influence, but don’t expect any noticeable results until hundreds of kilometers are involved. Data will traverse a full 100m UTP cable run in about 0,5 microseconds.

My wireless doesn’t work/is unstable/is slow. Why?
Wireless is a nice technology, but realise the limits. I’ve heard stories of people trying to connect +100 devices on one access point, or distances of over 50 meters, not counting any concrete walls, and so on. Wireless works, but try to keep it as a last resort, or at least favor the conditions so it doesn’t suffer from noise and other factors. I will explain more in an upcoming blog post.

Can I make my internet go faster?
Yes and no. Keep in mind, as with most things, that there are physical limits. If you have a 1Mbps line from your ISP, nothing is going to make a 20Mbit line out of it.
Things that may help for some applications are a proxy and a DNS caching server. I’ve heard people using pfSense as a proxy server in their network. I noticed my ISP performs poor on DNS sometimes, so another external DNS, or a DNS caching server can help. But both of these mostly increase response time when browsing. Apart from that, there’s no added benefit when streaming media.

My home network is slow, what is causing it?
It can be many things. If you’re using wireless, see the question about wireless above. It depends on the stress each device receives. As a general rule of thumb, if you’re using five devices or more on a regular basis for more intensive traffic patterns (streaming video and the like), consider using a separate small SOHO switch instead of connecting everything to a router. The router will most likely have to handle a lot already. Even a cheap DES-1008D can do wonders, as it takes the load off the router. Considering upgrading everything to gigabit can help too.
Something else that can slow the network are poor cabling or a device causing excessive broadcasts (malware). In the end, the only way to find out, is doing tests, run Wireshark, and try to locate the bottleneck.

I followed lessons and now I’ve waited six months for my exam and
WHY? If I waited six months after my lessons, I would never have passed. Not even at the second try. My last bit of advice for today: if you’ve taken lessons and/or studied for it, go for it. Do not wait. I have yet to meet someone who waited and didn’t regret that. If it’s fresh in your mind, it’s best. You can do it!

Server reconfiguration.

With CCNP SWITCH passed now I can focus on networking in general again now, instead of pure layer 2 stuff. I decided this would be a good moment to reconfigure my server.

When I was gathering materials for my home lab, I had to chance to pick up an IBM xSeries 335 server very cheap. Since it comes with two gigabit NICs and I had never worked with a rack server before, I decided to go for it. I originally installed ESX 3.5, allowing me to research virtual switching and basics of iSCSI, as well as run Windows Server and Red Hat on top of it.

Since I’m familiar with these topics now and not need them directly for my further studies, I decided to install a Linux on it now, and run Dynagen to emulate Cisco routers. Hard decision for me, as I have to admit that I’ve tried a lot with Linux in the past but never could find myself comfortable with it. I downloaded Ubuntu since this would be a relatively user-friendly choice.

Strangely enough for me, things worked out quite well so far: I installed Ubuntu, configured some network settings, installed OpenSSH server and Dynagen, and after about an hour I could log in remotely using SSH and get into Dynagen. I couldn’t do anything in it yet as I need IOS images on the Ubuntu, which I will transfer in the next days, and I’m going to have to read through the Dynagen tutorial, as well as figuring out how to easily create and edit the .net files it uses.

But all in all again a small step towards more labbing options.