Hello everybody!
I have experienced some troubles with the FSRM and customizing File Management Tasks under Windows Server 2012. I hope someone could assist me in this matter.
I found this Technet blog some time ago and my actions were based on it:http://blogs.technet.com/b/filecab/archive/2009/05/11/customizing-file-management-tasks.aspx
However, it doesn't want to work out quite how i want yet.
I would like to explain my situation first. We would like to archive our File Server, every file that hasn't been accessed for over 4 years should be moved to a different location. The folder structure as well as the permissions should be kept like they were on the file server (the only exception would be that write right on those files would/should be removed, because we don't want people to edit or delete archived files). We realized that this is not quite realizable with a normal file management task (with choosing "file expiration" in the action drop down). That's why we decided to make a script by ourselves and choose "customize" in the action drop down of the file management task in FSRM.
The problem we do have now is that the script doesn't get executed, we basically did the same thing like we were told to in that Technet blog without any success.
First of all we created an easy script in order to make sure our customized file management task works like it should. For that we just wanted to create a log file with the Source File Path of the work-related file, which is about to get archived in the task. The "%1" stands for the parameter [Source File Path]. The script looks like that:
echo %1 > C:\Users\Username\Desktop\log.txt
exit
I have attached a screenshot of the customized file management task as well:
Okay so far so good. If I run the file management task now, it somehow ends up in an endless loop, it doesn't do anything and it doesn't finish either. FSRM created a log file though. If I look at it I can see that every single file that matched the condition of last accessed 4 years ago, ended up in an error:
"Unable to run command: C:\Windows\System32\cmd.exe C:\Windows\System32\test.cmd [Source File Path]. 0x80045367, the file management action command timed out."
I have tried several ways of customizing the task already (absolute path, no absolute path, script file endings cmd or bat) nothing changed the result... Furthermore the script i am providing to test this customized task is fairly easy and working. So my assumption is that FSRM doesn't even execute the script?
I don't know where the error could be and i would really appreciate your help in form of troubleshooting or other suggestions/solutions how to achieve our goal.
Thank you!
Dario