Hi, Alan,

Thanks for the quick reply.

On Wed, Dec 09, 2009 at 05:43:50PM +0200, Alan McKinnon wrote:
> On Wednesday 09 December 2009 17:24:16 Alan Mackenzie wrote:
> > > My first thought as well... I'd guess, just at a glance, that sshd was
> > > started in the chroot, and that /mnt/gentoo/dev/ is bind mounted
> > > properly, but /mnt/gentoo/dev/pts/ isn't.

> > As said, I fixed the problem by mounting /dev with --rbind.  This
> > misunderstanding cost me, perhaps, 10 hours of my time.

> > I then reported my problem to the bug tracker, suggesting that the manual
> > should be amended to say "--rbind" here.

> > I really wish I hadn't bothered.  My attempt to contribute was brusquely
> > brushed aside by somebody who didn't even bother to thank me for my
> > trouble (I always thank people reporting bugs to my project), said that
> > he "couldn't reproduce [my] error", and asserted that sshd wasn't meant
> > to work in the chrooted environment (why on Earth not?), implying it was
> > my stupid fault for not following the manual rigidly and droidwise.  To
> > cap it all, he patronisingly referred me to the appropriate sections of
> > the fine manual (that's after my having reported how I'd already fixed
> > the problem for me).

> I can see his point of view, the chroot environment is something that
> exists only while doing the installation and as such is a temporary
> dodge so that you can do it. No binary distro runs sshd in the chroot
> it creates while performing the install either.

However, setting up /dev completely (with --rbind) costs nothing, adds
capability, and takes nothing away.

> The supported method is to ssh into the "LiveCD" environment then
> chroot from that shell. It's hard to imagine a scenario where you would
> have more than one user doing that at the same time, so why run sshd in
> the chroot at all?

If you run sshd in the bare installation (as suggested), the ssh client
has to update his ~/.ssh/known_hosts every time the system is booted
(what?  There are people who only boot it once before getting Gentoo
completely installed? ;-).  When sshd'ing from within the chrooted
environment, the ssh client has to add an entry to known_hosts just once,
and this entry will persist even when the embryonic gentoo has been fully
installed and configured.

More to the point, though, is that the manual doesn't explicitly state
that sshd must be started from outside the chroot.  It sort of implies
it, but doesn't emphasise it.  Reading the manual, it was clear to me
that it didn't matter (turns out I was wrong).  Also, people are going to
be running sshd on their own initiative, and it seems perverse knowingly
to leave a hindrance on one of the two ways they'll choose to do it.

This situation cost me around 10 hours of frustration.  Looks like I'll
not be the last victim.

> > See https://bugs.gentoo.org/show_bug.cgi?id=296073

> > Seems to me, reporting problems to Gentoo is a waste of time, at least
> > documentation problems.

> That is a classic case of applying a specific case to the general case.
> You had a problem with one specific dev regarding one specific bug
> relating to one specific piece of documentation. To then assert that
> contributing anything to any aspect of Gentoo documentation is
> pointless merely on the basis of one experience is disingenuous to say
> the least.

What you write is indeed true, but only up to a point.  I reported how
things "seem to me", and truly hope that my experience is not typical.
By contrast, the posters on gentoo-user, including yourself, have been
very helpful indeed.  Thank you!

> -- 
> alan dot mckinnon at gmail dot com

-- 
Alan Mackenzie (Nuremberg, Germany).

Reply via email to