Question

Free hd space by deleting useless files and folders like access log, error log and more

Hello wiich is the useless files and folders i can delete for free hd space? Thank you

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

This question was answered by @SphericalCow:

in general, i don’t recommend deleting the access nor error logs as they can helpful for troubleshooting issues. If they are several GB in size for some reason, then i suppose a case can be made to delete those files for some immediate free space.

Instead, I usually recommend using logrotate to keep the logs under control. A general tutorial on using logrotate for Apache is at this link

View the original comment