我正在尝试使用批处理脚本来使用ninite和组策略注销脚本自动更新某些应用程序。
这是我的脚本:
echo Copying ninite mkdir C:\temp mkdir C:\temp\ninite echo STARTING robocopy /xo /"\filesever01\shared data\IT\SoftwareUpdate\/" \temp\ninite\ NiniteOne.exe echo installing Chrome and Skype... c:\temp\ninite\NiniteOne.exe /select Chrome Skype /cachepath "\\fileserver01\shared data\IT\SoftwareUpdate\NiniteCache" echo Installing Java and Reader without autoupdates... c:\temp\ninite\NiniteOne.exe /select Java Reader /disableautoupdate /cachepath "\\fileserver01\shared data\IT\SoftwareUpdate\NiniteCache" /silent report.txt
脚本在注销时运行失败。 我在login时运行它,并注意到它失败,因为ninite要求pipe理员权限,我假设它在注销失败,出于同样的原因。
有没有人有什么我应该做的build议? 对于我正在尝试做的事情来说,ninite是正确的工具吗? 批处理脚本是正确的path还是应该尝试使用PowerShell?
注销脚本以用户身份运行。 在任何明智的Windows环境中,用户都不应具有pipe理员权限,也不能安装软件。
您最好将软件安装在作为计算机(SYSTEM)运行的“启动”或“closures”脚本中。
我对Ninite并不熟悉,所以我不能说它是否可以在启动或closures脚本中工作,但是我可以说任何需要提升权限的问题都不会成为问题。