Running ROS as a root user
Hi All,
Some of my ROS nodes need to be run as a root user. I can do this by "sudo su" under Ubuntu and "source" setup.bash. My programs seem to be running correctly. An annoying issue is that, when I try to use "tab completion" to complete the package name in the terminal (e.g., rosrun package_name executable_name), I got some warnings as follows:
[rospack] WARNING: cannot create rospack cache directory: Permission denied
[rospack] WARNING: cannot create rospack cache directory: Permission denied
[rospack] Unable to create temporary cache file /root/.ros/.rospack_cache.bGXJPX: Permission denied
I have done this: chmod -R a+rwx /root/.ros/
, but above warnings still come out.
Any suggestion for solving this problem is appreciated.