2017年9月7日星期四

Poisoning caused SSH service run exception, the following error:fatal: mm_request_send: write: Broken pipe

DEDICATED SERVER


US DEDICATED SERVERS


The article's configuration and instructions have been tested in the CentOS 6.5 64-bit operating system. Other types and versions of the operating system configuration may vary, the specific circumstances, please refer to the appropriate operating system official documents.



Problem Description
Connect to the cloud server ECS (Elastic Compute Server) Linux server, the command line or the secure log appears with an error message similar to the following:

fatal: mm_request_send: write: Broken pipe.
Connection closed by 192.168.0.1.


Problem causes:The problem may be due to udev-fall and other viruses affect the normal operation of the SSH service.
Approach:To solve this problem, it is recommended that you deal with the following:

Temporary recovery - Reliable approach - temporary recovery

To udev-fall virus, for example, you can try the following way, the temporary resumption of the normal operation of SSH services:

Through the management terminal into the system.

Use the following command to query the virus process:
ps aux | grep udev-fall
root     24486  0.0  0.0 108340  1848 pts/0    S    10:30   0:00 /usr/bin/udev-fall

Description: The number in the second column indicates the process ID (PID).

Use the following command to end the virus process: kill -9 <process corresponds to PID>

Such as:
kill -9 24486

Use the following command to cancel the automatic operation of the virus service:
chkconfig udev-fall off

Use the following command to remove virus program-related instructions and self-starting configuration:
rm -rf /usr/bin/udev-fall
rm -rf /etc/init.d/udev-fall


Use the following command to restart the SSH service and then try to reconnect from the client:
service sshd restart


Reliable approach

Because it can not clear the virus or malicious intruders, whether the system has done other tampering, or hide other virus files. Therefore, for the long-term stability of the server to run, it is recommended by rolling back the system disk historical snapshot of the way, to restore the server to the normal state.


The cloud server ECS CentOS 7 restarts the sshd service operation method

DEDICATED SERVER

US DEDICATED SERVERS


In the cloud server ECS Linux CentOS 7 restart service is no longer through the service operation, but through the systemctl operation.

The operating instructions are as follows:

1. Check whether the sshd service starts:

systemctl status sshd.service
2. If you do not start, you need to start the service:

systemctl start sshd.service
3. Restart the sshd service:

systemctl restart sshd.service
4. Set the service to open from:

systemctl enable sshd.service