我在RHEL5服务器上运行Varnish 3.x。 开始清漆后, ps ax |grep varnish得到:
[root@ip-... ec2-user]# ps ax |grep varnish 2747 ? Ss 0:00 /usr/sbin/varnishd -P /var/run/varnish.pid -a :80 -T localhost:6082 -f /etc/varnish/idea-int.vcl -u varnish -g varnish 2748 ? Sl 0:00 /usr/sbin/varnishd -P /var/run/varnish.pid -a :80 -T localhost:6082 -f /etc/varnish/idea-int.vcl -u varnish -g varnish
和/var/run/varnish.pid显示2747。
这是正常的吗?
是的,这很正常。 一个处理正常的连接,另一个处理pipe理员。
您可以使用netstat来检查哪个是哪个:
# netstat -ntlp | grep varnish tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 8935/varnishd tcp 0 0 127.0.0.1:6082 0.0.0.0:* LISTEN 8934/varnishd
正如你所看到的,绑定到回送接口上的pipe理端口(6082),而另一个绑定到主端口(在我的情况下,在大多数情况下80)。