Usage disk and rosclean

Hi,
I met wih this warning in rosject:

WARNING: disk usage in log directory [/home/user/.ros/log] is over 1GB.
It's recommended that you use the 'rosclean' command.

what does this mean?

Hi @MeineLiebeAxt ,

Since you will not be using the logs generated by ROS, you can delete the logs.

Simply go inside /home/user/.ros/log and delete all the contents inside.

The logs will get regenerated upon a new project build catkin_make in ROS or colcon build in ROS2 and logs are saved when you run ROS programs.

You can delete them. It is safe to do so and will cause no harm!

EDIT: You can do rosclean purge to remove all the logs from that folder. This is just when you want to delete all logs. If you wish to keep a few then you must manually go into the folder and delete the ones you do not want.

Regards,
Girish

Thank you very much! That is very practival tip!

Hi
I met with a problem. I cannot catkin_make any new workspace any longer, every time it goes wrong. Both on webshell and my own linux. I can hardly imagine what is going wrong. The only strange thing I can remember is that I previously runned this “rosclean purge”. Please inform me whether it is really ok to do so? Now I cannot catkin_make even a new blank workspace…

Hi @MeineLiebeAxt ,

'rosclean purge` only removes log files. It does not delete any packages. I have done it and have had no issues.

Are you sure you have a src folder within the parent folder when you run catkin_make ?
Assuming your new workspace name is my_new_ws, you must create another folder inside called src.
Then you must cd to my_new_ws and then issue the catkin_make command to set this up as a new workspace.

Are you sure you did not accidentally delete your folders?

– Girish

Thank you, I think I found the stupid reason…
Due to that I installed anaconda on my own linux, when I catkin_make the working space, I should use this:

catkin_make -DPYTHON_EXECUTABLE=/usr/bin/python3

but not simply:

catkin_make

And I didn’t realize that the rosject I am doing now, which is rosject of the course “ROS Basics in 5 days”, has updated already. So maybe the catkin_make there is also no longer useful, which need do to be use the python3 version, such as the above.

@MeineLiebeAxt ,

Actually, installing Anaconda IDE will make changes to your .bashrc file and the environment.
Therefore, you were unable to perform catkin_make.
While installing Anaconda, if it asked you for conda init and you selected “yes”, then your python environment variables to start ROS will fail.
This is a known fact discussed in the ROS discourse.

http://wiki.ros.org/IDEs#Anaconda

– Girish