在没有交互式会话的情况下在远程 Unix 机器上运行命令

Ric*_*ins 3 unix

如何在不启动交互式会话的情况下在远程 Unix 机器上运行命令?

neu*_*242 7

只需使用 ssh:

ssh yourusername@yourserver.com "ls -l"
Run Code Online (Sandbox Code Playgroud)