signetlabdei / DESERT_Underwater

DESERT Underwater: an NS-Miracle extension to DEsign, Simulate, Emulate and Realize Test-beds for Underwater network protocols
http://desert-underwater.dei.unipd.it/
BSD 3-Clause "New" or "Revised" License
27 stars 21 forks source link

Error loading .so's when running samples (undefined symbol) #5

Closed thiagobew closed 1 year ago

thiagobew commented 1 year ago

I installed DESERT in development mode using the wizard provided. After successfully installing and executing the source command as instructed, I tried running some samples, but some .so's don't seem to be working/loaded correctly.

Example 1: "ns test_uwopticalbeampattern.tcl" at DESERT-3.3.0-src/samples/Channel/Optical, with output: couldn't load file "libuwstaticrouting.so": /home/thiagobew/DESERT_Underwater-master/DESERT_buildCopy_LOCAL/lib/libuwstaticrouting.so: undefined symbol: _ZTI10UWIPModule while executing "load libuwstaticrouting.so" (file "test_uwopticalbeampattern.tcl" line 75)

Example 2: "ns test_polling_backoff.tcl" at DESERT-3.3.0-src/samples/MAC, with output: couldn't load file "libUwmStd.so": /home/thiagobew/DESERT_Underwater-master/DESERT_buildCopy_LOCAL/lib/libUwmStd.so: undefined symbol: _ZN9MPhy_Bpsk7commandEiPKPKc while executing "load libUwmStd.so" (file "test_polling_backoff.tcl" line 82)

I'm using Ubuntu 22.04.1 and DESERT 3.3.0.

fedefava86 commented 1 year ago

Thanks @thiagobew ,

We are trying to reproduce the problem in our installations, with no luck. We will come back with some more details needed to find the root cause

obolo commented 1 year ago

Hello @thiagobew , thanks for reporting. Could you please provide pwd of the test_uwopticalbeampattern.tcl and the result of cat DESERT_buildCopy_LOCAL/environment, please? Thank you

thiagobew commented 1 year ago

"cat DESERT_buildCopy_LOCAL/environment" export PATH=/home/thiagobew/DESERT_Underwater-master/DESERT_buildCopy_LOCAL/bin:${PATH} export LD_LIBRARY_PATH=/home/thiagobew/DESERT_Underwater-master/DESERT_buildCopy_LOCAL/lib:${LD_LIBRARY_PATH}

"pwd" /home/thiagobew/DESERT_Underwater-master/DESERT_buildCopy_LOCAL/DESERT-3.3.0-src/samples/desert_samples/Channel/Optical

obolo commented 1 year ago

We are not able to reproduce your issue. What comes to my mind is that you may have ns2 install via apt-get install. If that's the case, please uninstall it, as our OS will find first the ns2 installed via Ubuntu repos, and then the DESERT one is ignored.

thiagobew commented 1 year ago

Yes, I did install ns2 before installing DESERT. After removing the Ubuntu one, I just had to reinstall DESERT and the samples ran as expected.

Thank you all for the help!