Solve ssh error: shell request failed on channel 0

Problem: When building Jenkins task, it was found that the target host could not be connected. After manually executing SSH command on the command line, an error was reported: Shell Request failed on channel 0
Cause: The number of system processes on the target host is too small to connect
Solution: need to modify the/etc/security/limits. D/20 – nproc. The values in the conf file, change the 4096 older, such as 65535

[zhangsan@note1 /]$ cat /etc/security/limits.d/20-nproc.conf

*          soft    nproc     4096
root       soft    nproc     unlimited

Re-ssh, and you are done.
 

Read More: