From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ulf Kreutzberg Subject: Re: [Xen-users] Problemi using vif-route script Date: Mon, 28 Jan 2013 14:45:10 +0100 Message-ID: <510680E6.6050406@hosteurope.de> References: <20121026072821.GA9853@intersect> <1351237241.8558.9.camel@dagon.hellion.org.uk> <20121026121544.GA14662@intersect> <1351255054.15162.66.camel@zakaz.uk.xensource.com> <20121026170920.GA4835@intersect> <1351276218.11876.0.camel@dagon.hellion.org.uk> <51015DB8.40107@hosteurope.de> <1359105618.32057.58.camel@zakaz.uk.xensource.com> <51028DDE.9070907@citrix.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5334991507674247958==" Return-path: In-Reply-To: <51028DDE.9070907@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: =?UTF-8?B?Um9nZXIgUGF1IE1vbm7DqQ==?= Cc: "xen-users@lists.xen.org" , Ian Campbell , xen-devel List-Id: xen-devel@lists.xenproject.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --===============5334991507674247958== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="----enig2RGHMGKVDUPRPOVCDKUGG" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2RGHMGKVDUPRPOVCDKUGG Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Roger - >>> 2) from domU config: >>> vif =3D [ 'mac=3Dde:ad:a:1e:42:3,ip=3D10.3.2.3', >>> 'mac=3Dba:cc:7f:0:4:1,bridge=3Dbackupbr0,script=3Dvif-bridge'= ] >>> >>> The IP is not parsed so the ${ip} variable in the xen scripts is empt= y. >> >> ip should be parsed and written to xenstore -- do you see it there >> = (in >> the backend dir)? I can see the code which reads it in the hotplug >> script. > > I've tried this config and ip is written to xenstore: > > /local/domain/0/backend/vif/6/0/ip =3D "192.168.1.230" (n0,r6) > I think I could track down the issue: The mac address is not parsed correctly if not padded with leading zeros (and no error reported, though): Using the example above which worked perfectly with the old xm, xl create -n test.domU =3D=3D=3D=3D =2E..shortened output... "nics": [ { ... "mac": "de:ad:0a:0e:02:00", "ip": null, "bridge": null, "ifname": null, ... }, { ... "mac": "ba:cc:7f:00:00:0b", "ip": null, "bridge": null, "ifname": null, ... } ] =3D=3D=3D=3D=3D If I use padded bytes, vif =3D [ 'mac=3Dde:ad:0a:1e:42:03, ip=3D10.3.2.3', 'mac=3Dba:cc:7f:00:04:01,bridge=3Dbackupbr0,script=3Dvif-bridge']= it creates correctly =3D=3D=3D=3D=3D "nics": [ { ... "mac": "de:ad:0a:1e:42:03", "ip": "10.3.2.3", "bridge": null, "ifname": null, ... }, { ... "mac": "ba:cc:7f:00:04:01", "ip": null, "bridge": "backupbr0", "ifname": null, ... } ] =3D=3D=3D=3D=3D which is totally ok for me. Routes are set and the IP of the routed vif shows up in xenstore. Many thanks and best regards, Ulf ------enig2RGHMGKVDUPRPOVCDKUGG Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iEYEARECAAYFAlEGgOkACgkQhHSVerqjg064ggCgiWVGkDf5pBvNvSemT2BcP9fw 2gQAoIuFID12nkmLInsKmVWjCKGVIHvM =3+TR -----END PGP SIGNATURE----- ------enig2RGHMGKVDUPRPOVCDKUGG-- --===============5334991507674247958== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============5334991507674247958==--