為什麼 pssh 命令不起作用?

為什麼 pssh 命令不起作用?

我在 Ubuntu 11.10 x64 系統中安裝了 pssh 軟體套件。我可以透過呼叫parallel-ssh來運行程式但是,pssh給了我

$ pssh
No command 'pssh' found, did you mean:
 Command 'bssh' from package 'avahi-ui-utils' (universe)
 Command 'cssh' from package 'clusterssh' (universe)
 Command 'ssh' from package 'openssh-client' (main)
 Command 'posh' from package 'posh' (universe)
 Command 'pdsh' from package 'pdsh' (universe)
 Command 'mssh' from package 'mssh' (universe)
 Command 'zssh' from package 'zssh' (universe)
 Command 'rssh' from package 'rssh' (universe)
 Command 'ppsh' from package 'ppsh' (universe)
 Command 'push' from package 'heimdal-clients' (universe)
pssh: command not found

為什麼會發生這種情況以及讓 pssh 命令正常工作的正確方法是什麼?

PS 我知道我可以創建一個名為 /usr/bin/pssh 鏈接到 /usr/bin/parallel-ssh 的鏈接,但這些對我來說似乎很髒。 :(

答案1

關於原因,請參閱/usr/share/doc/pssh/README.Debian。

To avoid any conflicts with the putty package, all of the programs have been
renamed.

parallel-ssh is pssh
parallel-scp is pscp
parallel-rsync is prsync
parallel-nuke is pnuke
parallel-slurp is pslurp

關於該符號鏈接,一個稍微乾淨的解決方案是創建 /usr/local/bin/pssh 符號鏈接並讓它指向 /usr/bin/parallel-ssh。除了 /usr/local/ 之外,通常最好將 /usr/ 的內容留給套件管理器。預設 /usr/local/bin 也是 PATH 環境的一部份。

答案2

嘗試parallel-ssh它已被重命名。

引自包裝說明:

 The package contains:
 .
  - Parallel ssh (parallel-ssh, upstream calls it pssh), executes commands on
    multiple hosts in parallel
  - Parallel scp (parallel-scp, upstream calls it pscp), copies files to
    multiple remote hosts in parallel
  - Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently
    copies files to multiple hosts in parallel
  - Parallel nuke (parallel-nuke, upstream calls it pnuke), kills processes on
    multiple remote hosts in parallel
  - Parallel slurp (parallel-slurp, upstream calls it pslurp), copies files
    from multiple remote hosts to a central host in parallel
 .
 These tools are good for controlling large collections of nodes, where faster
 alternatives such as gexec and pcp are not available.

答案3

有時,用於啟動程式的命令的名稱與您安裝的用於取得所述程式的軟體包的名稱不同。

我最近在安裝《Maze of Galious》來嘗試時發現了這一點,它沒有出現在遊戲菜單中,我花了幾分鐘才發現要啟動遊戲,我必須進入終端並輸入“貓'。 /軼事。

發生這種情況的原因有很多,也許名稱(就像我的軼事中那樣)太長,無法成為命令的合理名稱,也許開發人員想要的名稱已經被選擇,也許開發人員有腦蟲,只是想把它稱為完全隨機的東西來擾亂你——為什麼不值得擔心,如果你想「修復」它,只需使用別名或符號/硬連結。

如果它打擾你您可以向上游提交更改請求,但如果開發人員選擇該名稱,他/她可能有充分的理由。

相關內容