From mboxrd@z Thu Jan 1 00:00:00 1970 From: Roy Marples Date: Tue, 01 Aug 2006 13:56:49 +0000 Subject: Re: [PATCH] Only lookup uid/gid when applying rules Message-Id: <200608011456.49802.uberlord@gentoo.org> List-Id: References: <200608011135.25769.uberlord@gentoo.org> In-Reply-To: <200608011135.25769.uberlord@gentoo.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org On Tuesday 01 August 2006 14:12, Kay Sievers wrote: > How does that solve the problem, that you need to resolve a name when a > rule gets applied, but you will hang in getpwnam() cause of the system > config? > Such an array will only reduce the number of lookups for the _same_ > name, but not solve the problem, right? OK, it doesn't really solve the problem. The issue as I see it is that ever= y=20 user/group name is looked up for each rule before events are processed. This is bad for reasons explained earlier. So we need to lookup the user/group at rule application time. We can=20 optionally store it back in the rule or in an a id/name array. This solves the problem of a correctly configured LDAP server who does not = have the user/group "tss" in any nss DB and yet exists in a udev rule that = will never be applied. This does not solve the problem of a poorly configured LDAP/NIS/udev system= =20 where the user did not add tss to /etc/{passwd,group}, but the patch was no= t=20 expected to either ;) Thanks --=20 Roy Marples Gentoo/Linux Developer (baselayout, networking) ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=DEVD= EV _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel