From owner-freebsd-net@FreeBSD.ORG Sun Mar 15 23:49:21 2015 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id EABFAD4D for ; Sun, 15 Mar 2015 23:49:20 +0000 (UTC) Received: from mail-la0-f43.google.com (mail-la0-f43.google.com [209.85.215.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 6DB4D9AD for ; Sun, 15 Mar 2015 23:49:19 +0000 (UTC) Received: by lamx15 with SMTP id x15so26757551lam.3 for ; Sun, 15 Mar 2015 16:49:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:user-agent :in-reply-to:references:mime-version:content-transfer-encoding :content-type; bh=jWY27SPfe4psrcAar0Fer550FbyDkOOhYn+u8FBdWr4=; b=SVLwS1N8djl0OcXfy75wSt5XrgbNMeZZmc6R6/YqOixS6jofkc08yn2halVjX29LQh /rkSGzmF3oWUIs8XnlhAo8LNuQczw8bOrFpw53tVZn2/EHDXIRr68qJci0MgJ2lwgdQy 7q8jaU5qcEFxpxq9UEdNTiThzcZPluSnTpS50dBH82ck32NdmNR0N/w0o1V9pXS6G/e5 /1B0xsNZkgda2zVEih/TeO+otZm61S9xE9fMEp0ASpdBLWdcWh+k9E/VKj8QrP29mTLT 8fjlfYP+DbIXh3N79hz21Yg5XgaL0+0mhVu+krqzT3hJaxbP/NfyWZUa1A2kBu6GJU0h Q33g== X-Gm-Message-State: ALoCoQmp3XSbUZZ1Kk3ol+t3La5U4rlJlBePaDn0xebLHSprPc18kfoMWJBl31G1XFdzf35Geb5s X-Received: by 10.112.50.38 with SMTP id z6mr31487229lbn.122.1426463350615; Sun, 15 Mar 2015 16:49:10 -0700 (PDT) Received: from kde4.my.domain (pppoe.178-66-19-232.dynamic.avangarddsl.ru. [178.66.19.232]) by mx.google.com with ESMTPSA id n12sm1835786lbg.31.2015.03.15.16.49.09 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 15 Mar 2015 16:49:09 -0700 (PDT) From: Oleg Ginzburg To: Bryan Venteicher Subject: Re: SIOCSVH, SIOCGVH ioctl(2) and virtio ethernet driver Date: Mon, 16 Mar 2015 02:49:58 +0300 Message-ID: <3860521.yJlCc0OyhB@kde4.my.domain> User-Agent: KMail/4.14.2 (FreeBSD/11.0-CURRENT; KDE/4.14.2; amd64; ; ) In-Reply-To: References: <36413168.TE9MLvZCzL@kde4.my.domain> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: freebsd-net@freebsd.org X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Mar 2015 23:49:21 -0000 On Monday 29 December 2014 14:18:01 Bryan Venteicher wrote: > On Fri, Dec 26, 2014 at 8:09 AM, Oleg Ginzburg wrote: > > is it possible to use the carp(4) protocol with > > vtnet(4) interfaces ( which is used, for example, in bhyve(8) ) > > Currently, the standard carp init operation causes an SIOCGVH error: > > > > /sbin/ifconfig vtnet0 vhid 1 advskew 100 pass pass 10.10.10.10/24 alias > > ifconfig: SIOCGVH: Protocol not supported > > You probably don't have the carp(4) module loaded. Sorry for delay. Unfortunately the problem somewhere else. Depending on the FreeBSD revision there is a different behavior except usual. E.g: a) 10.1-RELEASE and 10-STABLE: % kldload carp % kldstat -m carp Id Refs Name 486 1 carp % /sbin/ifconfig vtnet0 vhid 1 advskew 100 pass navuhodonosor 192.168.1.210/24 state master alias ifconfig: SIOCSVH: Invalid argument b) On FreeBSD-current r276500M CARP IP is established for some seconds, then vanishes: % /sbin/ifconfig vtnet0 vhid 1 advskew 100 pass navuhodonosor 192.168.1.210/24 state master alias % ifconfig vtnet0 vtnet0: flags=8943 metric 0 mtu 1500 options=80028 ether 00:a0:98:d7:e3:65 inet 192.168.1.170 netmask 0xffffff00 broadcast 192.168.1.255 inet 192.168.1.210 netmask 0xffffff00 broadcast 192.168.1.255 vhid 1 nd6 options=29 media: Ethernet 10Gbase-T status: active carp: BACKUP vhid 1 advbase 1 advskew 100 % ifconfig vtnet0 vtnet0: flags=8943 metric 0 mtu 1500 options=80028 ether 00:a0:98:d7:e3:65 inet 192.168.1.170 netmask 0xffffff00 broadcast 192.168.1.255 nd6 options=29 media: Ethernet 10Gbase-T status: active % dmesg ... carp_alloc_if: ifpromisc(vtnet0) failed: 45 carp: VHID 1@vtnet0: INIT -> BACKUP carp: VHID 1@vtnet0: BACKUP -> MASTER (master down) ifa_del_loopback_route: deletion failed: 3 ifa_del_loopback_route: deletion failed: 3 And one more dmesg from the server with more fresher revision (r280012M): carp_alloc_if: ifpromisc(vtnet0) failed: 45 carp: 1@vtnet0: INIT -> BACKUP (initialization complete) carp: 1@vtnet0: BACKUP -> MASTER (master timed out) -- TOX ID: olevole@toxme.se (B4A584A75560D5A93DBF387FAAC56669DA18797078A46B9A9818726BEE643E52A43A6A2E3DA0) E-mail: olevole at olevole.ru XMPP/jabber: olevole at jabber.ru Voice: 199.48.133.74/1001 PGP public key: http://www.olevole.ru/olevole_pgpkey.asc