LoginSignup
3
2

More than 3 years have passed since last update.

roscoreが正常に起動しない

Last updated at Posted at 2019-05-25

とても久しぶりにROSを起動しようとしてroscoreをコマンドを打ったら

... logging to /home/reo/.ros/log/a097bcd8-7ef5-11e9-8bc6-d47bb04d8ebf/roslaunch-reo-FMVWWA27B-23664.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.

Unable to contact my own server at [http://192.168.1.38:45611/].
This usually means that the network is not configured properly.

A common cause is that the machine cannot ping itself.  Please check
for errors by running:

    ping 192.168.1.38

For more tips, please see

    http://www.ros.org/wiki/ROS/NetworkSetup

The traceback for the exception was written to the log file

とエラーが出てしまった.

解決法としては

.bashrcにある

export ROS_MASTER_URI=http://192.168.1.34:11311
export ROS_HOSTNAME=192.168.1.38

を変えてやれば良い.

特に別のPCとROSで通信することが無いなら

export ROS_MASTER_URI=http://localhost:11311
export ROS_HOSTNAME=localhost

とすれば良い.

通信するなら

export ROS_MASTER_URI=http://192.168.122.105:11311    (192.168.122.105はマスタのipアドレス)
export ROS_HOSTNAME=192.168.122.100   (192.168.122.100は自分のipアドレス)

自分のipアドレスは
ifconfig
コマンドで調べるべし.

3
2
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
2