I tend to use my install docs by copying and pasting the lines in, adjusting as needed.

I boot from the install ISO, generally a memstick image for physical machines, and go into a live session.

From the live session, I want to ssh in from an established system to do the install. However, running sshd is a small challenge. To overcome this, I do the following:

# First, you need a mutable /etc. So:
mkdir /tmp/etc
mount_unionfs /tmp/etc /etc

# Things get twitchy about mtimes and so forth, so:
#
# XXX note that under FreeBSD 13, you'll see a number of errors for files under
# /etc/ssl as the files themselves are a link farm, as opposed to directories.
# This is cosmetic, but worth noting as it spews a bunch of errors across your
# terminal.
find /etc -exec touch {} \;

# That done, you can change the root passwd, for ssh:
passwd root

# ...and allow root to ssh in;
vi /etc/ssh/sshd_config

# change PermitRootLogin to "yes". Note that you're changing the install
# environment's sshd configuration, and this won't carry over to your install.

# Once this is done, set up networking, either by hand or with something like:
dhclient em0

# ...and then:
service sshd onestart

This done, now you can ssh into root from a comfortably configured and run bsdinstall. Note that your ssh host keys generated during the install environment will go away on first boot unless you explicitly save them.

It might be nice if this sort of environment were available canned from the installer, but it's not bad to set it up, and it's very convenient once done.

NOTE: This purpose would be better served by links into /tmp/bsdinstall_etc in the install environment, and I'll see about pursuing this.


CategoryHowTo

MasonLoringBliss/InstallEnvironment (last edited 2021-04-20T01:02:29+0000 by MasonLoringBliss)