(22)
前提: 接続先に鍵登録済
sudo apt -y install pdsh
pdsh -L
export PDSH_RCMD_TYPE='ssh'
pdsh -w 192.168.137.182,192.168.137.169 'id;uname -n'
pdsh -w 192.168.137.[182,169] 'id;uname -n'
pdsh -w 192.168.137.[182,169] 'id;uname -n' | dshbak -c
(12)
前提: 接続先に鍵登録済
apt -y install pdsh
pdsh -L
export PDSH_RCMD_TYPE='ssh'
pdsh -w 192.168.137.180,192.168.137.187 'id;uname -n;cat /etc/os-release'
pdsh -w 192.168.137.18[0,7] 'id;uname -n;cat /etc/os-release'
pdsh -w 192.168.137.18[0,7] 'id;uname -n;cat /etc/os-release' | dshbak -c
(RL9)
https://zoo200.net/linux-command-pdsh-pdcp/
前提: 接続先に鍵登録済
dnf -y install epel-release
dnf search pdsh
dnf -y install pdsh pdsh-rcmd-ssh
pdsh -L
export PDSH_RCMD_TYPE='ssh'
pdsh -w 192.168.137.191,192.168.137.192 'id;uname -n'
pdsh -w 192.168.137.19[1-2] 'id;uname -n'
pdsh -w 192.168.137.19[1-2] 'id;uname -n' | dshbak -c
- Windows Server
(2022)
前提:
-- 接続される側
管理者権限でPowerShellを開く
Enable-PSRemoting
New-PSSession
-- 接続する側
管理者権限でPowerShellを開く
net start WinRM
Set-Item WSMan:\localhost\Client\TrustedHosts -Value "192.168.137.62,192.168.137.63"
Invoke-Command -ComputerName 192.168.137.62,192.168.137.63 -ScriptBlock {whoami;ipconfig}