收到機房發來預警,就是說你的機器端口111開著,會引發Ddos攻擊啥的,安全起見還是禁用掉沒用的端口。
> Dear Sir or Madam,
>
> the Portmapper service (portmap, rpcbind) is required for mapping RPC
> requests to a network service. The Portmapper service is needed e.g.
> for mounting network shares using the Network File System (NFS).
> The Portmapper service runs on port 111 tcp/udp.
>
> In addition to being abused for DDoS reflection attacks, the
> Portmapper service can be used by attackers to obtain information
> on the target network like available RPC services or network shares.
>
> Over the past months, systems responding to Portmapper requests from
> anywhere on the Internet have been increasingly abused DDoS reflection
> attacks against third parties.
下面簡單記錄下禁用111端口過程。

1)、查看本機正在監聽的端口:
root@Proxmox-VE / # netstat -tlnup
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:8006 0.0.0.0:* LISTEN 1550/pveproxy
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 683/rpcbind
tcp 0 0 127.0.0.1:85 0.0.0.0:* LISTEN 1509/pvedaemon
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 4957/sshd
tcp 0 0 0.0.0.0:3128 0.0.0.0:* LISTEN 1582/spiceproxy
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1429/master
tcp6 0 0 :::111 :::* LISTEN 683/rpcbind
tcp6 0 0 :::22 :::* LISTEN 4957/sshd
tcp6 0 0 ::1:25 :::* LISTEN 1429/master
udp 0 0 0.0.0.0:111 0.0.0.0:* 683/rpcbind
udp 0 0 0.0.0.0:859 0.0.0.0:* 683/rpcbind
udp6 0 0 :::111 :::* 683/rpcbind
udp6 0 0 :::859 :::* 683/rpcbind
2)、查看正在監聽的111端口,由哪個服務使用
root@Proxmox-VE / # cat /etc/services | grep -w 111
sunrpc 111/tcp portmapper # RPC 4.0 portmapper
sunrpc 111/udp portmapper
3)、查看使用111端口服務的詳細狀態信息
root@Proxmox-VE / # systemctl list-unit-files --all |grep portmapper
root@Proxmox-VE / # systemctl list-unit-files --all |grep rpcbind
rpcbind.service enabled
rpcbind.socket enabled
rpcbind.target static
4)、關閉正在使用111端口的服務,并設置開機不啟動該服務
root@Proxmox-VE / # systemctl stop rpcbind.socket
root@Proxmox-VE / # systemctl disable rpcbind.socket
Removed /etc/systemd/system/sockets.target.wants/rpcbind.socket.

操作完畢后,再看看111端口禁用了
教程參考:https://www.wandouip.com/t5i283482/