Exchange 2016 logging folder Huge

HI guys

I have an exchange server 2016 & its logging folder  is getting filled up very quickly & huge in space. Is there anyway to cleanup- automatically & is is safe to cleanup

Logging path

c:\program files\microsoft\exchange server\V15\Logging

P VStorage & Virtualization ConsultantAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

MASEE Solution Guide - Technical Dept HeadCommented:
-->Is there anyway to cleanup- automatically & is is safe to cleanup
Do not clean manually. There are scrips available for cleaning up.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
austin minorCommented:
Here's a good wiki article about Exchange logs:

Once try this script:

gci 'C:\Program Files\Microsoft\Exchange Server\V15\Logging', 'C:\inetpub\logs' -Directory | gci -Include '*.log','*.blg' -Recurse | ? LastWriteTime -lt (Get-Date).AddDays(-7) | Remove-Item
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

timgreen7077Exchange EngineerCommented:
See the link for the below script and you can run it via the powershell.

You can actually delete those files manually (not the folder), and it will not cause a problem, run the script will save you a ton of time.
Download the script and right click and select run with powershell, and thats it, you will watch as it deletes all those files. It can take a while if there is are alot of files so be patient it working.
P VStorage & Virtualization  ConsultantAuthor Commented:
Thanks guys for you comments,

 but is there a way to disable this logging... ?
timgreen7077Exchange EngineerCommented:
There is always a way but it will take modifying the config files on each folder and the next time you run a CU update on exchange it will be enabled again. Not worth the trouble. Just run that script and you will be good. You can set the script to run as a scheduled task but that i definitely the easiest thing to do. Disregard disabling them because they will be needed for troubleshooting if something ever happens.
AkhaterSolutions ArchitectCommented:
Don't disable logging. As per my previous comment schedule the maintenance. You never know when you are going to need the logs
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.