On Sun, Jun 19, 2011 at 06:42:34PM +0200, Jim Meyering wrote:
Richard W.M. Jones wrote:
> Anyone seeing this error? Unless I boot with enforcing=0, I see
> this error when I try to log in as any user:
>
> Unable to get valid context for <username>
>
> It seems like it's just started happening, since I upgraded something
> within the last 1-2 weeks.
Hi Rich,
I'm using 3.0-0.rc3.git5.1.fc16.x86_64 in enforcing mode (of course ;-)
and don't see any problem when logging in via ssh:
h$ ssh r date
Sun Jun 19 18:34:32 CEST 2011
h$ ssh r
Last login: Sun Jun 19 18:33:11 2011 from 192.168.122.1
r$ :
Everything is up to date, at least wrt whatever mirror I'm using.
My shell on that system is zsh; but I got the same result when
temporarily switching it to bash.
I was still seeing it, even after just updating everything and
rebooting the VM:
$ ssh 192.168.122.151
Unable to get valid context for rjones
Last login: Sun Jun 19 17:46:29 2011 from 192.168.122.1
Connection to 192.168.122.151 closed.
However I then touched /.autorelabel using guestfish:
# guestfish -i --rw -d FedoraRawhidex64 touch /.autorelabel
(it turns out I've written about this before, but had forgotten, see
https://rwmj.wordpress.com/2010/01/06/tip-autorelabel-a-vm/).
And that fixed it! However I don't know why ...
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
libguestfs lets you edit virtual machines. Supports shell scripting,
bindings from many languages.
http://libguestfs.org