我有以下输出lsof -i:portnumber
[ztao@MongoDB ~]$ lsof -i:6379
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
redis-ser 5341 ztao 4u IPv6 23457 0t0 TCP *:6379 (LISTEN)
redis-ser 5341 ztao 5u IPv4 23459 0t0 TCP *:6379 (LISTEN)
redis-ser 5341 ztao 6u IPv4 23533 0t0 TCP localhost:6379->localhost:6633 (ESTABLISHED)
redis-ser 5341 ztao 7u IPv4 23535 0t0 TCP localhost:6379->localhost:6634 (ESTABLISHED)
redis-ser 5341 ztao 8u IPv4 23538 0t0 TCP localhost:6379->localhost:6635 (ESTABLISHED)
redis-ser 5341 ztao 9u IPv4 23540 0t0 TCP localhost:6379->localhost:6636 (ESTABLISHED)
redis-ser 5341 ztao 10u IPv4 23839 0t0 TCP localhost:6379->localhost:6747 (ESTABLISHED)
redis-ser 5341 ztao 11u IPv4 23842 0t0 TCP localhost:6379->localhost:6748 (ESTABLISHED)
newsProvi 5349 ztao 6u IPv4 23530 0t0 TCP localhost:6633->localhost:6379 (ESTABLISHED)
newsProvi 5349 ztao 7u IPv4 23532 0t0 TCP localhost:6634->localhost:6379 (ESTABLISHED)
newsProvi 5349 ztao 8u IPv4 23536 0t0 TCP localhost:6635->localhost:6379 (ESTABLISHED)
newsProvi 5349 ztao 9u IPv4 23539 0t0 TCP localhost:6636->localhost:6379 (ESTABLISHED)
newsDistr 5456 ztao 12u IPv4 23838 0t0 TCP localhost:6747->localhost:6379 (ESTABLISHED)
newsDistr 5456 ztao 13u IPv4 23841 0t0 TCP localhost:6748->localhost:6379 (ESTABLISHED)
我很难理解是什么
localhost:6379->localhost:6633 (ESTABLISHED)
意思。我试图搜索但找不到答案。这一定是一些非常基础的知识,但我是新手,我不知道。有什么帮助吗?
localhost:6379->localhost:6633 (ESTABLISHED)
表示在localhost
的端口 6379 和 6633 之间建立了连接。(“已建立”是TCP/IP 状态机中的一个状态;其他协议也有类似的状态。)箭头不代表通信的方向;它反映了港口的所有权。箭头左侧是属于列出的进程(Redis)的端口,箭头右侧是属于连接远程端的端口。
由于连接的两端都是本地的,所以可以看到连接的另一端: