2016-12-07 45 views
0

我有SLS文件设置为将事物从网络文件夹复制到本地目录。通过Salt Master使用ROBOCOPY

看起来有点像这样: CMD-测试: cmd.run: - 名称: 'ROBOCOPY \\\ CygwinSource C:\ CygwinSource/E'

,并得到下面的输出:

------------------------------------------------------------------------------- 
    ROBOCOPY  ::  Robust File Copy for Windows        
------------------------------------------------------------------------------- 

    Started : Tuesday, December 6, 2016 10:50:35 AM 
2016/12/06 10:50:35 ERROR 1808 (0x00000710) Getting File System Type of Source \\<Server>\<program>\<file>\ 
The account used is a computer account. Use your global user account or local user account to access this server. 


    Source - \\<Server>\<program>\<folder>\ 
    Dest : C:\<path>\<folder>\ 

    Files : *.* 

    Options : *.* /S /E /DCOPY:DA /COPY:DATS /PURGE /MIR /NP /R:1 /W:1 

------------------------------------------------------------------------------ 

NOTE : NTFS Security may not be copied - Source may not be NTFS. 

2016/12/06 10:50:35 ERROR 1808 (0x00000710) Accessing Source Directory \\<Server>\<program>\<file>\ 
The account used is a computer account. Use your global user account or local user account to access this server. 

Waiting 1 seconds... Retrying... 

当我在本地命令行中运行与'ROBOCOPY \\\ CygwinSource C:\ CygwinSource/E'相同的东西并且它完美运行时。我不知道如何解决Robocopy在盐中使用时出现的'使用本地用户帐户'。

我也尝试添加/ MIR和/ SEC哪些没有工作。

运行Windows 10,爪牙2016年3月3日 站长:红帽,2016年3月3日

回答

1

盐似乎连接到与计算机帐户的网络资源。一些可能的解决方案:

  1. 尝试更改客户端上的Salt服务(如果这是盐如何执行命令)作为域用户运行。
  2. 尝试使用盐,文件服务器
  3. 落实在其中创建计划任务本哈克的解决方法 - 在GitHub的问题是似乎与您问题相关讨论:https://github.com/saltstack/salt/issues/16340