Subject: Re: Q: Blind installation on DEC 3000 m300
To: Aaron J. Grier <agrier@poofygoof.com>
From: Christian Lavoie <christian.lavoie@mail.mcgill.ca>
List: netbsd-users
Date: 03/12/2002 15:13:29
The short story:

1) I cannot use sysconfig, I need to do it all manually. What has to be done? 
(Available tools: A text editor.)

2) I need to add a user manually to a system. All I have access to is a text 
editor. Not a fully working NetBSD system, just a linux nfs-server that hosts 
the root for a diskless NetBSD, and I need to add a user on that NetBSD 
system -- that NetBSD system is diskless, keyboardless and partially 
monitorless.

On Thursday 07 March 2002 01:02, Aaron J. Grier wrote:
> On Thu, Feb 28, 2002 at 08:13:43PM -0500, Christian Lavoie wrote:
> > The configuration files (/etc) are available on another UNIX system. I
> > can edit them right now. Why am I restricted to doing that from the
> > working NetBSD install? It magically patches the running kernel?
> >
> > Wait... This is supposed to be a diskless client (the disks are pretty
> > much reserved for databases) I hope there's nothing fundamentally
> > opposing getting the configuration from the NFS server, right? Once
> > that's done, all I need to do is change a couple of text files that
> > physically reside on a machine that's already fully working, so I can
> > edit them. Right?
>
> ahh... I didn't catch that it was a diskless NFS root machine.  yeah,
> you should just be able to tweak /etc/rc.conf to start sshd and
> configure networking by putting the proper values in a few files in
> /etc.

Ok, so here's the current setup: I still can't get anything to work. Sortof. 
=)

1) If I let it boot with rc.conf as: [comments striped for brievity]

if [ -r /etc/defaults/rc.conf ]; then
	. /etc/defaults/rc.conf
fi

rc_configured=YES

hostname="baldur.christianlavoie.net"
nfs_client=YES
defaultroute="192.168.0.1"
no_swap=YES
dmesg=NO
rpcbind=YES
inetd=YES
syslogd=NO
sshd=YES

----

If I netboot that, nothing works: I can't login with SSH.

Now, if I append:

/usr/libexec/telnetd -debug 80

To the rc.conf file, I can actually connect to port 80.

But, obviously, it's refusing root access. How can I connect? Two solutions I 
can see: Allow telnet root logins (not a problem if it's only temporary) or 
create a user account... remember that I don't have access to the working 
system, I'll have to manually edit the config files. Any ideas on how to do 
either?

What's the format for pwd.db?

> > So what are the files I need to toy with?
>
> /etc/rc.conf, /etc/hostname, /etc/ifconfig.le0, /etc/resolv.conf, and
> /etc/fstab

They all look sane to me and to my interpretation of the manpages =P

> I'm sure there's more I'm forgetting right now...  the diskless(8)
> manpage (available on NetBSD website if you can't read it anywhere else)
> has the details.  if you're booting you're already pretty far along.
[snip]

> > The only thing it really needs is, as far as I can see:
> >
> > IP address/netmask <-> eth card mapping
>
> NFS server address + path on server
>
> > Am I missing something?
>
> you've got it.
>
> the only tricky bit might be /etc/fstab and /etc/ifconfig.le0:
>
> /etc/ifconfig.le0:
> 10.0.0.20 netmask 0xffffff00 media autoselect
>
> /etc/fstab:
> myserver:/export/myclient/root / nfs rw 0 0
> myserver:/usr /usr nfs rw 0 0
>
> that should get you going.  good luck.

Didn't =(

-- 
"A friend of mine used to say that talking to me as like an out-of-body 
experience: everything's normal then something, some detail, makes you feel 
like you've left reality behind."
        -- Christian Lavoie

Christian Lavoie, christian.lavoie@mail.mcgill.ca
http://www.christianlavoie.com