From owner-freebsd-current@FreeBSD.ORG Thu Feb 13 18:59:16 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9BEDA78D for ; Thu, 13 Feb 2014 18:59:16 +0000 (UTC) Received: from mail-ve0-x234.google.com (mail-ve0-x234.google.com [IPv6:2607:f8b0:400c:c01::234]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 59AC515F2 for ; Thu, 13 Feb 2014 18:59:16 +0000 (UTC) Received: by mail-ve0-f180.google.com with SMTP id db12so8720159veb.39 for ; Thu, 13 Feb 2014 10:59:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=hZ6rZJrd36JC5te9hqMvhqFI8qyMIddpqvAvti952A4=; b=ohiW1rLjJRRJeq/ldDJFKpk/DqMLwtrlDeswuAoYjCo4wK3Ckb5TzwZXnygDtbQjpg tldS8EQaGKVtZK3+TGkoSqjFMozZwN9iPe+8aime1ys2KPIEuTwPOFZSKyhXeCBmKWC6 pSGrQVVBhBXoLN1PSYRQXQmAt3OKJqIDzU5rD2Yfg4QQj221iBtyJv4xhUwt1K6DylSo UU4IndQtCUFG54hnSYFkIjPr223UAwLZ02DpJAlCHWnI0Sy7+9IMGWvJyZdh9PUF8f/v ja7fLvfvAqNkFjdudABGXB6LWVpx88QRLmt6H9w30l5mLnHJNxd+xWAN9xo1zk+R6tND kINw== MIME-Version: 1.0 X-Received: by 10.59.5.102 with SMTP id cl6mr483584ved.41.1392317954936; Thu, 13 Feb 2014 10:59:14 -0800 (PST) Received: by 10.220.11.130 with HTTP; Thu, 13 Feb 2014 10:59:14 -0800 (PST) Date: Thu, 13 Feb 2014 12:59:14 -0600 Message-ID: Subject: ezjails, systat -ifstat, and multiple network cards From: Preston Hagar To: freebsd-current@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.17 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Feb 2014 18:59:16 -0000 I have a server setup with FreeBSD-10.0-RELEASE. It has 3 Intel gigabit network cards in it, em0, em1, and em2. I have multiple ezjails setup that run various things. One jail, called db, runs a postgresql database. It was my intention to give it em0 all to itself. The other jails and host machine should be going through em2. em1 currently isn't being used. If I do an ifconfig, I see that em0 has the alias IP for my db jail and em2 has the alias IP for all other jails. All the jails respond to network traffic as expected and seemingly work fine. The weird thing is when I do a systat -ifstat from the host, it should essentially all traffic going through em0. Some of the jails that run off of em2 (as defined in their jail config files and seen in ifconfig) have large data transfers and/or are web servers with lots of photos. I have even tried to manually scp a large file out of a jail setup through em2 and the numbers don't seem to budge. If I do netstat -i -b -n -I and check em0 and em2, it seems to support the numbers shown by systat -ifstat. However, if I use trafshow or iftop (both of which require choosing one interface at a time), they both seem to indicate the traffic flowing through the interfaces as I would expect. So I was curious if anyone had seen something like this before or had any ideas of what is going on. I have net.fibs=2 set in /boot/loader.conf, but in all the jails I current have jail_name_fib="" as I haven't got around to fullying setting up fibs. Is that perhaps the issue? Is there any way to determine with certainty which jail is using which interface short of physically pulling a network cable and seeing what stops working? Here are the relevant lines from my db (the one that should be on em0) config: export jail_db_hostname="db" export jail_db_ip="em0|10.1.10.2" >From another jail on em2 called www: export jail_www_hostname="www" export jail_www_ip="em2|10.1.10.7" from ifconfig em0: flags=8843 metric 0 mtu 1500 options=4219b ether 08:60:6e:13:94:06 inet 10.1.1.4 netmask 0xffff0000 broadcast 10.1.255.255 inet6 fe80::a60:6eff:fe13:9406%em0 prefixlen 64 scopeid 0x1 inet 10.1.10.2 netmask 0xffffffff broadcast 10.1.10.2 nd6 options=29 media: Ethernet autoselect (1000baseT ) status: active em2: flags=8843 metric 0 mtu 1500 options=4219b ether 68:05:ca:13:74:2a inet 10.1.1.2 netmask 0xffff0000 broadcast 10.1.255.255 inet6 fe80::6a05:caff:fe13:742a%em2 prefixlen 64 scopeid 0x3 inet 10.1.10.3 netmask 0xffffffff broadcast 10.1.10.3 inet 10.1.10.1 netmask 0xffffffff broadcast 10.1.10.1 inet 10.1.10.8 netmask 0xffffffff broadcast 10.1.10.8 inet 10.1.10.10 netmask 0xffffffff broadcast 10.1.10.10 inet 10.1.10.4 netmask 0xffffffff broadcast 10.1.10.4 inet 10.1.10.9 netmask 0xffffffff broadcast 10.1.10.9 inet 10.1.10.7 netmask 0xffffffff broadcast 10.1.10.7 nd6 options=29 media: Ethernet autoselect (1000baseT ) status: active Let me know if any more detail would be helpful or if you have any ideas of things to check. Thanks, Preston