NDNSIM NS-3 Visualiser Fail to Execute

165 views
Skip to first unread message

Josh LRT

unread,
Jun 25, 2019, 2:21:49 AM6/25/19
to ns-3-users
My NS-3 Configured as >> https://pastebin.com/jd2PwQMp
My NS-3 compile successfully with examples and visualiser >> https://pastebin.com/WdYYXfVH

But when I run a simple ndn scenario,
sudo ./waf --run=ndn-simple --vis

I got this errors,
Waf: Entering directory `/home/lrtndn/Desktop/ndnSIM_working/ns-3/build'
Waf: Leaving directory `/home/lrtndn/Desktop/ndnSIM_working/ns-3/build'
Build commands will be stored in build/compile_commands.json
'build' finished successfully (14.261s)
Could not load plugin 'show_last_packets.py': could not import gobject (could not find _PyGObject_API object)
Could not load icon applets-screenshooter due to missing gnomedesktop Python module
Traceback (most recent call last):
  File "<string>", line 2, in <module>
  File "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py", line 1877, in start
    viz = Visualizer()
  File "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py", line 760, in __init__
    self.create_gui()
  File "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py", line 1096, in create_gui
    monitor = display.get_primary_monitor()
AttributeError: 'X11Display' object has no attribute 'get_primary_monitor'

Please help, I am running Ubuntu 16.04.6 LTS.
Release: 16.04
Codename: xenial

Jan Lühr

unread,
Jun 25, 2019, 4:40:38 AM6/25/19
to ns-3-...@googlegroups.com
Hello,


Am 25/06/2019 um 08.21 schrieb Josh LRT:
> My NS-3 Configured as >> https://pastebin.com/jd2PwQMp
> My NS-3 compile successfully with examples and visualiser
>>> https://pastebin.com/WdYYXfVH
>
> But when I run a simple ndn scenario,
> */sudo ./waf --run=ndn-simple --vis/*
>
> I got this errors,
[..]
> */Could not load icon applets-screenshooter due to missing gnomedesktop
> Python module/*
> */Traceback (most recent call last):/*
> */  File "<string>", line 2, in <module>/*
> */  File
> "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py",
> line 1877, in start/*

> Please help, I am running Ubuntu 16.04.6 LTS.

It looks like you're missing some python libraries / dependencies. You
can install them using apt - I guess it's possible to you bake
(build.py), too.

Please check for warnings using ./waf --configure

Greetz, Jan

Jan Lühr

unread,
Jun 25, 2019, 4:52:15 AM6/25/19
to ns-3-...@googlegroups.com
Hellom
Oops, sorry, that might be to generic. To be more specific:
afaik waf fails to detect some missing dependencies, but they are still
warnings sometimes. I struggled with ubuntu using apt, too. Some folks
said, that bake is able to resolve dependencies, but I haven't tried yet.

I'm able to use vis on bionic (18.04) and ns-3 3.29 - installed packets
are: http://jluehr.de/dpkg-l.txt

Greetz, Jan

Josh LRT

unread,
Jun 25, 2019, 10:01:51 PM6/25/19
to ns-3-users
Hi .. maybe u are rights. I am checking the dependencies 1 by 1  and stuck in pybindgen compilation, in ns-3 configuration, it stated my pybindgen missing, but is in the same root folder so I decide to reconfigure pybindgen and found out > 
Checking for program castxml     : not found

how do I install that ?

Tom Henderson

unread,
Jun 25, 2019, 11:01:59 PM6/25/19
to ns-3-...@googlegroups.com
On 6/24/19 11:21 PM, Josh LRT wrote:
> My NS-3 Configured as >> https://pastebin.com/jd2PwQMp
> My NS-3 compile successfully with examples and visualiser >>
> https://pastebin.com/WdYYXfVH
>
> But when I run a simple ndn scenario,
> */sudo ./waf --run=ndn-simple --vis/*
>
> I got this errors,
> */Waf: Entering directory `/home/lrtndn/Desktop/ndnSIM_working/ns-3/build'
> /*
> */Waf: Leaving directory `/home/lrtndn/Desktop/ndnSIM_working/ns-3/build'/*
> */Build commands will be stored in build/compile_commands.json/*
> */'build' finished successfully (14.261s)/*
> */Could not load plugin 'show_last_packets.py': could not import gobject
> (could not find _PyGObject_API object)/*
> */Could not load icon applets-screenshooter due to missing gnomedesktop
> Python module/*
> */Traceback (most recent call last):/*
> */  File "<string>", line 2, in <module>/*
> */  File
> "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py",
> line 1877, in start/*
> */    viz = Visualizer()/*
> */  File
> "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py",
> line 760, in __init__/*
> */    self.create_gui()/*
> */  File
> "/home/lrtndn/Desktop/ndnSIM_working/ns-3/src/visualizer/visualizer/core.py",
> line 1096, in create_gui/*
> */    monitor = display.get_primary_monitor()/*
> */AttributeError: 'X11Display' object has no attribute
> 'get_primary_monitor'/*
>
> Please help, I am running Ubuntu 16.04.6 LTS.
> Release:16.04
> Codename:xenial

I am not sure about the status of NDNSIM (which is a fork of ns-3), but
in general people have been reporting problems with this particular error:

AttributeError: 'X11Display' object has no attribute 'get_primary_monitor'

on Ubuntu 16.04. There have been some changes in ns-3 to move from
pygoocanvas to pygobject 3.0 in the past year; see:

https://mailman.isi.edu/pipermail/ns-developers/2018-June/014403.html

see also:

https://www.nsnam.org/bugzilla/show_bug.cgi?id=2930

and I can confirm that I have used PyViz recently on ns-3-dev (also
ns-3.29) on macOS and also Ubuntu 18.04 and later, but I'm not sure
about the status of Ubuntu 16.04.

- Tom

Josh LRT

unread,
Jun 26, 2019, 1:12:21 AM6/26/19
to ns-3-users
U r right Tom. I had installed the suggested dependencies provided by NSAM and eventually, I can run the visualizer! 
NSAM guide >> https://www.nsnam.org/wiki/Installation

Josh LRT

unread,
Jun 26, 2019, 9:08:38 AM6/26/19
to ns-3-users
Another issue, when i run with simple ndn, it prompt the visualiser, can click simulation but when i go to the node, i couldn't right click to view CS / FIB / PIT .. etc 
Reply all
Reply to author
Forward
0 new messages