GNS3 0.7rc1 supports JUNOS… Lets try it out (Part 2)

Posted: January 11, 2010 in How to, DIY, Network & Security
Tags: , , , , , ,

In my previous post we creating Qemu & olive-base. Let us now continue with installing JUNOS. Also we will see how GNS3 integrates Qemu to run JUNOS.

First, we will make sure we have the following files before proceding further.

Please visit my previous post for more details about patched Qemu and olive-base.img. Some of you will notice the images loading faster, it’s because I have hotlinked them from Picasa web albums. Expect a post for it in future. Lets proceed further with JUNOS installation.

Installing JUNOS:

Before installing Olive we have to make sure we share the connection between PC and Qemu. this is required to transfer Olive fia FTP.

  • Install OpenVPN. Go to network adaptor settings.
  • In TAP-Win32 Adapter and specify ip address (10.0.2.254) and gateway (for internet).
  • Disable Netbios in TAP adapter, it’s junk traffic can slow FTP connectivity.
  • The ip-address of  TAP should be in the same subnet as in free BSD (10.0.2.0/8).
  • Rename TAP-Win32 Adapter to TAP (case-sensitive).

Once extracting Patched Qemuolive-base.img to c:\qemu we will follow below steps.

  • Boot Qemu & attach Intel e1000 virtual network card as well as Tap Adapter.
qemu -m 256 -hda olive-base.img -boot c -localtime \
-net nic -net tap,ifname=TAP -net nic,macaddr=00:aa:00:60:01:01
,model=e1000 -net user
  • Free BSD bootsup and asks for user & password.
  • After entering username and password, Free BSD authenticates and allow you to enter commands.

  • Type ifconfig -a. This will allow you to view connected interfaces.
  • Type dhclient <interface> (em0), route add default 10.0.2.254.
  • After learing ip address via DHCP, type netstat -r to find the default gateway.
  • Ping default gateway as well as PC ip and check connectivity.

-

dhclient em0
route add default 10.0.2.254
netstat -r
ping 10.0.2.2
ping 10.0.2.254
-
-
-
  • Everyting looks good . Now I can download JUNOS via FTP and install it.
  • After downloading Filezilla FTP server, install it. Login to the server, setup user account, shared directory also specify passive mode ip as 10.0.2.254. (I shared my C: drive and placed jinstall-8.5R1.14-domestic-signed.tgz inside C:/Olive folder.). Change the directory permissions to full.

    • Download the file via FTP to /var/tmp directory as shown below.
    • Specify transfer type as binary otherwise it will end up getting corrupted due to ASCII conversion.

    The jinstall file after 7.4 version has a binary called checkpic. This binary will fail and the image cannot be installed. Replacing this binary with /usr/bin/true fixes the issue. Also, it is needed to recalculate MD5 and SHA1 checksums before archiving them back.

    cd /var/tmp
    mkdir jinst-signed
    cd jinst-signed
    tar zxvf ../jinstall-8.5R1.14-domestic-signed.tgz
    
    mkdir jinst
    cd jinst
    tar zxvf ../jinstall-8.5R1.14-domestic.tgz
    
    mkdir pkgtools
    cd pkgtools
    tar zxvf ../pkgtools.tgz
    cd bin
    cp /usr/bin/true ./checkpic
    cd ..
    
    tar zcvf ../pkgtools.tgz *
    cd ..
    rm -rf pkgtools
    tar zcvf ../jinstall-8.5R1.14-domestic.tgz *
    cd ..
    rm -rf jinst
    
    md5 -q jinstall-8.5R1.14-domestic.tgz > jinstall-8.5R1.14-domestic.tgz.md5
    sha1 -q jinstall-8.5R1.14-domestic.tgz > jinstall-8.5R1.14-domestic.tgz.sha1
    
    tar zcfv /var/tmp/jinstall-8.5R1.14-domestic-olive.tgz *

    Before proceeding further upload the jinstall-8.5R1.14-domestic-olive.tgz file to FTP server. This is your new Juniper Olive PKG :-) . You can delete other files from /var/tmp folder except jinstall-8.5R1.14-domestic-olive.tgz.

    If you have downloaded olive-base.img(linux) , skip installation of linux emutor & go to pkg_add.

    • To avoid ELF Binary Type 0 Not Known error when installing, Free BSD has toload Linux kernel modules.

    Follow below steps to add linux emulation inside Free BSD.

    • Add  linux_enable=”YES” line in /etc/rc.conf .  Save the file and reload Free BSD.

    • After reboot type kldstat,check if linux.ko is listed.
    • Copy /usr/lib/libc.so to usr/compat/linux/lib/libc.so. Download linux_base-fc4.
    • Get the file via FTP and untar it to /usr/ports/emulators directory.
    • Edit /etc/make.conf by adding X11BASE=/usr/local. Save the file on exit.

    • From /usr/ports/emulators/linux_base-fc4 run the command make all install to install Linux emulator.
    • When its done, olive-base.img(linux) is ready for installing JUNOS.

    • Finally we will install JUNOS with pkg_add .
    pkg_add -f /var/tmp/jinstall-8.5R1.14-domestic-olive.tgz
    -

    Once the jinstall package installed, stop FreeBSD by using the halt command init 0, quit qemu. Jinstall has installed a bootstrap environment we need not boot up FreeBSD one more time to finish the installation. Juniper router does not have VGA out and redirects everything to the serial port. QEMU can redirect the serial port to either stdio or a telnet port. To do so, launch Qemu with the stdio parameter:  then when booting press CTRL+ALT+3 simultaniously for serial console output.

    qemu -m 256 -hda olive-base.img -boot c -localtime
    -

    • After the installation it will reboot again, login with root user.

    Shutdown JUNOS.  If you wish you do some housekeeping by compressing  the  unused space from the image file. Type the following syntax as mentioned below. This will save some space in your hard drive. Make sure the Image boots properly after compression.

    qemu-img.exe convert -c -f qcow2 olive-base.img -O qcow2
    olive-router.img
    -
    Save the new olive-base.img securely it’s an important. When running in multiples instances, Qemu optimizes file usage by using a common base image, writing only the changes to “slave” images to save on disk space. It also uses less memory for each Qemu instance. How the slave image is created is demonstrated below.
    -
    qemu-img.exe create -b olive-base.img -f qcow2 R<n>.img
    -
    Where <n> can be any number. Multiple instances can be created depending upon the routers you wish to add. The new slave image can be booted as shown below. This is managed in back-end by qemuwrapper.
    -
    qemu R1.img -m 96 -localtime \
    -net nic,macaddr=00:aa:00:60:01:01,model=e1000 -net user
    -
    Networking:

    Our Juniper router works, but it’s of no use unless we are able to network properly. We need to create a virtual network to link them together. Dynamips & GNS3 use UDP tunnels to connect emulated routers. They can be used more reliably to connect two Olive routers together. This can also result in lower latency. All these functions will be done by qemuwrapper.exe.-

    qemu R1.img -m 96 -serial telnet::2001,server,nowait \-localtime
    -net nic,vlan=1,macaddr=00:aa:00:60:01:01,model=e1000 \-net udp,
    vlan=1,sport=10000,dport=10001,daddr=127.0.0.1
    
    qemu R2.img -m 96 -serial telnet::2002,server, nowait \-localtime
    -net nic,vlan=1,macaddr=00:aa:00:60:01:02,model=e1000 \-net udp,
    vlan=1,sport=10001,dport=10000,daddr=127.0.0.1

    -

    Olive to GNS3:

    Bugs…….. I hate em :-( ………

    There seems to be a problem with windows version of  qemuwrapper. It is an important file which does all the back-end stuff like creating slave images, networking different devices via UDP, and managing other functions of Qemu. The problem I’m facing is that whenever I try to start any Juniper router i get the following error

    Dynagen management console for Dynamips (adapted for GNS3)
    Copyright (c) 2008 GNS3 Project
    => Error: could not communicate with qemuwrapper server 127.0.0.1
    It may have crashed. Check the qemuwrapper server output.
    
    Exiting...

    It appears to be with a bug in cli for qemu version 0.11.0 as well as other versions. It’s unable to create FLASH and SWAP files in the temp directory. Even after disabling UAC and giving full access permissions I am getting the same output. To fix this, I tried created the files manually and was able to start the router, but could not gain telnet access.

    c:\GNS3>cd %temp%
    C:\Users\Sushant\AppData\Local\Temp>cd JUNOS1
    C:\Users\Sushant\AppData\Local\Temp\JUNOS1>c:\qemu\qemu-img.exe
    create -b c:\qemu\olive-base.img -f qcow2 FLASH 4G
    
    C:\Users\Sushant\AppData\Local\Temp\JUNOS1>c:\qemu\qemu-img.exe
    create -f qcow2 SWAP 1G
    
    C:\Users\Sushant\AppData\Local\Temp\JUNOS1>cd ..
    
    C:\Users\Sushant\AppData\Local\Temp\cd JUNOS2
    C:\Users\Sushant\AppData\Local\Temp\JUNOS2>c:\qemu\qemu-img.exe
    create -b c:\qemu\olive-base.img -f qcow2 FLASH 4G
    
    C:\Users\Sushant\AppData\Local\Temp\JUNOS2>c:\qemu\qemu-img.exe
    create -f qcow2 SWAP 1G

    One more issue is that Qemuwrapper uses -serial telnet::3000,server command for telnet, however it doesn’t work as documented. The only way to get console access to work is to use -serial telnet:127.0.0.1:3000,server. On linux/Mac this is easy, simply edit the qemuwrapper.py script to use explicit loopback address. On Windows however, without recompiling qemuwrapper I’m not sure how to get this to work.

    Since it’s a Release Candidate, you cannot expect it to be perfect. There are workarounds by which you can edit qemuwrapper.py script and recompile it using python & py2exe. However I prefer to wait till the final release arrives  and continue later.

    EDIT:  GNS3 0.7 is available for download and features integrated Qemu :-) .

    New post WIP..

    -

    Advertisement
    Comments
    1. [...] EDIT: Downloading olive-base.img(linux) will allow you to skip installation of Linux emulator as mentioned in part2. [...]

    2. sunwoo says:

      i know how to configure tap interface..
      my looking TAP is down(unplugged)
      ping 10.0.2.254
      host is down
      host is down….

      • sushantwagle says:

        @Sunwoo

        Made some corrections.

        Make sure you have renamed tap adapter to “TAP”.
        in adapter settings change to application control

        when using tap add “-net nic -net -net tap, ifname=TAP”

        syntax:

        qemu.exe -m 256 -hda olive-base.img -boot c -localtime \-net nic -net tap,ifname=TAP -net nic,macaddr=00:aa:00:60:01:01,model=e1000 -net user

      • kronicklez says:

        my TAP still unplug when i run the first command…anyone can help?

    3. sunwoo says:

      i know qemu command but
      i unknown network adaptor setting
      i unknow TAP ip address and gateway
      and other interface setting(local interface)

    4. sunwoo says:

      What can I enter 10.0.2.254 ip on the network adapter?

      • sushantwagle says:

        Hi,

        Are you using Translate tools?

        Difficult to guess your question.

        1. Where can I enter ip address 10.0.2.254?

        Ans: in your host sytem tap adaptor (tcp/ip settings) & not on FREE BSD.

        2. Can I enter 10.0.2.254 ip on network adaptor (instead of TAP).

        Ans: No, It will fall in L3 domain and free BSD doesn’t have route for it.

    5. kronicklez says:

      what is the username and pswword tu login free bsd

      • sushantwagle says:

        It is mentioned in the post

        user: root
        pass: password

    6. kronicklez says:

      One another question?

      In TAP interface i put ip 10.0.2.245 netmask 255.0.0.0 right?

      How about at FreeBSD itself. Is it automatic grab IP or need to put manual ip…

      • sushantwagle says:

        kronicklez,

        1. “In TAP interface i put ip 10.0.2.245 netmask 255.0.0.0 right?”
        Yes on host PC.

        2. “How about at FreeBSD itself. Is it automatic grab IP or need to put manual ip…”
        If you want you can enter the ip manually provided it is in the same subnet as the TAP interface on local PC.
        I have used DHCLIENT to assign it via DHCP.
        check from “Type ifconfig -a” in the post

    7. kronicklez says:

      Hi sushantwagle,

      This was i understand. Correct me if i wrong.

      1.) Put ip at TAP interface 10.0.2.245 255.0.0.0 rigt?
      2.) Then put ip at freebsd 10.0.2.246 255.0.0.0 right?
      3.) Make sure freebsd can ping TAP ip interface rigt? If ping failed what the problem.

      4.)If ping success then i must add route add default to TAP ip interface right?

      5.) After that i can ftp right ?

      Please correct if i wrong. Appereciate for your fast response?

      • sushantwagle says:

        Hi kronicklez,

        1. Correct.

        2. You can manually enter enter the ip or allow it to be learned in free BSD via DHCP with command “dhclient em0″.

        3. Ping to 10.0.2.245 should work if you have performed the steps correctly. If not check if the TAP adapter goes into connected state when starting Qemu.

        4. The reason for adding the default route is to have internet access. When installing the Linux emulator, it will need net access to download binary files. (Note: in TAP adapter on local pc specify the default gateway with the default gateway ip used for your internet connection)

        5. Yes, provided you configure the FTP server with the required details.

    8. kronicklez says:

      Hi all,

      One additional question? What a difference between model=e1000 & model=i82559er. I search n see mane person using model=i82559er to create olive and success to run MPLS. Can somebody explain to me?

      • sushantwagle says:

        Hmm,

        dont know why the author of GNS3 used qemu version 0.11. JQEMU features “model=i82559er” which is faster and leaner version of intel nic.
        May be in future you can expect JQEMU , You should ask the Author regarding the same.

    9. kronicklez says:

      Hi sushantwagle,

      I already success to install Olive using QEMU but how to add additional interface FXP1. FYI, i use this url as a reference “http://brokenpipes.blogspot.com/2008/01/olive-is-alive.html”

      But if i try to add another interface FXP1 it can’t communicate between freebsd with TAP interface. If i just use FXP 0 it wass success to communicate. Where can I download kqemu latest such as this url “http://brokenpipes.blogspot.com/2008/01/olive-is-alive.html” please see last sentences to download kqemu. To run MPLS (L3VPN) i need at last two interface (FXP0 FXP1). Thnks

      • sushantwagle says:

        Hi Kroniclez,

        This will be done by GNS3. After creating Olive you have to add it in GNS3 config.
        GNS3 contains qemuwrapper which will add the interfaces. We are using the TAP interface only to download and install Olive. Once done is won’t be used in any network topologies.

        Current GNS3 (ver 0.7 post RC1) has problems and cannot run more then 1 juniper router.

    10. kronicklez says:

      Hi sushantwagle,

      Do you mean we can add interface only using GNS3? I think i already test in GNS3 but when i user sh interface terse i can’t see interface FXP1. Kindly need your expertise. Do I need to add TAP interface and run specific command to make sure One olive can have multiple interface FXP0, FXP1 etc. Thnks.

      • sushantwagle says:

        Hi,

        The Idea of GNS3 is to make it simple to integrate and Run Olive. IF you look inside GNS3 folder you will find an exe named “qemuwrapper.exe” which handles the cli commands needed to run qemu. Thus when you add an interface in GNS3 “qemuwrapper” will add interface(s) in cli. In short Qemuwrapper uses UDP tunnels to connect emulated Juniper routers.

        As I have mentioned earlier we are using TAP to transfer files between Host PC and Free BSD. It wont be used after that.

    11. kronicklez says:

      Hi sushantwagle.

      I understand what you mention. So in other word its enough just to have one interface for one Instances. How I want to play if topology such as A–B–C. Kindly need your guidelines. Thnks.

      • sushantwagle says:

        Hi,

        With Current ver of GNS3 (0.7) you can only run one JUNIPER router due to bugs in qemuwrapper.
        However you will be able to connect two or more cisco routers to Juniper.

    12. [...] GNS3 0.7rc1 supports JUNOS… Lets try it out (Part 2) [...]

    13. nub says:

      Hello sushant,

      For the last twodays I have been trying to see a Junos to work on my system but with no luck.. I have installed the latest gns3 0.7.2 and set the path for Junos as \GNS3\JunOS\olive-base.img. After dragging the Junos router and starting it A qemu window is loading and stopping at the root prompt after entering root/password. Then I tried to console to the Junos but Not seeing any thing on the telnet session. Its just blank. Do you know what I am missing in this case?

      • sushantwagle says:

        Hi there,

        Gns team still hasn’t fixed the bug in windows, which causes to run only one instance of Juniper router. This issue is not found in Linux or mac version.

        more details: http://www.gns3.net/phpBB/topic1914.html

    14. nub says:

      Hi Sushant, It still doesn’t make sense of what mistake I am doing.. I have switched to Ubuntu 10.04 assuming it will be a smooth sail. Yes the compilation went pretty smooth (I assume this is actually NOT necessary with the current release.) My issue is to install the Juniper release from BSD to router.. BSD just not getting route to the local host either on Windows or linux platform for ftp to work. I am using 64 bit processor and assuming all the installs were done properly so far.. Any thoughts would be great.

      • sushantwagle says:

        make sure you are able to ping TAP adaptor ip. (configured on windows host)

        add a default route towards TAP adaptor in BSD. (mentioned in post.)

        please let me know the steps you have performed.

    15. nub says:

      Ok Finally Got it working on Ubuntu after spending 3 days! Newversion of gns3 is much better as there is no requirement for MSys MinGw etc.. Conceptually I am still not clear of why we are using a Cloud – bridge – junos..Gud learning on free BSD, Qemu etc during this process of instalation..

      • sushantwagle says:

        Happy to hear that. You can also connect them without the cloud viz interface to interface.

        • kronicklez says:

          Hi sushantwagle

          Just one question. How to add multiple loopback IP addr in one logical router? Thanks..

        • sushantwagle says:

          I have not studied much about logical routers but i think this is how you can add multiple loopback interfaces to logical routers

    16. mico says:

      Hi

      I have followed each and every step and not able to ping the ip address of TAP (10.0.2.254) from FreeBSD(QEMU),

      I was successfully ping the ip address 10.0.2.2, please help me in this ,

      1) can SCP be used for downloading jinstall-8.5R1.14-domestic-signed.tgz into FreeBSD(QEMU) instead of FTP ?.
      2)can i put jinstall-8.5R1.14-domestic-signed.tgz locally on my desktop and download it via SCP into FreeBSD(QEMU).
      3)can a real LAN card address used instead of virtual(OpenVPN) LAN card?
      4) My TAP interface is always connected at 10Mbps when i start Qemu, what could be the reason for not ping 10.0.2.254(TAP)?.
      5) If i do not give default GW(internet) will it still ping 10.0.2.254?
      6)can windows firewall block the ping packets or any other software can block them which result in packet loss?

      Thanks in advance for ur help.

      • sushantwagle says:

        1): Yes you can use SCP to transfer the files. Check if your OS has any compatibility issues with it.
        I used FTP because its easy and well known

        2): Yes as long as your server knows where the file is stored, and the BSD Client is able to communicate with the server.

        3):I am not sure if there is any support for real LAN cards in this version of Qemu.

        4): check the Adapter properties > configure > advanced > media. See if it is set to Application controlled.
        check if you have entered the syntax correctly : http://pastebin.com/xVBUJbsa
        Download and install the latest version of GNS3(delete the old one first). I have tried it from Qemu.exe inside GNS3 installed folder.

        5): Its obvious. 10.0.2.254 falls in the same Layer 2 domain as the freebsd. check “arp -a” and see the ip and mac address.

        6): It can if it has blocked ICMP. IF you are seeing mac address in windows as well as free bsd but you are not able to ping, disable the firewall.

    17. mico says:

      Hi,
      Thanks for your reply, Now i am able to ping successfully the both ip addresses 10.0.2.2 and 10.0.2.254 from QEMU and now i want to proceed for the JunOS installation via FTP. please guide me about the following.
      1) Should i download FileZilla client or FileZilla Server from http://filezilla-project.org/?
      2)In FileZilla client for the remote file jinstall-8.5R1.14-domestic-signed.tgz download from internet which (Host, Username , Password and Port) should i use ,do I have to make it my self by going to the Host website?
      3)In FileZilla client for the Remote file ,If I place the file jinstall-8.5R1.14-domestic-signed.tgz locally in my pc C:\Olive folder , which (Host, Username , Password and Port) should I use, Is this the one used to Login into Windows XP?
      4) In the above FTP example , Is the remote file jinstall-8.5R1.14-domestic-signed.tgz being placed locally on the pc in C:\Olive Folder or being placed remotely on the internet FTP server?
      5)In the above FTP example , from where do the Login Name (10.0.2.254:root):ftp and Password come from?
      Thanks in advance again for your help.

      • sushantwagle says:

        Hi,

        1. Since we are uploading it to from Windows system we need Filezilla Server. Make sure you set the authentication and connection details in its gui. Its very intuitive to configure. When downloading the file in BSD set the download to Binary type, it assumes ASCII by default.

        2. Search the “jinstall-8.5R1.14-domestic-signed.tgz” from google and download it. Somebody has already hosted it and does not require any user/pass. It can also be downloaded in freebsd directly. make sure to enable internet sharing in your LAN adapter which is used for internet.

        3. In the Filezilla server u mean?. Authentication is irrelevant of windows ADS. you can configure this in the server users.

        4. the remote file jinstall-8.5R1.14-domestic-signed.tgz which I downloaded form the internet I placed it in “any xyz folder”, mapped it in the Filezilla server for FTP root directory.

        5. As mentioned above I configured this in the FTP server gui. you can configure any “abc” user/pass and enter it in bsd when loging in.

    18. mico says:

      Hi,

      Thanks for ur help ,some more questions as below.
      1)what command is used to upload the jinstall-8.5R1.14-domestic-olive.tgz file to ftp server? is it mput? do we keep the same directories when downloaded the file in QEMU?
      2)Do we need to specify the “binary” command while uploading via ftp as well?
      3) what is the command for deleting the other files from /var/tmp folder except jinstall-8.5R1.14-domestic-olive.tgz?

      Thanks in advance.

    19. mico says:

      Hi,
      1) After the JUNOS installation it will reboot again, login with root user and Shutdown JUNOS, which command is used to shutdown JUNOS? typing “halt”?.
      2) Which command will boot the image properly after compression ?

      Thanks

      • sushantwagle says:

        “shutdown -a” will shutdown the router. It gives a message that u can turn off since it cant (remember old PCs, junos was built at that time). close qemu window.

        Gns3 will boot the router for you. After you have shutdown the router, link it inside GNS3. Add one router in network topology and press start button, which boots the router.

        One thing, which you should already know from my previous comments
        GNS 3 cannot run more than one instance of junos in windows,
        works on linux and Mac.

        If you have ubuntu installed , I have posted how to install GNS3.
        junos works perfectly on it.

    20. mico says:

      Hi,

      Please guide , as i need to Run More than one JUNOS router instances on GNS3.
      1)Please give me link where i can download ubuntu OS ? what release of ubuntu can i download?
      2)can i easily operate ubuntu just for GNS3? , as i have only windows XP experience.
      3)can i use windows compiled olive-base.img with JUNOS installed on ubuntu?

      Thanks

      • sushantwagle says:

        Download from here: http://www.ubuntu.com/desktop/get-ubuntu/download

        Step by step procedures are mentoned on the site.

        I suggest you install Ubuntu via WUBI (Windows Ubuntu installer).
        You will need a free NTFS partion (Primary) Say 10 gb.
        http://www.ubuntu.com/desktop/get-ubuntu/windows-installer

        Again very easy step-by-step procedures are mentioned on the site.

        WUBI installs Ubuntu under windows and creates primary and secondary os grub boot.
        So when you wish remove ubuntu, Simply boot from windows and uninstall it.

        After Ubuntu is installed. Make sure you update it first.

        Installing GNS 3 in ubuntu http://sushantwagle.wordpress.com/2010/05/16/gns3-0-7-1-2-on-ubuntu-10-04-lts-the-easy-way/

        Yes there is a learning curve just like when you come from cisco world to juniper. But when you are through you will enjoy it.

        “olive-base.img” is a hard disk image, just like vmware disk.

    21. prasad2612 says:

      Hi,

      Please guide , as i need to Run JUNOS router instances on GNS3.

      i compiled olive-base.img from 4.11 free mini installation.iso after that i booted using olive-base.img with e1000 nic, assaigned ip 10.0.2.5 to interface em0, for TAP interface i assigned 10.0.2.1 ip , now i was trying to do ftp to ip 10.0.2.1 (i.e tap interface ) not able to get connected to it, due to that i am not able to copy jinstall file to /var/tmp folder, i am using 10.255.8.176 to my pc, but tap interface is 10.0.2.1 (will this make any difference).. did i miss something .. please help me how out as i was working on it for long time….

      it would be great if u can solve my prob,

      Regards
      Prasad

      • sushantwagle says:

        Hi Prasad,

        1. Check if you are able to ping the TAP IP from FREE BSD. Are you able to learn the arp address of TAP in BSD?
        Check the tap adaptor, See if media status is application controlled.
        It should show down when Free BSD is not running and UP when Free BSD runs.
        Disable your Firewall and check.

        2. If you are able to ping the TAP adapter from free BSD. check your FTP setting. Make sure FTP server is up and running. Check if you have specified the external ip to be used by FTP server. Check if you are able to FTP locally, if not your server may not be running / A Firewall may be limiting the connection. Disable your firewall and check.

        • prasad2612 says:

          Hi Sushant

          I am able to ping from BSD to TAP interface. But I am not able to do FTP from BSD to FTP server which is hosted on Windows 2003 OS. I tried with Golden FTP/ Filezilla and Windows 2003 built in IIS FTP server .But FTP is failing.

          Error message that I am getting is “421 connection reset by peer” . I tried doing FTP from other machines it is working fine. Only from BSD is is not able to do FTP.

          I checked Firewall settings and found nothing obstructing any ports/sockets.

          Please help

        • sushantwagle says:

          Hi Prasad,

          Make sure you have disabled NetBIOS (in tap adaptor >> IPv4 >> Advanced >> WINS).
          NetBIOS Causes broadcast storms which limits the connection by chocking the TAP adaptor.
          you can also disable client for microsoft, QOS, file and printer sharing.

          1. IS this FTP server Directly connected (via TAP) to BSD.

          2. Do a high Mtu ping from FTP server to determine whether this is an MTU issue.
          do “ping [bsd ip] -l 1472 -f” from FTP server. Also note the Latency should note be more than 10 msecs.

          3. Is the qemu run from the latest GNS3 package.

          4. provide me the complete logs from BSD as well as FTP server. also the ping response.

    22. shivlu jain says:

      cd /var/tmp
      mkdir jinst-signed
      cd jinst-signed
      tar zxvf ../jinstall-8.5R1.14-domestic-signed.tgz

      mkdir jinst
      cd jinst
      tar zxvf ../jinstall-8.5R1.14-domestic.tgz

      Please let me know do we need to install install-8.5R1.14-domestic-signed.tgz and install-8.5R1.14-domestic.tgz files and both need to be uploaded in /var/tmp.

      regards
      Shivlu Jain
      http://www.mplsvpn.info

      • sushantwagle says:

        Hi Shivlu,

        “jinstall-8.5R1.14-domestic-signed.tgz” is an install package.
        What we replacing its “checkpix” file with the one located inside /usr/bin/true in BSD
        checkpix is located inside “jinstall-8.5R1.14-domestic-signed.tgz\jinstall-8.5R1.14-domestic.tgz\pkgtools.tgz\bin”

        After version 7.4. You cannot install Olive directly as the existing checkpix wont let u do it. The only way is to replace it.

        After untaring, we replace the checkpix, correct the checksums and create “jinstall-8.5R1.14-domestic-olive.tgz”

        same as “jinstall-8.5R1.14-domestic-signed.tgz” install package.
        This is the only file we will use to install Olive package. Delete the rest of the stuff inside /tmp, its not needed.

    23. Nitin says:

      Hello Sushant,

      I hope you are doing good mate.

      I know its been a long long time since we spoke last time, i had been busy with my University exams and work, so wasnt working on GNS at all.

      Just finished with my Uni exams, so i was thinking if you can help me with simulating PIX and ASA in GNS please.

      Any help would be much appreciated.

      Thanks
      nitin

      • sushantwagle says:

        Hi Nitin,

        some one has already created a step by step for ASA, using “asa802-k8.bin”
        http://www.brainbump.net/2010/03/gns3-how-to-emulate-asa-in-windows-7/
        http://www.brainbump.net/2010/02/gns3-how-to-emulate-asa-in-ubuntu-9-10-linux/

        No plans for it right now, the reason being I don’t work on Firewalls/Security platforms.
        May be in future i will plan on a post.

    24. Nitin says:

      It seems like the webpage you directed me to is for Linux since following softwares are required..

      Ubuntu 9.10 – 32 bit Edition
      GNS3 v0.7 RC1 tgz (Download it here)
      Dynamips 0.2.8-RC2 binary for Linux x86 platforms (Download it here)
      Qemu-0.11.0 tar.gz (Download Link)
      Qemu-0.11.0 Patch (Download Link)
      ASA Binary Version 8.0(2) – (asa802-k8.bin)
      For detailed explanation about emulating ASA tutorial , check this link.
      Download Shell Script (first_start.sh) – Right Click to Save !

      Could you suggest me for Windows???

    25. Biddumehta says:

      Not able to connect to FTP server from QEMU .

      ### Logs on Qemu ###

      ping to 10.0.2.2 and 10.0.2.254 is OK.

      #ftp 10.0.2.254
      connected to 10.0.2.254


      Name(10.0.2.254:root): cisco
      421 Service not available , remote server has closed connection.
      ftp: Login failed.
      ftp: No control connection for command

      ### Logs on FTP server filezilla ###

      000017)9/5/2010 9:00:02 AM – (not logged in) (127.0.0.1)> Connected, sending welcome message…
      (000017)9/5/2010 9:00:02 AM – (not logged in) (127.0.0.1)> 220-FileZilla Server version 0.9.36 beta
      (000017)9/5/2010 9:00:02 AM – (not logged in) (127.0.0.1)> 220-written by Tim Kosse (Tim.Kosse@gmx.de)
      (000017)9/5/2010 9:00:02 AM – (not logged in) (127.0.0.1)> 220 Please visit http://sourceforge.net/projects/filezilla/
      (000018)9/5/2010 9:00:02 AM – (not logged in) (10.0.2.15)> Connected, sending welcome message…
      (000018)9/5/2010 9:00:02 AM – (not logged in) (10.0.2.15)> 220-FileZilla Server version 0.9.36 beta
      (000018)9/5/2010 9:00:02 AM – (not logged in) (10.0.2.15)> could not send reply, disconnected.
      (000017)9/5/2010 9:00:03 AM – (not logged in) (127.0.0.1)> disconnected.

    26. J.M says:

      Hi,
      I’ve installed Olive using jinstall-7.4R1.7-domestic-signed.tgz and created two copies using Ubuntu Distributor ID: Ubuntu
      Description: Ubuntu 10.04.1 LTS
      Release: 10.04
      Codename: lucid

      qemu R1.img -m 96 -nographic -daemonize -serial telnet::2001,server,nowait \
      -localtime -net nic,vlan=1,macaddr=00:aa:00:60:01:01,model=e1000 \
      -net socket,vlan=1,listen=:6000

      qemu R2.img -m 96 -nographic -daemonize -serial telnet::2002,server,nowait \
      -localtime -net nic,vlan=1,macaddr=00:aa:00:60:01:02,model=e1000 \
      -net socket,vlan=1,connect=127.0.0.1:6000

      I telnet on each of them using telnet 127.0.0.1 2001, telnet 127.0.01 2002
      then I configured the basic on both olives as
      R1
      root@%cli
      root>edit
      [edit]
      root#

      [edit]
      root#set system root-authentication plain-text-password
      New password:
      Retype new password:

      [edit]
      root#set interfaces em0 unit 0 family inet address 10.0.0.1/8
      [edit]
      root#commit
      commit complete

      R2
      root@%cli
      root>edit
      [edit]
      root#

      [edit]
      root#set system root-authentication plain-text-password
      New password:
      Retype new password:

      [edit]
      root#set interfaces em0 unit 0 family inet address 10.0.0.2/8
      [edit]
      root#commit
      commit complete

      However when trying to ping each other I get
      root> ping 10.0.0.2
      PING 10.0.0.2 (10.0.0.2): 56 data bytes
      ping: sendto: Can’t assign requested address
      ping: sendto: Can’t assign requested address
      ping: sendto: Can’t assign requested address
      ping: sendto: Can’t assign requested address
      ping: sendto: Can’t assign requested address

      even a ping on each router does not work. Where am I getting it wrong, please help.

      Regards

    27. waleed says:

      Hi sushantwagle,

      Thank you for your nice and useful post,
      i get Problem with no interface em0 its not appear only ed0 and loopback.
      BTW i download all your files including patched qemu and Olive image which you provide us
      and i follow your steps as well also i follow Gns3 Blog so please can you help pls<
      or is it fine i can continue the steps and install junos ?

      Thanks..

    28. [...] http://sushantwagle.wordpress.com/2010/01/11/gns3-07rc1-supports-juniper-part2/ [...]

    29. Luis Glez says:

      Hi Sushant,

      Same sympthoms:

      fto 10.0.2.254
      Connected to 10.0.2.254
      421 Service not available, remote server has closed connection.

      I am using Windows 7.
      By the way if I try the same thing on the host pc:
      Microsoft Windows [Version 6.1.7600]
      Copyright (c) 2009 Microsoft Corporation. All rights reserved.

      C:\Users\Administrator>ftp 10.0.2.254
      Connected to 10.0.2.254.
      220-FileZilla Server version 0.9.36 beta
      220-written by Tim Kosse (Tim.Kosse@gmx.de)
      220 Please visit http://sourceforge.net/projects/filezilla/
      User (10.0.2.254:(none)): luis
      331 Password required for luis
      Password:
      230 Logged on
      ftp>

      I already followed your recommendations about Netbios on the TAP interface without success, also I removed Filezilla and install it again since I was not having successful connections to localhost.

      I read that it might be an issue with ftp permission within FreeBSD. Can you please provide your input???

      Thanks in advance!