Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

There aren't any hard limits in ROS on the number of subscribers, but your operating system may have some limits that indirectly limit the number of publishers or subscribers. For example the maximum number of open file descriptors limits the number of open TCP connections that a process can have.

On most common versions of Ubuntu Linux, for example, the maximum number of open file descriptors is 1024. I suspect your subscriber is nowhere near this limit, but if gazebo is publishing and subscribing to many topics per uav, it may be close to this limit.

You should be able to find the PID (process ID) for gazebo through ps; something like ps a | grep gazebo will probably help. Once you have the process ID, you can show all of the open file descriptors for gazebo with lsof -P {PID} (where {PID} is the process ID for gazebo), or you can count the number of open file descriptors with lsof -p {PID} | wc -l.

There aren't any hard limits in ROS on the number of subscribers, but your operating system may have some limits that indirectly limit the number of publishers or subscribers. For example the maximum number of open file descriptors limits the number of open TCP connections that a process can have.

On most common versions of Ubuntu Linux, for example, the maximum number of open file descriptors is 1024. I suspect your subscriber is nowhere near this limit, but if gazebo is publishing and subscribing to many topics per uav, it may be close to this limit.

You should be able to find the PID (process ID) for gazebo through ps; something like ps a | grep gazebo will probably help. Once you have the process ID, you can show all of the open file descriptors for gazebo with lsof -P -p {PID} (where {PID} is the process ID for gazebo), or you can count the number of open file descriptors with lsof -p {PID} | wc -l.