Tuesday, 7 February 2012

OPNET 14.5 Configuration

Hello,
This is my first blog post. Hope it will be interesting to you. I am going to start with network simulator tool OPNET14.5.
So, What is OPNET14.5 ????
OPNET is a network modeler through which one can design any kind of network model and then can simulate it. 14.5 is the version of OPNET and it is freeware.
Here simulation means OPNET will generate the traffic as defined in attributes set by user and will generate results like utilization, collision, load, etc (these analysis parameters are again set defined by user. We will discuss later on how to define each attribute).

Now, first we will discuss about how to install and major part is how to configure the OPNET on MS VS2008.

INSTALLATION
OPNET 14.5 modeler have three packages. So install them in sequence as:
1. First install OPNET Modeler.
2. Second Install OPNET documentation.
3. Then last install OPNET library.
Also,  note that every package is installed in same directory.

CONFIGURATION
Now, after installing one have to set environment variables. So, I think first question will be why we need to set environment variables?? If we don't do what will happen???

Well, I will answer you at the end of this discussion. :) :)

I am considering that MS VS2008 is installed in default directory i.e.( C:\Program Files\Microsoft Visual Studio 9.0\ ). First right click on 'My Computer' choose 'Advanced" tab and the click on 'Environment Variables'. Then in system variables add following variables:
a) PATH
     C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE;
     C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN;
     C:\Program Files\Microsoft Visual Studio 9.0\Common7\Tools;
     C:\Program Files\Microsoft Visual Studio 9.0\Common7\Tools\bin;
     C:\WINDOWS\Microsoft.NET\Framework\v3.5;
     C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727;
     C:\Program Files\Microsoft Visual Studio 9.0\VC\VCPackages;
     C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin;
b) LIB
    C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB;
    C:\Program Files\Microsoft Visual Studio 9.0\VC\LIB;
    C:\Program Files\Microsoft SDKs\Windows\v6.0A\lib;
c) LIBPATH
    C:\WINDOWS\Microsoft.NET\Framework\v3.5;
    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727;
    C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB;
    C:\Program Files\Microsoft Visual Studio 9.0\VC\LIB;
d) INCLUDE
    C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\INCLUDE;
    C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE;
    C:\Program Files\Microsoft Visual Studio 9.0\SDK\v3.5\include;   
e) NetSamplePath
    C:\Program Files\Microsoft Visual Studio 9.0\SDK\v3.5;
f) DevEnvDir
    C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE;
g) FrameworkDir
    C:\Windows\Microsoft.NET\Framework;
h) FrameworkSDKDir
    C:\Program Files\Microsoft Visual Studio 9.0\SDK\v3.5;
i) FrameworkVersion
    v2.0.500727;
j) VCBUILD_DEFAULT_CFG
    Debug^|Win32;
k) VCBUILD_DEFAULT_OPTIONS
    /useenv;
l) VCINSTALLDIR
    C:\Program Files\Microsoft Visual Studio 9.0\VC;
m) VSINSTALLDIR
    C:\Program Files\Microsoft Visual Studio 9.0;

Oops!!!!! lot of variables...:) :)
Now I will answer the question raised at the starting of discussion Why it is required??
So we can design a network in two ways a) Using the Object Pallete and  b) Through coding... Obviously no one wants to do it though coding when everything is graphically done by just setting attributes and code will be generated for same. So whatever you are designing graphically , for same a code  will be generated in C that needed to be compiled before we do simulation so all these variable we defined above will set the path for all header files required for compilation and execution of the network. That's why OPNET requires VS2008 because it uses VS2008 for code compilation and execution. That's why we need to set these environment variables. I think now you got answer of first question that why we did that. Now if we don't do it then we can design the network but cant simulate it.
I think if you go to manual of OPNET you will find the same variable but if it is for VS2005 the directory names will be different for example .Net framework used in VS2005 is v2.0 while in VS2008 it is v3.5 so you need to make changes at all respective places.
Also if you get error during compilation that

gna_email_mgr.pr.tmp.c

c:\opnet\14.5.a\sys\include\vos.h(105) : fatal error C1083: Cannot open include file: 'WinDef.h': No such file or directory.


Then search the Windef.h in my computer. You will get lot of results but you have to select the path as:
C:\Program Files\Microsoft SDKs\Windows\v6.0A\Include;
Copy the address and append it to 'INCLUDE' environment variable value.

I think now we are done with configuration.
uuuhhhhh!!!!!! It seems that we have done a kind of project :) :) but exactly speaking we have just set the environment for our projects :) :).
Hope it gives you enough information to set OPNET 14.5 network modeler. In further discussions of OPNET we will discuss how to design a network and how to simulate and analyse it.
:) :)
Bye!!



53 comments:

  1. thank you so much!!!!

    can you help me ?

    How can make trace C++ code in opnet?

    ReplyDelete
  2. sorry,do you know someone who has installed it on win7?

    ReplyDelete
    Replies
    1. use this link
      http://www.youtube.com/watch?v=6CaV12xknug

      Delete
  3. I was getting some errors but simply appended the location of all the opnet header files to the INCLUDE environment and everything is fine now. Thanks for your guide bro.

    ReplyDelete
  4. I done everything and getting error opgalaxy7.vr is missing. Can u help me? :)

    ReplyDelete
    Replies
    1. Never got this error. So don't have any Idea but still check your environment variables.

      Delete
  5. Hello, I got a problem with OPNET14.5 on win xp VS2005. When i want to run a simulation i get a error log with this kind of problems:

    <<< Recoverable Error >>>
    Process model (aodv_rte) compilation failed
    Errors given in file (C:\Documents and Settings\versacz\op_admin\tmp\cc_err_5228)

    Got any idea how to fix this?

    ReplyDelete
    Replies
    1. This error may be because of application attributes which are not set properly. Check your application attributes or properties.

      Delete
  6. Hello, while running process model i am getting the following error
    1.'op_sv_ptr': undeclared identifier
    2.left of '->dist_addr' must point to struct/union
    3.'prim_dist_outcome': too few arguments for call
    4. 'prim_pk_nfd_set_int32' : too few arguments for call

    how to fix those errors? Is it anywhere related to environment variable declaration ???

    ReplyDelete
    Replies
    1. Hi, These errors may be due to some unset attributes. If u are able to run Hello World then all your environment variables are fine. Check necessary attributes of your application.
      Gd Lk. :)

      Delete
    2. This comment has been removed by the author.

      Delete
  7. comp_msvc: Unable to execute compiler (Win32 error code: 2)
    Check that Visual C++ has been installed correctly, and that
    its BIN directory is included in the Path environment variable.

    I got this error please help me ASAP..m using VS2005 and 14.5 opnet version

    ReplyDelete
    Replies
    1. hey abhishek.. m also getting this problem.. if u find solution please publish it here...

      Delete
  8. Hello Mr Vikram,

    I am getting following error when click for 2D animation in Opnet 14.5 and does not show animation

    "<<< Recoverable Error >>>
    Ignoring arrival of non-ADP packet.
    T (0), EV (-), MOD (NONE), PROC (sim_anim_flow_ipc_pk_error)"

    Please help me out in this.
    Thanks
    Shankar

    ReplyDelete
  9. See On YouTube

    Install OPNET 14.5 on Windows 7 with Visual Studio 2010
    http://www.youtube.com/watch?v=6CaV12xknug


    Install OPNET 14.5 on Windows 8 with Visual Studio 2012
    http://www.youtube.com/watch?v=XhN9kSZbHYg

    ReplyDelete
  10. Dear friend i m frm nitj and working on opnet can mail me some of experiment to learn opnet

    ReplyDelete
  11. --
    Simulation terminated by process (wlan_mac) at module (top.Campus Network.node_4.wlan_mac_1_0), T (0), EV (431)
    Error reported by Wireless LAN MAC process:
    More than one Access Point found within the same BSS (BSS ID = 1)
    or in the same OPNET subnet.
    Check the configuration

    ReplyDelete
    Replies
    1. Simulation terminated by process (ethernet_mac_v2) at module (top.subnet_1.switch.mac_1), T (0), EV (271)
      An error has been detected by the Ethernet Model Suite.
      Check the simulation log for details. If the simulation log was not
      enabled, rerun the simulation after enabling this feature in the
      Project/Simulation Editor.

      Delete
    2. sir i am not able to rectify this error..pls suggest the possible solution for this...

      Delete
  12. simulation aborted by this error
    <<< Recoverable Error >>>
    Process model (aodv_rte) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (app_demand) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (application_config) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (bridge_dispatch_v2) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (bridge_mac_relay_entity_v2) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (bridge_protocol_entity) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (dhcp_client) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (dhcp_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (dhcp_server) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (dsr_rte) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (ethernet_mac_v2) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_ace_task_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_ace_task_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_clsvr_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_conn_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_conn_mcast_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_custom_app_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_database_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_email_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_email_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_ftp_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_ftp_mgr) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)

    ----
    <<< Recoverable Error >>>
    Process model (gna_http_cli) compilation failed
    Errors given in file (C:\Users\user\op_admin\tmp\cc_err_2052)


    it happen when i run simulation to view the statistic


    ReplyDelete
    Replies
    1. hi did u solve these recoverable errors. cz i had the same errors
      plz help me...

      Delete
    2. did you solved this problem

      Delete
  13. sir i install opnet 14.5 on windows7 with MVS 2008 all variables are set but when i select any technology for office network for empty scenerio ,instead of finish opnet is stop working and
    i have 3 options
    1 check online for a solution and close program
    2 close the program
    3 debug
    when 1 is choose nothing is happend and opnet is closed.
    after debugging
    Unhandled exception at 0x00000000 in modeler.exe: 0xC0000005: Access violation reading location 0x00000000.

    plz help me out to solve it ..ASAP...
    i think my processor type is not compatible with opnet 14.5 ...my processor is pentium(R)dual-core..










    ReplyDelete
    Replies
    1. Hi Sonam,
      Your processor is not a problem because first time I worked on system having Pentium dual core processor.
      Just re-verify your environment settings.

      Good luck.

      Delete
  14. ok thanx alot sir. but when i install opnet then it shows a msg that ur processor type is not compatible....then windows7 32bit with mvs 2008 is ok with opnet 14.5

    ReplyDelete
  15. Is vmware for windows7 is gud option to install windows xp and install opnet 14.5 on windows xp virtual machine ???cz its not working on windows7...help me out ASAP..:)

    ReplyDelete
    Replies
    1. Yeah You can try VMWare or any other virtual box to install Win XP and try opnet in it. But please give suficeinet amount of RAM to VMWare at least 1 GB so that it works smoothly.

      It works on Win7 also but only thing that changes is environment variables paths.

      Bye

      Delete
  16. thanx sir i tried environment variables of win7 also bt stil opnet not working ....now i m trying with vmware..
    fingure cross let it works...

    ReplyDelete
  17. sir on vmware in windowsxp when i run opnet as admin then there are so many recoverable errors like one is
    unable to create log file after three attempts..
    then i create password for administrator and then run as admin by password

    now after selecting topology same
    Unhandled exception at 0x00000000 in modeler.exe: 0xC0000005: Access violation reading location 0x00000000.
    as in windows7...AND sir i had already checked all the environment variables.
    sir plz help me ASAP...i m trying to run opnet 14.5 from so many days...

    ReplyDelete
  18. I used windows 8 and Visual studio 2008 and my system is 64 bit and when I compile any process I have got the following error although I added all the variables successfully as I think:

    m11.pr.tmp.c
    C:\Program Files\Microsoft SDKs\Windows\v6.0A\include\winnt.h(81) : fatal error C1189: #error : "No Target Architecture"


    Please help me

    ReplyDelete
  19. hey vikram.. i m new to opnet.. when i try to compile process model, it show the following error:

    comp_msvc: Unable to execute compiler (Win32 error code: 2)
    Check that Visual C++ has been installed correctly, and that
    its BIN directory is included in the Path environment variable.

    please tell me how to overcome this problem..

    ReplyDelete
    Replies
    1. Hi,
      I think the enviornment variables are not properly set.
      Check them :)

      Delete
  20. hiii vikram.. i m pursing b.tech. i want to do project in opnet 14.5 . i had installed 14.5 . i want to convert the opnet 9.1 labs into opnet 14.5 . how to configure in opnet 14.5 .plz help me ,its urgent for me. email- aggarwal_pallavi@ymail.com

    ReplyDelete
  21. hi vikram ,
    i m using opnet modeler 14.5 , when i want to run wpan model that i have downloaded from net , it give following error:
    <>
    repository missing processes model(wpan_sink_process v2.0)

    ReplyDelete
  22. This comment has been removed by the author.

    ReplyDelete
  23. hi:
    I get the following error when I run simulation.
    link (bts -> s_d) specifies non-existent transceiver (s_d.NONE)
    T (0), EV (-), MOD (NONE), PROC (sim_objdesc_link_trx_error)

    but I named the model only s_d (signal destination)
    can you please tell me the solution?

    ReplyDelete
  24. I Had a same problem ... I solved that and shared on my blog

    Install OPNET 14 5 on Windows 8 and Visual Studio 2012
    http://www.cbt4all.com/2014/04/install-ns-3-on-open-suse-part1.html

    Install OPNET 14 5 on Windows 7 and Visual Studio 2010
    http://www.cbt4all.com/2014/04/install-ns-316-on-opensuse-part2.html

    Install OPNET 14.5 on Windows 8 with Visual Studio 2012
    http://www.cbt4all.com/2014/04/install-ns-3-on-opensuse-part3.html


    Also, I created several videos in Installing ns-3 on Suse (OpenSuse) Linux,

    You can my see videos at : http://www.cbt4all.com/

    Install NS-3.16 on OpenSuse-Part1-Install OpenSuse On VM-Ware
    http://www.cbt4all.com/2014/04/install-ns-3-on-open-suse-part1.html

    Install NS-3.16 on OpenSuse-Part2-Install Prerequirments Package for NS-3.16
    http://www.cbt4all.com/2014/04/install-ns-316-on-opensuse-part2.html

    Install NS-3.16 on OpenSuse-Part3-Install NS-3.16 and Run Example
    http://www.cbt4all.com/2014/04/install-ns-3-on-opensuse-part3.html

    Install and configure Eclipse IDE on ns-3
    http://www.cbt4all.com/2014/04/install-and-configure-eclipse-ide-on-ns.html

    I hope it is useful
    more free video? www.cbt4all.com

    ReplyDelete
    Replies
    1. Thanks Reza for sharing your experience. :)

      Delete
  25. This comment has been removed by the author.

    ReplyDelete
  26. Hi vikram...
    I have installed opnet on windows 8 and having visual studio
    2012... Installation went fine...
    I built a project and when i try to run the project it gave me the error...
    Please help me out...

    the error is as given:

    cl : Command line warning D9024 : unrecognized source file type
    'Files\OPNET\145~1.A\models\
    std\include', object file assumed
    cl : Command line warning D9027 : source file
    'Files\OPNET\145~1.A\models\std\include' ignored
    gna_custom_app_mgr.pr.tmp.c
    C:/Program Files/OPNET/14.5.A/models/std/applications/gna_custom_app_mgr.pr.c(24)
    : fatal error C1083: Cannot open include file:
    'gna_custom_app_support.h': No such file or directory

    ReplyDelete
  27. Hi Vikram,

    I am using opnet modeler 17.5 and have installed visual studio 2012. However inspite of setting the environment variables i still get an error showing:

    comp_msvc: Unable to execute compiler (Win32 error code: 2)
    Check that Visual C++ has been installed correctly, and that
    its BIN directory is included in the Path environment variable.
    Can you please help?
    Thanks

    ReplyDelete
    Replies
    1. Hi Shobhana,
      Sometimes error comes because the path u set doesn't exist. Its difficult to guess what may be the problem.

      Delete
  28. Hi Vikram,

    I got these messages in sequence upon running the simulator.

    launched
    aborted

    Any idea what's wrong with the OPNET modeller? Thanks.

    ReplyDelete
    Replies
    1. Hi kman,

      Sorry I didn't see any error like this. If you find solution please post it here.

      Thanks!

      Delete