[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#354401: Error "chown: `root:UNKNOWN': invalid group" when setting up tex-common



On 2006-02-27 02:56:37 +0100, Norbert Preining wrote:
> On Mon, 27 Feb 2006, Norbert Preining wrote:
> > > dixsept:~> echo ".$(/usr/bin/stat --format="%G" /var/cache/fonts)."
> > > .UNKNOWN.
> > 
> > Ahh, so I assume that /var/cache/fonts exists, but it is owned by a
> > group id NOT listed in /etc/groups, so stat cannot find it.

Note that this can happen when the group name is defined by NIS,
but when the upgrade occurs, the NIS client isn't running (though
the problem here occurred for another reason).

> I suggest the following fix to the tex-common config script:
> --- config.in   (Revision 949)
> +++ config.in   (Arbeitskopie)
> @@ -59,6 +59,10 @@
>    PERMS=$(stat --format="%a" /var/cache/fonts 2>/dev/null)
>    GROUP=$(stat --format="%G" /var/cache/fonts 2>/dev/null)
>  
> +  if [ "$GROUP" = "UNKNOWN" ] ; then
> +    GROUP=$(stat --format="%g" /var/cache/fonts 2>/dev/null)
> +  fi
> +
>    # see wether we already have asked this question once
>    db_fget tex-common/managecache seen || true
>    SEEN="$RET"
> 
> Ie if the group cannot be found, take instead the numeric id. The user
> can later change the group id to a group name, but if he wants to leave
> the group id as is, we do
> 	 chown "root:$GROUP"
> in the postinst script, which also works with numeric ids. So I would
> say that would be a solution.

I think this is OK.

BTW, when I wanted to fix the group name (gid) with
"dpkg-reconfigure tex-common", the BackSpace key (generating ^?)
didn't work to erase the value. I was connected via ssh. I suppose
this is a bug too.

-- 
Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
Work: CR INRIA - computer arithmetic / SPACES project at LORIA



Reply to: