高TIME_WAIT并且无法从salt minion获得返回作业ID

时间:2016-10-07 10:54:28

标签: tcp ubuntu-14.04 salt-stack

关于salt master(Ubuntu 14.04):

# salt '*' test.ping or execute some state files,

我可以看到屏幕像下面的消息一样挂起,无法从小兵那里得到作业ID。

[DEBUG   ] Using cached minion ID from /etc/salt/minion_id: ranjith1.times.com
[DEBUG   ] Missing configuration file: /root/.saltrc
[DEBUG   ] MasterEvent PUB socket URI: /var/run/salt/master/master_event_pub.ipc
[DEBUG   ] MasterEvent PULL socket URI: /var/run/salt/master/master_event_pull.ipc
[DEBUG   ] Initializing new AsyncZeroMQReqChannel for ('/etc/salt/pki/master', 'ranjith1.times.com_master', 'tcp://192.168.233.3:4506', 'clear')
[DEBUG   ] Initializing new IPCClient for path: /var/run/salt/master/master_event_pub.ipc
[DEBUG   ] LazyLoaded local_cache.get_load
[DEBUG   ] Reading minion list from /var/cache/salt/master/jobs/58/763acd820353b8a744c7a7167c62f2/.minions.p
[DEBUG   ] get_iter_returns for jid 20161007154243656981 sent to set(['gr-test.foreman.in']) will timeout at 16:07:43.662608


# netstat shows,

Every 2.0s: netstat -antp | grep 4506

                                                                                                       Fri Oct  7 15:37:18 2016

tcp        0      0 192.168.233.3:4506      0.0.0.0:*               LISTEN      1591/python
tcp        0      0 192.168.233.3:34619     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34620     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34622     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34621     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34617     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34616     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34618     192.168.233.3:4506      TIME_WAIT   -
tcp        0      0 192.168.233.3:34623     192.168.233.3:4506      TIME_WAIT   -

更改了以下值:

# cat /proc/sys/net/ipv4/tcp_tw_recycle
0
# cat /proc/sys/net/ipv4/tcp_tw_reuse
0
# cat /proc/sys/net/ipv4/tcp_fin_timeout
60
# cat /proc/sys/net/ipv4/ip_local_port_range
32768   61000

为:

# cat /proc/sys/net/ipv4/ip_local_port_range
15000   65000
# cat /proc/sys/net/ipv4/tcp_fin_timeout
30

但是我仍然可以看到time_wait,请提示在服务器端(ubuntu)或salt-master配置中还需要做什么来缩短此问题。

0 个答案:

没有答案