Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

My Microsoft Exchange 2010 installation server suffers from disk space absence sometimes. To work around this problem I usually just go ahead and remove log files on my mailbox folder.

I have to do it every 3 months. Is it possible to set up a recurring task in Windows Server, so that it would check the size of the mailbox folder, and if it exceeds, for example 4 GB, remove all the log files?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Ye, and it is trivial (beginner sysadmin level). Sionce quite some time Windows Server has a task scheduler that can start any program or script locally. Create script, create task to run script regularly, finished.

OR, if you are aa little more professional: Use your System Center Operations Module to run a regular mainteannce script on the machine.

share|improve this answer
    
Thanks TomTom. A script like PowerShell script? –  Maxim V. Pavlov Feb 13 '12 at 12:16
    
For example. I actually would use powershell these days ;) Frist I would write a sciptr to manually execute, then automate the execution - but I would use system center. I do not like to track dozens of scripts on different machines. –  TomTom Feb 13 '12 at 12:19
    
For me, being a .net developer, it turns out to be easier to just write an executable that does all the work based on a logic, then to learn an debug the PS script =) –  Maxim V. Pavlov Feb 13 '12 at 13:26
    
Same here, but then I would rather write a scriopt. It IS the new world of Powershell and I move to wards maykin my software usabble via powershell anyway. –  TomTom Feb 13 '12 at 13:27
    
Yes, good point! PowerGUI tools makes writing scripts much easier, from what I can tell now. –  Maxim V. Pavlov Feb 13 '12 at 13:39

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.