Pseudo-terminal will not be allocated because stdin is not a terminal.和Unable to get valid context for root
Pseudo-terminal will not be allocated because stdin is not a terminal.
通过这种方式执行command的时候:
ssh user@server <<eeooff
command
eeooff
会报error: Pseudo-terminal will not be allocated because stdin is not a terminal.
解决办法:
加参数:-T
ssh -T user@server <<eeooff
command
eeooff
Unable to get valid context for root
selinux设置selinuxtype错误导致的问题。

浙公网安备 33010602011771号