Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fast-DDS Monitor did not pick the traffic data. #151

Open
iekhanx opened this issue Apr 20, 2022 · 11 comments
Open

Fast-DDS Monitor did not pick the traffic data. #151

iekhanx opened this issue Apr 20, 2022 · 11 comments
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@iekhanx
Copy link

iekhanx commented Apr 20, 2022

Hi forum,
I am trying to use Fast-DDS monitor to lay out latency graph and other useful options to check with current traffic over the network I configured the "fastdds-monitor" as follow:

export FASTDDS_STATISTICS="HISTORY_LATENCY_TOPIC;NETWORK_LATENCY_TOPIC;PUBLICATION_THROUGHPUT_TOPIC;
SUBSCRIPTION_THROUGHPUT_TOPIC;RTPS_SENT_TOPIC;RTPS_LOST_TOPIC;
HEARTBEAT_COUNT_TOPIC;ACKNACK_COUNT_TOPIC;NACKFRAG_COUNT_TOPIC;
GAP_COUNT_TOPIC;DATA_COUNT_TOPIC;RESENT_DATAS_TOPIC;SAMPLE_DATAS_TOPIC;
PDP_PACKETS_TOPIC;EDP_PACKETS_TOPIC;DISCOVERY_TOPIC;PHYSICAL_DATA_TOPIC"

When I try to run following syntax the app fails
./DDSHelloWorld publisher 0 500

Monitor_Did_NOT_record_data

$ ./DDSHelloWorld publisher
Starting
DDSHelloWorld DataWriter created.
DDSHelloWorld DataWriter waiting for DataReaders.
DataWriter matched.
DataWriter matched.
Auto Sent: Message ('q' quit)

NOW Subscriber:
export FASTDDS_STATISTICS="HISTORY_LATENCY_TOPIC;NETWORK_LATENCY_TOPIC;PUBLICATION_THROUGHPUT_TOPIC;
SUBSCRIPTION_THROUGHPUT_TOPIC;RTPS_SENT_TOPIC;RTPS_LOST_TOPIC;
HEARTBEAT_COUNT_TOPIC;ACKNACK_COUNT_TOPIC;NACKFRAG_COUNT_TOPIC;
GAP_COUNT_TOPIC;DATA_COUNT_TOPIC;RESENT_DATAS_TOPIC;SAMPLE_DATAS_TOPIC;
PDP_PACKETS_TOPIC;EDP_PACKETS_TOPIC;DISCOVERY_TOPIC;PHYSICAL_DATA_TOPIC"

./DDSHelloWorld subscriber

This program run without any issue.

But "fastdds-monitor" fail to gather data. Although messages are flowing across the two PC but not picked up by
"fastdds-monitor" program to plot a graph or make sensible conclusion.

IF you please shed some light on this issue will be much obliged and grateful
Thank you,
IK

@jparisu jparisu added bug Something isn't working documentation Improvements or additions to documentation labels Apr 21, 2022
@jparisu
Copy link
Contributor

jparisu commented Apr 21, 2022

Hi @iekhanx :

Your issue

Regarding the issue you are seeing in your execution, it is most likely that you have compiled Fast-DDS without statistics.
You should use the CMake option -DFASTDDS_STATISTICS=ON (check Fast-DDS documentation https://fast-dds.docs.eprosima.com/en/latest/fastdds/statistics/statistics.html) in order to Fast-DDS compile the statistics module.

I think we can agree there is a lack of information in the Fast-DDS-Monitor documentaiton. There is a warning in the main page: https://fast-dds-monitor.readthedocs.io/en/latest/rst/formalia/titlepage.html regarding this, but it is true that it should be explicitly explained in the installation.
Please, do not close this issue until we prepare a new PR to add it.

Fast DDS Suite

There is a new tool developed by our team that avoids you the installation phase, and allow to use all our products by docker. I am sure you would appreciate to avoid all the compilation steps. Just follow this documentation https://fast-dds.docs.eprosima.com/en/latest/docker/docker_demo/fast_dds_suite.html and download the docker image from our downloads page: https://www.eprosima.com/index.php/downloads-all
This image has Fast-DDS, Fast-DDS-Monitor, and DDS Router.

DDS Router

I see you are using the DDS Router. Just a couple of comments:

  • First, there is no need to pass the default configuration file as an argument. If you do not give a configuration file (with argument flag -c), it takes that file by default (so, you can skip the < DDS_ROUTER_CONFIGURATION.yaml part, that is actually not doing anything).
  • Be careful while routing the topics in the Router, as the Statistics topics could be filtered if you are using a custom allowlist.
  • (Just in case) The DDS Router is not necessary if you are communicating DDS entities in the same local network (LAN).

Custom support

As you are using many eProsima products, and it seems you are encounter some problems that are easily solved by a meeting or two, I suggest you to speak with our support team: support@eProsima.com in order to negotiate some possible contracts.
We would be happy to hear about your use case and to help you further in your project.

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

Hello jparisu
Quote " You should use the CMake option -DFASTDDS_STATISTICS=ON (check Fast-DDS documentation https://fast-dds.docs.eprosima.com/en/latest/fastdds/statistics/statistics.html) in order to Fast-DDS compile the statistics module."

I did NOT build FastDDS from the source I downloaded a tarr file untarred on my PC and using ./install.sh i installed. Hence, I assume it is build using above specified options?

PS: As i knew our Manager Mr. Rhys Jones is in touch with eProsima team and Maria mahler seems to knew him
I believe he is resuming on work on Monday at the office as main contact in Saab.

1 similar comment
@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

Hello jparisu
Quote " You should use the CMake option -DFASTDDS_STATISTICS=ON (check Fast-DDS documentation https://fast-dds.docs.eprosima.com/en/latest/fastdds/statistics/statistics.html) in order to Fast-DDS compile the statistics module."

I did NOT build FastDDS from the source I downloaded a tarr file untarred on my PC and using ./install.sh i installed. Hence, I assume it is build using above specified options?

PS: As i knew our Manager Mr. Rhys Jones is in touch with eProsima team and Maria mahler seems to knew him
I believe he is resuming on work on Monday at the office as main contact in Saab.

@jparisu
Copy link
Contributor

jparisu commented Apr 21, 2022

You are right, using the .tgz file from downloads installs by default Fast DDS without statistics.
I would suggest to use Docker instead.

However, if you want to use that .tgz package, you can manually change the install.sh file and add -DFASTDDS_STATISTICS=ON in the cmake line that compiles fastdds. This line must look like:
cmake -DCMAKE_PREFIX_PATH=/usr/local -DBUILD_SHARED_LIBS=$dyn_link -DFASTDDS_STATISTICS=ON ../../src/fastrtps

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

Well I guess all this privileged info coming out after installation completed and product is doing what its purpose to transmit the messages across which is doing?
It mean simply I have to restart all over again to cover for gathering statistics to rebuild the Fast-DDS from the scratch.
These instructions should be covered in the README.md file which come with?
There were files i.e optionparser.hpp missing in example (BOTH LINUX, WINDOW-10) from fastdds/example/C++/ directory and fastrtps.lib file is missing for MS WINDOW-10 build PROCESS to successfully build ALL the provided examples. The missing of these files from most recent download if you are still re-arranging entire structure of ".tgz" file then please include the missing files in the deploy-able(s), please:
1/ Although the optionparser.hpp and optionparser.h exists in the directoy of thirdparty/

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

1/ Althogh optionparser.hpp and optionparser.h these files exist in the build under thirdparty/ directory but their link is missing and build fails
2/ There were fastrtps-2.6.0.lib file exist but it did not allows to link with cmake process fail and subsequently MS visual studio fail too.
Please provide or give clue for 1/ how to connect optionparser.hpp to the project as my understanding is to modify CMakefile.txt but tried that

The missing fastrtps.lib is failing all the example from build.
Your valuable advise ...for.. waiting.
Thank you,
IK

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

HI jparisu,
followings are code snippet where needed to be patched the statistic info gather variable On?

if [ -d src/foonathan_memory_vendor ]; then
mkdir -p build/foonathan_memory_vendor
cd build/foonathan_memory_vendor
cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ ../../src/foonathan_memory_vendor
cmake --build . --target install
cd ../..
fi

for dyn_link in ON OFF
do
if [ -d src/fastcdr ]; then
mkdir -p build/fastcdr
cd build/fastcdr
cmake -DBUILD_SHARED_LIBS=$dyn_link ../../src/fastcdr
cmake --build . --target install
cd ../..
fi

mkdir -p build/fastrtps
cd build/fastrtps
**cmake -DCMAKE_PREFIX_PATH=/usr/local -DBUILD_SHARED_LIBS=$dyn_link ../../src/fastrtps -DFASTDDS_STATISTICS=ON**
cmake --build . --target install
cd ../..

# remove build directories
rm -rf build

done

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

HI jparisu,
Funny thing I noticed as you instructed to rebuild fastdds using statistic gather option, hence, I have to kill the running program 'fastdds' but the messages are still transmitted across the computers.

Then I killed DDS-Router program ddsrouter and to my surprise still messages transmission continues.

As I made this program at last weekend after watching one of your YouTub video to create a .idl file
hence, i created two char values and two long values embedding in the .idl file and using
fastddsgen --example DDSHelloWorld program it has created few cpp and hpp files which I build and start using
it looks though the single program DDSHelloWorld contain all the functionality needed to transmit messages over the Wired network it has failed to use wireless connection. So the question IS?
1/ Where to fit-in fastdds program?
2/ Where to use DDS-Router program?
3/ When DDSHelloWorld program created by fastddsgen utility to provide all the functionality for transmitting custom messages?
Cause I am not using Docker as special instruction to ME by my boss to use DDS-Router ONLY to demonstrate message transmit across the network.
Your elaboration ..please.
IK

@iekhanx
Copy link
Author

iekhanx commented Apr 21, 2022

HI jparisu,
Here is freshly build Fast-DDS program in action load at the UDPv4 at 127.0.0.1:14520 port address and running.
But still fastdds-monitor did NOT picking up the data over the network. Please advise?
IK
Monitor_Did_NOT_record_data_01

@iekhanx
Copy link
Author

iekhanx commented Apr 22, 2022

Following instruction from Fast-DDS-monitor running on Window-10 OS environment:
replacing export to become "set" and using rest of the string as it is create an error "file not found" under windows-10
only can be run
HelloWorldExample subscriber

So one can gather transmit statistics?
While following statement does not work under window-10 OS.

export FASTDDS_STATISTICS="HISTORY_LATENCY_TOPIC;NETWORK_LATENCY_TOPIC;PUBLICATION_THROUGHPUT_TOPIC;
SUBSCRIPTION_THROUGHPUT_TOPIC;RTPS_SENT_TOPIC;RTPS_LOST_TOPIC;
HEARTBEAT_COUNT_TOPIC;ACKNACK_COUNT_TOPIC;NACKFRAG_COUNT_TOPIC;
GAP_COUNT_TOPIC;DATA_COUNT_TOPIC;RESENT_DATAS_TOPIC;SAMPLE_DATAS_TOPIC;
PDP_PACKETS_TOPIC;EDP_PACKETS_TOPIC;DISCOVERY_TOPIC;PHYSICAL_DATA_TOPIC"

./build/fastrtps/examples/C++/DDS/HelloWorldExample/DDSHelloWorldExample subscriber

@zygfrydw
Copy link

I am trying to use Fast-DDS Monitor but I am having the same issue - the Fast-DDS Monitor does NOT show any traffic.

I have tried using Fast-DDS Monitor with ROS2 Humble with no success, hence I have tested an example docker (ubuntu-eprosima-dds-suite:v1.4.0) provided at LINK.

I have followed the tutorial (some path changes were required, as the docker structure seams to diverged in time).

Reproductions steps:

docker run -it --privileged -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix --name fastdds ubuntu-eprosima-dds-suite:v1.4.0
goToExamples
cd dds/HelloWorldExample/bin
./DDSHelloWorldExample publisher -s 0
docker exec -it fastdds bash
goToExamples
cd dds/HelloWorldExample/bin
./DDSHelloWorldExample subscriber
docker exec -it fastdds bash
fastdds_monitor

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants