ROS Resources: Documentation | Support | Discussion Forum | Service Status | Q&A answers.ros.org
Ask Your Question
0

no nodes visible with roscore. A localhost problem?

asked 2015-03-06 11:05:34 -0500

nictosi8 gravatar image

updated 2015-03-10 06:43:46 -0500

Hi all, I have installed ROS Groovy on Ubuntu 12.04 .

I have done the tutorials using roscore and everything worked fine with the turtle example.

Then, I used roslaunch to launch a single RVIZ node and that worked.

The problem is now if do

[nt225917][i0009134-linux][~]# roscore
... logging to /home/nt225917/.ros/log/0c0b60a8-c421-11e4-9c85-001aa07b2128/roslaunch-i0009134-linux-5419.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://i0009134-linux:56914/
ros_comm version 1.9.55


SUMMARY
========

PARAMETERS
 * /rosdistro
 * /rosversion

NODES

auto-starting new master
process[master]: started with pid [5433]
ROS_MASTER_URI=http://i0009134-linux:11311/

setting /run_id to 0c0b60a8-c421-11e4-9c85-001aa07b2128

and

$ rosrun turtlesim turtlesim_node

Nothing happens, I can't stop roscore with CTRL + C and it seems that no node is loaded, not even /rosout.

[nt225917][i0009134-linux][~]# rosnode list

[nt225917][i0009134-linux][~]#

I reckoned this could be a hostname problem.

[nt225917][i0009134-linux][~]# cat /etc/hosts
127.0.0.1   localhost
127.0.1.1   i0009134-linux

# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
[nt225917][i0009134-linux][~]#

but setting i0009134-linux to 127.0.1.1 didn't solve the issue. Even with roslaunch I have the same issue. So basically it only worked once.

Any idea why this is happening?

I also tried to roslaunch without calling roscore in another shell. I used this simple example.launch

  <launch>
  <node name="talker" pkg="rospy_tutorials" type="talker" />
</launch>

and then:

    nt225917@i0009134-linux:~/Desktop$ roslaunch example.launch 
... logging to /home/nt225917/.ros/log/4e8145ac-c718-11e4-a96b-001aa07b2128/roslaunch-i0009134-linux-7368.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://localhost:56727/

SUMMARY
========

PARAMETERS
 * /rosdistro
 * /rosversion

NODES
  /
    talker (rospy_tutorials/talker)

auto-starting new master
process[master]: started with pid [7382]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to 4e8145ac-c718-11e4-a96b-001aa07b2128

But then again, the list of nodes seems to be empty, even though the talker node is shown in the roslaunch shell

nt225917@i0009134-linux:~/Desktop$ rosnode list

nt225917@i0009134-linux:~/Desktop$

Perhaps something is messed up with my environment variables?

nt225917@i0009134-linux:~/Desktop$ env |grep ROS
ROS_ROOT=/opt/ros/groovy/share/ros
ROS_PACKAGE_PATH=/home/nt225917/catkin_ws/src:/opt/ros/groovy/share:/opt/ros/groovy/stacks
ROS_MASTER_URI=http://localhost:11311
ROS_TEST_RESULTS_DIR=/home/nt225917/catkin_ws/build/test_results
ROS_HOSTNAME=localhost
ROSLISP_PACKAGE_DIRECTORIES=/home/nt225917/catkin_ws/devel/share/common-lisp
ROS_DISTRO=groovy
ROS_ETC_DIR=/opt/ros/groovy/etc/ros
edit retag flag offensive close merge delete

Comments

I noted the # in your shell. Are you running as root? Typically you do not run roscore/roslaunch etc. as root. Particularly some environment variables are usually not set for the user root....

Wolf gravatar imageWolf ( 2015-03-09 02:51:03 -0500 )edit
1

The # was just the result of a prompt title customisation in the ~/.bashrc . I run roscore as user nt225917

 nt225917@i0009134-linux:~$ whoami 
nt225917
nictosi8 gravatar imagenictosi8 ( 2015-03-10 05:22:44 -0500 )edit

3 Answers

Sort by ยป oldest newest most voted
0

answered 2015-03-07 14:37:39 -0500

ahendrix gravatar image

This _probably_ isn't an issue with your hostname.

The thing I find most strange is that the rosout node isn't starting as part of roscore. Is there more output when you run roscore which you haven't included in your question?

edit flag offensive delete link more

Comments

No, the only output I get is already in the question. On a side note, I can't stop roscore with CTRL + C .

nictosi8 gravatar imagenictosi8 ( 2015-03-10 05:25:45 -0500 )edit
0

answered 2015-03-12 09:47:36 -0500

nictosi8 gravatar image

Re-installing ROS solved the issue. I hopothesise this was caused by some env variable badly set.

I tested both reinstalling ros-groovy and ros-hydro.

edit flag offensive delete link more
-1

answered 2015-03-07 08:43:27 -0500

kramer gravatar image

updated 2015-03-07 08:45:59 -0500

Sort of, if my guess is correct. See this answer from @ahendrix.

Although that's specifically about all numeric hostnames...

edit flag offensive delete link more

Comments

That answer ONLY applies to all-numeric hostnames. This is a different issue.

ahendrix gravatar imageahendrix ( 2015-03-07 14:33:28 -0500 )edit

Thank you for the correction, I was hoping you'd see and confirm/deny my guess. Is it bad form to delete an incorrect answer?

kramer gravatar imagekramer ( 2015-03-08 09:41:39 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2015-03-06 10:59:41 -0500

Seen: 188 times

Last updated: Mar 12 '15