XEN & KVM / netbsd guest tuning

casual fixen

pdksh rules

chpass -s /bin/ksh root

disable vga console altogether (wscons)

    mv -i /etc/rc.conf /etc/rc.conf.dist
    vi /etc/rc.conf
. /etc/defaults/rc.conf
rc_silent=no # /var/run/rc.log
rc_configured=yes
raidframe=no
wscons=no
sshd=yes

# no memory dump
no_swap=yes
savecore=no

# kvm only
powerd=yes

disable virtual terminals

cp -pi /etc/ttys /etc/ttys.dist
vi /etc/ttys

ttyE1   ... off
ttyE2   ... off
ttyE3   ... off

make postfix happy

vi /etc/myname # new file

netbsd$shortrel

cp -pi /etc/hosts /etc/hosts.dist
vi /etc/hosts

127.0.0.1   netbsd$shortrel

template-ready

a cheaper cloud-init

    vi /etc/ifconfig.vioif0

    dhcp

rm -f /etc/mygate

template/cloud-ready

    /etc/rc.d/sshd stop
    rm -f /etc/ssh/ssh_host_*

you’re done!

    shutdown -p now

HOME | GUIDES | LECTURES | LAB | SMTP HEALTH | HTML5 | CONTACT
Copyright © 2024 Pierre-Philipp Braun