NIS client installation with FAI

Katarzyna Myrek oliviakrk at gmail.com
Fri Jul 20 09:45:39 CEST 2012


Hi

I managed to install NIS with NFS via FAI class. Here are files I am using:

1. /srv/fai/config/files/root/nis_install
nis nis/domain  string  YOUR_NIS_DOMAIN

This file will help install package nis (holding off any prompts in post
install aptitude scripts).

2. Script included in class which installs nis:
#! /bin/bash
# © 2012 Katarzyna "Olivia" Myrek

if [ $FAI_ACTION = "install" ]; then
fcopy -BMi /root/nis_install
echo "Copied nis_install"
$ROOTCMD debconf-set-selections /root/nis_install
$ROOTCMD aptitude install -y nis
rm /target/root/nis_install
##Those lines need a little security tweaking
echo "NFSSERVER:/export/home            /home           nfs
defaults,rw,nodev,nosuid,rsize=32768,wsize=32768,_netdev,tcp 0 0" >>
/target/etc/fstab
echo "+::::::" >> /target/etc/passwd
echo "+::::::" >> /target/etc/shadow
echo "+::::::" >> /target/etc/group
echo "+::::::" >> /target/etc/gshadow


fcopy -BMi /etc/defaultdomain
fcopy -BMi /etc/default/nis
fcopy -BMi /etc/yp.conf
fcopy -BMi /etc/nsswitch.conf
fcopy -BMi /etc/profile
fcopy -BMi /var/yp/Makefile ##not needed?
fcopy -BMi /usr/local/bin/passwd

fi

I hope this will someday help someone install nis via class;).


Regards,
Katarzyna Myrek
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.uni-koeln.de/pipermail/linux-fai/attachments/20120720/bf1a6ab1/attachment.html>


More information about the linux-fai mailing list