Cleanup commit, added diskless clients
authorroot <root@xenhost00.office.fsf.org>
Mon, 11 Aug 2014 06:01:39 +0000 (02:01 -0400)
committerroot <root@xenhost00.office.fsf.org>
Mon, 11 Aug 2014 06:01:39 +0000 (02:01 -0400)
16 files changed:
class/50-host-classes
config [new symlink]
disk_config/DEFAULT [new file with mode: 0644]
disk_config/FAIBASE
disk_config/FAIBASE.bak [new file with mode: 0644]
disk_config/RMS.bak [new file with mode: 0644]
files/etc/fai/fai.conf/DEFAULT [new file with mode: 0644]
files/etc/fstab/DISKLESS [new file with mode: 0644]
hooks/partition.DISKLESS [new file with mode: 0755]
package_config/DEFAULT
package_config/DEMO
package_config/FAIBASE~ [deleted file]
package_config/RMS [new file with mode: 0644]
package_config/TRISQUEL [new file with mode: 0644]
scripts/DISKLESS/10_setup_initramfs [new file with mode: 0755]
scripts/DISKLESS/20_install_fstab [new file with mode: 0755]

index 49ae3de6430a24687e11660c9ebb25bb4e04da03..785bee23926b9500fb70c7ac4e9669380723464d 100755 (executable)
@@ -8,6 +8,8 @@ case $HOSTNAME in
        echo "FAIBASE DEMO FAISERVER" ;;
     demohost)
        echo "FAIBASE DHCPC DEMO" ;;
+    rms)
+       echo "FAIBASE DHCPC DEMO XORG TRISQUEL RMS";; 
     gnomehost)
        echo "FAIBASE DHCPC DEMO XORG GNOME";;
     atom*)
@@ -16,9 +18,13 @@ case $HOSTNAME in
        echo "FAIBASE DHCPC LVM_XEN_SERVER XEN" ;;
     puma)
        echo "FAIBASE DHCPC RAID_XEN_VIRTUAL" ;;
+    freestation)
+       echo "FAIBASE DHCPC DISKLESS XORG TRISQUEL" ;;
     *)
-       echo "FAIBASE DHCPC;;
+       echo "FAIBASE DHCPC DEMO XORG GNOME";;
 esac
 
-(ifclass I386 || ifclass AMD64) && echo GRUB_PC
+if ! ifclass DISKLESS; then
+    (ifclass I386 || ifclass AMD64) && echo GRUB_PC
+fi
 exit 0
diff --git a/config b/config
new file mode 120000 (symlink)
index 0000000..3f2acbf
--- /dev/null
+++ b/config
@@ -0,0 +1 @@
+/srv/fai/config
\ No newline at end of file
diff --git a/disk_config/DEFAULT b/disk_config/DEFAULT
new file mode 100644 (file)
index 0000000..4ba9b37
--- /dev/null
@@ -0,0 +1,4 @@
+# an extremely simple layout
+#
+disk_config disk1 disklabel:msdos
+primary /      250      ext3  rw
\ No newline at end of file
index 0f44dcc913e7770677ac87b8b5fabe537b816fbe..141b6deb36c6028107caa036867309a45056538b 100644 (file)
@@ -4,9 +4,7 @@
 
 disk_config disk1 disklabel:msdos bootable:1 fstabkey:uuid
 
-primary /      250      ext3  rw,noatime,errors=remount-ro
-logical swap   200-1000 swap  rw                   
-logical /var   600-1300 ext3  rw,noatime         createopts="-L var -m 5" tuneopts="-c 0 -i 0"
-logical /tmp   100-1G   ext3  rw,noatime,nosuid,nodev createopts="-L tmp -m 0" tuneopts="-c 0 -i 0"
-logical /usr   1G-8G    ext3  rw,noatime,nodev   createopts="-L usr"
-logical /home  100-50%  ext3  rw,noatime,nosuid,nodev createopts="-L home -m 1" tuneopts="-c 0 -i 0"
+primary /      18G        ext3  rw,noatime,errors=remount-ro
+primary /home  100-100%  ext3  rw,noatime,nosuid,nodev createopts="-L home -m 1" tuneopts="-c 0 -i 0"
+primary swap   2G swap  rw                   
+
diff --git a/disk_config/FAIBASE.bak b/disk_config/FAIBASE.bak
new file mode 100644 (file)
index 0000000..0f44dcc
--- /dev/null
@@ -0,0 +1,12 @@
+# example of new config file for setup-storage
+#
+# <type> <mountpoint> <size>   <fs type> <mount options> <misc options>
+
+disk_config disk1 disklabel:msdos bootable:1 fstabkey:uuid
+
+primary /      250      ext3  rw,noatime,errors=remount-ro
+logical swap   200-1000 swap  rw                   
+logical /var   600-1300 ext3  rw,noatime         createopts="-L var -m 5" tuneopts="-c 0 -i 0"
+logical /tmp   100-1G   ext3  rw,noatime,nosuid,nodev createopts="-L tmp -m 0" tuneopts="-c 0 -i 0"
+logical /usr   1G-8G    ext3  rw,noatime,nodev   createopts="-L usr"
+logical /home  100-50%  ext3  rw,noatime,nosuid,nodev createopts="-L home -m 1" tuneopts="-c 0 -i 0"
diff --git a/disk_config/RMS.bak b/disk_config/RMS.bak
new file mode 100644 (file)
index 0000000..bf72766
--- /dev/null
@@ -0,0 +1,6 @@
+disk_config disk1 disklabel:msdos bootable:1 fstabkey:uuid
+
+primary /      9G      ext4  rw,noatime,errors=remount-ro
+primary swap   3.1G    swap  rw
+primary /home  -100%   ext4  rw,noatime,nosuid,nodev createopts="-L home -m 1" tuneopts="-c 0 -i 0"
+
diff --git a/files/etc/fai/fai.conf/DEFAULT b/files/etc/fai/fai.conf/DEFAULT
new file mode 100644 (file)
index 0000000..88dc091
--- /dev/null
@@ -0,0 +1,37 @@
+# $Id$
+
+# /etc/fai/fai.conf -- configuration for FAI (Fully Automatic Installation)
+
+# how to access the fai config space
+# If undefined here, make-fai-nfsroot/fai-setup will use default value
+# nfs://<install server>/$FAI_CONFIGDIR
+# supported URL-types: nfs, file, cvs, cvs+ssh, svn+file, svn+http,
+# git, git+http, hg+http, tarball via http
+FAI_CONFIG_SRC=git://faiclient@vcs.fsf.org:fai-configs
+
+# LOGUSER: an account on the install server which saves all log-files
+# and which can change the kernel that is booted via network.
+# Configure .rhosts for this account and PAM, so that root can log in
+# from all install clients without password. This account should have
+# write permissions for /srv/tftp/fai. For example, you can use write
+# permissions for the group linuxadm. chgrp linuxadm /srv/tftp/fai;chmod
+# g+w /srv/tftp/fai. If the variable is undefined, this feature is disabled.
+# Define it, to enable it, eg. LOGUSER=fai
+LOGUSER=
+
+# set protocol type for saving logs. Values: ssh, rsh, ftp
+FAI_LOGPROTO=ssh
+
+# Access to Debian mirror via NFS mounted directory
+# If FAI_DEBMIRROR is defined, install clients mount it to $MNTPOINT
+#FAI_DEBMIRROR=yournfs debianmirror:/path/to/debianmirror
+
+
+# The following variables are read only for almost every user.
+# Do not change them unless you know what you are doing!
+
+# mount point where the mirror will be mounted
+MNTPOINT=/srv/fai/mirror
+
+# the local configuration directory on the install client
+FAI=/srv/fai/config
diff --git a/files/etc/fstab/DISKLESS b/files/etc/fstab/DISKLESS
new file mode 100644 (file)
index 0000000..2a573ea
--- /dev/null
@@ -0,0 +1,13 @@
+# /etc/fstab: static file system information. 
+#
+# <file system> <mount point>   <type>  <options>       <dump>  <pass>
+proc            /proc           proc    defaults        0       0
+/dev/nfs        /               nfs    defaults          1       1
+none            /tmp            tmpfs   defaults        0       0
+none            /var/run        tmpfs   defaults        0       0
+none            /var/lock       tmpfs   defaults        0       0
+none            /var/tmp        tmpfs   defaults        0       0
+none            /media          tmpfs   defaults        0       0
+/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto 0       0
+192.168.0.25:/home                           /home               nfs4           defaults      0
+        2
diff --git a/hooks/partition.DISKLESS b/hooks/partition.DISKLESS
new file mode 100755 (executable)
index 0000000..22e69a0
--- /dev/null
@@ -0,0 +1,40 @@
+#! /bin/sh
+
+# install a diskless workstation
+# this is just an example, but not perfect code
+#
+# (c) Thomas Lange, 2001, lange at debian.org
+
+# server and all filesystems for diskless client
+server=......  # Fill in your server's name
+root=/export/$HOSTNAME    # Change according to your situation
+var=
+swap=
+
+# Under lenny, the mount point does not exist at this stage yet.
+[ ! -d $target ] && mkdir $target
+
+# dpkg wants a lock but linux NFS can't do it yet
+mountopt="-o nolock,async"
+# Add the options which helped to speed up diskless machines under etch.
+mountopt=${mountopt},tcp,intr,rsize=8192,wsize=8192,retrans=10
+
+# mount2dir can't mount nfs directories yet, so do it now
+# and skip the default task later
+# also clean up the directories (preserve is not yet possible)
+mount $mountopt $server:$root $target
+echo 'Deleting target files from previous OS may take some time...'
+echo 'You may help a little by deleting files yourself on the server.'
+#rm -rf $target/.[0-z]* $target/*
+(cd $target; mklost+found)
+
+# create fstab
+cat > /tmp/fai/fstab <<EOF
+$server:$root / nfs rw,errors=remount-ro 0 0
+EOF
+# $server:$usr /usr nfs rw 0 0
+
+echo "#!" > $LOGDIR/disk_var.sh
+
+# now skip some default tasks
+skiptask partition mountdisks
\ No newline at end of file
index c12a917f93a968deae11b6ce60bc26f643a4cc8a..c97956018f24525219183fb7e966a3f2d9441f1d 100644 (file)
@@ -1,13 +1,13 @@
 PACKAGES aptitude I386
-linux-image-2.6-486 initramfs-tools
+linux-image initramfs-tools
 memtest86+
 
 PACKAGES aptitude CHROOT
-linux-image-486-
-linux-image-amd64-
+linux-image
+
 
 PACKAGES aptitude AMD64
-linux-image-2.6-amd64 initramfs-tools
+linux-image initramfs-tools
 memtest86+
 
 PACKAGES aptitude XEN
index 0502f9bc4555ac8d0367b29dda028a786cc6a05a..1592f02505dab8498b8221fa90afec27b308c7e5 100644 (file)
@@ -1,11 +1,7 @@
 # some packages we need on a demo machine
 
 PACKAGES aptitude
-fortune-mod fortunes
+
 rstat-client #rstatd
 rusers rusersd
 
-# only when also class XORG is defined
-PACKAGES aptitude XORG
-bb xpenguins
-#frozen-bubble
diff --git a/package_config/FAIBASE~ b/package_config/FAIBASE~
deleted file mode 100644 (file)
index e633c3d..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-PACKAGES aptitude
-fai-client
-cfengine2
-cron
-dialog
-debconf-utils
-file
-hdparm
-jove
-less
-linuxlogo
-nfs-common
-nscd
-rdate
-rsync
-openssh-client openssh-server
-strace
-tcsh
-time
-procinfo
-exim4
-eject
-locales
-console-common
-pciutils usbutils
-lvm2
diff --git a/package_config/RMS b/package_config/RMS
new file mode 100644 (file)
index 0000000..f2fdbc3
--- /dev/null
@@ -0,0 +1,37 @@
+PACKAGES aptitude
+
+build-essential
+gdb
+units
+audacity
+aspell
+aspell-fr
+aspell-es
+aspell-it
+aspell-id
+tanglet
+vlc
+mpg123
+music123
+vorbis-tools
+network-manager
+freeciv-server
+freeciv-client-gtk
+libreoffice
+ffmpeg
+calibre
+xcdroast
+konqueror
+rfkill
+cups
+ghostscript
+xpdf
+ssh
+gnupg
+gnupg-agent
+tex
+openvpn
+youtube-dl
+wicd
+wicd-client
+unrar-free
\ No newline at end of file
diff --git a/package_config/TRISQUEL b/package_config/TRISQUEL
new file mode 100644 (file)
index 0000000..f59091a
--- /dev/null
@@ -0,0 +1,10 @@
+PACKAGES aptitude
+
+trisquel
+menu
+gconf-editor
+gnome-screensaver gnome-system-monitor gnome-system-tools
+gnome-network-admin
+libgnomevfs2-bin
+
+
diff --git a/scripts/DISKLESS/10_setup_initramfs b/scripts/DISKLESS/10_setup_initramfs
new file mode 100755 (executable)
index 0000000..57f9710
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+sed 's/^BOOT=.*/BOOT=nfs/g' -i $target/etc/initramfs-tools/initramfs.conf 
+
+$ROOTCMD update-initramfs -u
\ No newline at end of file
diff --git a/scripts/DISKLESS/20_install_fstab b/scripts/DISKLESS/20_install_fstab
new file mode 100755 (executable)
index 0000000..89e3420
--- /dev/null
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+fcopy -v /etc/fstab
\ No newline at end of file