Skip to content

Installing OMNet++ IDE Under new Windows11 Version Using WSL

The Windows Subsystem for Linux (WSL): 

The Windows Subsystem for Linux (WSL) lets developers run a GNU/Linux environment — including most command-line tools, utilities, and applications — directly on Windows, unmodified, without the overhead of a traditional virtual machine or dual-boot setup[1]. Particularly, by using the latest version of WSL2 under Windows 11 one can effortlessly install ns-3 and NetAnim under Windows 11.

Compiling the latest Linux-based simulation tool  OMNet++ using  (Cygwin, MinGW and MSYS2  will be a challenging task. Of course, some people successfully made it work but the rest of the people may fail to make it work because of various reasons.

But, using different virtualisation solutions such as Microsoft Virtual PC, Microsoft Hyper-V, VMWare, VirtualBox, etc., one can successfully install and use any Linux-based application under Windows. But the performance of OMNet++ simulation in terms of speed will be good under these kind of desktop virtualization solutions.  But Windows Subsystem for Linux is the best and most efficient way of running a Linux-based simulation tool OMNet++ under Windows. It will give better performance in terms of speed while comparing with other virtualization technologies. Most among all, with native support for GUI-based applications, we can effortlessly run the OMNet++IDE and even 2D and 3D outputs of OMNet++ simulations under Windows 11.

 

Installing WSL2 and suitable Linux version Under Windows 11 for OMNET++ Installation.

 

The following step-by-step procedure explains the way of installing WSL2, and Ubuntu under the latest Windows 11 version.

 

Installing WSL2 Under Windows 11 and Running GUI Linux Apps.

 

The installation procedure of OMNet++ 6 that we present here is almost the same as the following one :

Installing OMNeT++ 6 on a 64-bit Debian 10 Under Chroot-Jail

Instead of doing it under chroot, we are repeating it under Ubuntu 20.04.4 LTS which was installed on WSL2 of Windows 11.

 

Installation of OMNet++ under DSL of Windows 11

Step 1: Update the apt package repository

$ sudo apt-get update

Step 2: Install the necessary dependancies

$ sudo apt-get install -y build-essential clang lld gdb bison flex perl python3 python3-pip qtbase5-dev qtchooser qt5-qmake qtbase5-dev-tools libqt5opengl5-dev libxml2-dev zlib1g-dev doxygen graphviz libwebkit2gtk-4.0-37
The following screenshot shows the successful installation of necessary dependencies under Ubuntu which was installed under WSL2 of Windows 11.
 

Step 3: Install some python related packages

$ python3 -m pip install –user –upgrade numpy pandas matplotlib scipy seaborn posix_ipc
The following screenshot shows the progress of pip based installation process:
 
 
And the following screenshot shows the successful installation of python related dependencies :

Step 4: Install OpenSceneGraph 3D support

# this step may fail under your linux version – just ignore it if you do not need openscenegraph and osgearth
$ sudo apt-get install -y openscenegraph-plugin-osgearth libosgearth-dev
The following screenshot shows the successful installation of OSG 3D related Dependencies under WSL2 :

Step 5: Install MPI support

 
$ sudo apt-get install -y mpi-default-dev
The following screenshot shows the successful installation of MPI related Dependencies under WSL2 :
 

Step 6: Install nemiver support

$ sudo apt-get install -y nemiver
The following screenshot shows the successful installation of memiver related Dependencies under WSL2 :

Step 7: Download and Extract OMNeT++ 6

Download OMNeT++ 6 from the following link

 

$ wget https://github.com/omnetpp/omnetpp/releases/download/omnetpp-6.0/omnetpp-6.0-linux-x86_64.tgz
Extract it
 
#extract the compressed file
$ gzip -d omnetpp-6.0-linux-x86_64.tgz
$ tar -xvf omnetpp-6.0-linux-x86_64.tar
The following screenshot shows the successful extraction of omnetpp-6.0 under the home directory of the user :
 

Step 8: Compiling Omnet ++

Hidden Section! Contact Charles  

The key/passphrase will be given once you have been approved for getting paid research support/assistance from Charles. To get paid support, you may start a 'free' research discussion.  

WhatsApp chatDiscuss Through WhatsApp
 

 
#compiling omnet++ 6.0

$ cd /home/omnetpp-6.0

#configure make file according to the environment
$ ./configure

# – if you do not need OSG support
$ ./configure WITH_OSG=no 

 
The ‘make’ may end with an error related to xdg-desktop-menu:
 
Correct the above error as follows:

Hidden Section! Contact Charles  

The key/passphrase will be given once you have been approved for getting paid research support/assistance from Charles. To get paid support, you may start a 'free' research discussion.  

WhatsApp chatDiscuss Through WhatsApp
 

And run make again:

#speeding the make using multiple processors ( the -j option)
$ make -j9
The following screenshot shows the successful compile of OMNet++ 6:
 
 

Step 8: Running OmNet++

You may add the following lines in .bashrc file:

Hidden Section! Contact Charles  

The key/passphrase will be given once you have been approved for getting paid research support/assistance from Charles. To get paid support, you may start a 'free' research discussion.  

WhatsApp chatDiscuss Through WhatsApp
 

 
$ omnetpp
If we run the omnetpp under Ubuntu,  WSL terminal,  it will run inside Ubuntu and will display its IDE on the desktop of the Windows 11 host.
 
 
If we select “samples” as workspace, then it will show the opened workspace under the IDE

Installation of INET4.4

While opening the IDE for the first time, and if we have selected to install INET4.4, then it will automatically get installed. You can see the progress in the status bar at the bottom of the IDE.

At the end of the installation, now it is ready to  do projects with OMNet++ 6.0 with INET4.4
 
 
 
 
A 2D Network Animation and Visualization Example.
 
 

Conclusion

With the latest Windows 11 and its WSL2 support, we can run any GUI-based Linux applications under windows. The future version of WSL may even have excellent support for applications that may use 3D graphics subsystem. 

Now we can install any text-based as well as GUI-based Linux application under this Ubuntu which is running under WSL2. So, now it is possible to install OMNet++ with its IDE and may run 2D and 3D simulations under Windows 11 .

We may see the installation procedure of different simulation tools under WSL2 in different articles. Meantime one may try the following installation procedures under WSL2.

https://www.projectguideline.com/installing-netsimulyzer-3d-visualization-tool-under-linux-virtual-guest-operating-system-environment/

Installing NetSimulyzer 3D Visualization Tool Under Linux Virtual Guest Operating System Environment

https://www.projectguideline.com/installing-aquasim-aqua3d-on-an-old-linux-under-virtualbox/

Installing Aquasim & Aqua3D on an old Linux under VirtualBox

References 

    1. https://docs.microsoft.com/en-us/windows/wsl/about
    2. https://ubuntu.com/tutorials/install-ubuntu-on-wsl2-on-windows-11-with-gui-support#1-overview
    3. https://www.nsnam.org/wiki/Installation
    4. https://www.projectguideline.com/installing-omnet-in-debian-9-chroot-jail-under-debian-11-host-os/
    5. https://doc.omnetpp.org/omnetpp/InstallGuide.pdf
WhatsApp Discuss Through WhatsApp