From owner-freebsd-arch@FreeBSD.ORG Mon Mar 30 15:41:58 2009 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0F31E1065687 for ; Mon, 30 Mar 2009 15:41:58 +0000 (UTC) (envelope-from rpaulo@gmail.com) Received: from ey-out-2122.google.com (ey-out-2122.google.com [74.125.78.25]) by mx1.freebsd.org (Postfix) with ESMTP id 848898FC1B for ; Mon, 30 Mar 2009 15:41:57 +0000 (UTC) (envelope-from rpaulo@gmail.com) Received: by ey-out-2122.google.com with SMTP id 4so415939eyf.7 for ; Mon, 30 Mar 2009 08:41:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:cc:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:mime-version :subject:date:references:x-pgp-agent:x-mailer; bh=2Bpp0ZQaoj9GOEvjskAo4RK5Y3RdLkO3uxM8yoNA1aA=; b=cWToYe3C17XPYoveYIz6eaJ2NgoEpZ5ARUc8Ib7RvOjQ4fJppeNWMAo6VzT2I8cV6Y NjJUgGBEPkzPTNKvM+w0T0IxBgA344CCbgDICBM1PoKdn3859+s5+z1TZy2+sG4JLsby oYMkDxb8InlwU4lRjaSTgO8TfR/PqFDuq6bnc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-pgp-agent:x-mailer; b=TDu8fuqHyIFr+ZlMJKVqkGpT+lNiHu7Obf7TLfLc38mvzLdk9Z7uXyFvOvZKwtI7ZT fcSMGhAWyCBWXaYdsmjc8gLg2ymgXp2AQJcnSDuIQWVIS7brCyG0oA1OHHwwRY5tnIvS xufMHSGA5DLCMlh+6vgUS1PnOPQn3tFNOJwg8= Received: by 10.216.18.212 with SMTP id l62mr1691999wel.76.1238426058722; Mon, 30 Mar 2009 08:14:18 -0700 (PDT) Received: from epsilon.lan (bl5-225-84.dsl.telepac.pt [82.154.225.84]) by mx.google.com with ESMTPS id u14sm8632189gvf.31.2009.03.30.08.14.17 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 30 Mar 2009 08:14:18 -0700 (PDT) Sender: Rui Paulo Message-Id: <3E2EA002-4C26-4D44-ACEE-AD0F782F268E@freebsd.org> From: Rui Paulo To: Rick Macklem In-Reply-To: Content-Type: multipart/signed; protocol="application/pgp-signature"; micalg=pgp-sha1; boundary="Apple-Mail-2-273330164" Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v930.3) Date: Mon, 30 Mar 2009 16:14:11 +0100 References: X-Pgp-Agent: GPGMail 1.2.0 (v56) X-Mailer: Apple Mail (2.930.3) Cc: freebsd-arch@freebsd.org Subject: Re: Unique machine identifier for nfsv4 client X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Mar 2009 15:42:00 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --Apple-Mail-2-273330164 Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit On 30 Mar 2009, at 16:09, Rick Macklem wrote: > An nfsv4 client needs a unique identifier that is persistent across > reboots. My code currently uses the MAC address of the first net > interface that it can find that has an Ethernet style MAC. > > There are two problems with this: > 1 - If it can't find a net interface with a MAC, it falls back on a > randomly generated identifier, which changes when it is rebooted. > 2 - The code that finds the MAC breaks layering (ie knows stuff about > the network code like struct ifnet) and only builds if > "options VIMAGE_GLOBALS" is set. This doesn't answer the question, but have you thought about the possibility of the using the UUID that the system provides? A lot of new machines come with UUIDs. -- Rui Paulo --Apple-Mail-2-273330164 content-type: application/pgp-signature; x-mac-type=70674453; name=PGP.sig content-description: This is a digitally signed message part content-disposition: inline; filename=PGP.sig content-transfer-encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Darwin) iEYEARECAAYFAknQ4cMACgkQfD8M/ASTygKW8wCgvZ5+kgElJgiAONT1TvAwIoaT tVIAn1ffeuex8Jb1xMdw9G5+Qb8Bko+D =hT3V -----END PGP SIGNATURE----- --Apple-Mail-2-273330164--