Hello everyone,
I am trying to configure File Server Resource Manager via powershell. I am having problems creating a new File Screen Template with a command action. I would like the command to run a BAT file and pass the [Source Io Owner] variable as an argument to the BAT file. I have tried placing my BAT file in various locations due to the "0x80045317, The specified path is insecure" error but I also get a "0x8004530d, The specifiec property is out of range". I also get this error when I run the cmd.exe command and invoke my BAT file through arguments. I have researched this errors extensively and there is little to no details about what would be causing them online so I am turning to these discussions as a last resort. Here are the powershell commands I have tried and their results:
PS C:\Users\Administrator> $notification2 = new-fsrmaction command -Command "C:\gradea\crypto.bat" -CommandParameters "[
Source Io Owner]" -SecurityLevel LocalSystem -RunLimitInterval 1
PS C:\Users\Administrator> new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $Notification2
-Active:$false
new-fsrmfilescreentemplate : 0x80045317, The specified path is insecure.
At line:1 char:1
+ new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_FsrmFileScreenTemplate:Root/Microsoft/...eScreenTemplate) [New-FsrmF
ileScreenTemplate], CimException
+ FullyQualifiedErrorId : HRESULT 0x80045317,New-FsrmFileScreenTemplate
PS C:\Users\Administrator> $notification2 = new-fsrmaction command -Command "C:\crypto.bat" -CommandParameters "[Source
Io Owner]" -SecurityLevel LocalSystem -RunLimitInterval 1
PS C:\Users\Administrator> new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $Notification2
-Active:$false
new-fsrmfilescreentemplate : 0x8004530d, The specified property is out of range.
At line:1 char:1
+ new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_FsrmFileScreenTemplate:Root/Microsoft/...eScreenTemplate) [New-FsrmF
ileScreenTemplate], CimException
+ FullyQualifiedErrorId : HRESULT 0x8004530d,New-FsrmFileScreenTemplate
PS C:\Users\Administrator> $notification2 = new-fsrmaction command -Command "C:\temp\crypto.bat" -CommandParameters "[So
urce Io Owner]" -SecurityLevel LocalSystem -RunLimitInterval 1
PS C:\Users\Administrator> new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $Notification2
-Active:$false
new-fsrmfilescreentemplate : 0x80045317, The specified path is insecure.
At line:1 char:1
+ new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_FsrmFileScreenTemplate:Root/Microsoft/...eScreenTemplate) [New-FsrmF
ileScreenTemplate], CimException
+ FullyQualifiedErrorId : HRESULT 0x80045317,New-FsrmFileScreenTemplate
PS C:\Users\Administrator> $notification2 = new-fsrmaction command -Command "C:\WINDOWS\system32\cmd.exe" -CommandParame
ters "/c C:\gradea\crypto.bat [Source Io Owner]" -SecurityLevel LocalSystem -RunLimitInterval 1
PS C:\Users\Administrator> new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $Notification2
-Active:$false
new-fsrmfilescreentemplate : 0x8004530d, The specified property is out of range.
At line:1 char:1
+ new-fsrmfilescreentemplate -name "CRYPTO" -includegroup "CRYPTO" -Notification $ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_FsrmFileScreenTemplate:Root/Microsoft/...eScreenTemplate) [New-FsrmF
ileScreenTemplate], CimException
+ FullyQualifiedErrorId : HRESULT 0x8004530d,New-FsrmFileScreenTemplate
Does anyone have an idea why I get the 0x80045317 or 0x8004530d errors?
Thanks in advance,
Phil