我可以列出我自己的计算机的共享没有问题:
gwmi Win32_Share
但是当我尝试
gwmi Win32_Share -computer myserver
myserver
运行 BusyBox 的 HP MediaVault mv2120在哪里。我得到回复:Get-WmiObject : The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
有没有办法做到这一点?
我可以列出我自己的计算机的共享没有问题:
gwmi Win32_Share
但是当我尝试
gwmi Win32_Share -computer myserver
myserver
运行 BusyBox 的 HP MediaVault mv2120在哪里。我得到回复:Get-WmiObject : The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
有没有办法做到这一点?
WMI 中的“W”代表“Windows”,虽然 SAMBA 在让服务器消息块 (SMB) 工作方面做得还不错,但它并没有在 Linux 上实现 WMI。不幸的是,接口/协议不同。
如果您想从 Windows 中查看 SAMBA 共享,请使用 NET VIEW \\1.2.3.4 其中 1.2.3.4 是您的 Unix 机器的 IP。
没有。有一个可用于 Linux 的 wmiclient 软件包。使用它我们可以从 Linux 通信 Windows。
RPC 服务器不可用:我们必须在 Windows 机器上启动 RPC 相关服务和 WMI 服务。
答案是否定的——Linux 没有 WMI 服务。
Get-WMIObject 仅适用于 Windows 系统(直到 Linux 社区中的某个人实现 WMI!)