/[smeserver]/cdrom.image/sme10/Packages/base/sme-kickstart.cfg
ViewVC logotype

Diff of /cdrom.image/sme10/Packages/base/sme-kickstart.cfg

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

Revision 1.1 by unnilennium, Fri May 27 15:05:34 2016 UTC Revision 1.4 by unnilennium, Sat Jul 2 11:34:04 2016 UTC
# Line 1  Line 1 
1  # System authorization information  # System authorization information
2  auth --enableshadow --passalgo=sha512  auth --enableshadow --passalgo=sha512
3    
4  # Use CDROM installation media  # Use CDROM installation media
5  cdrom  #cdrom #what about usb stick
6  # Use graphical install  
7  #graphical  # we do not want Selinux
 #%include /usr/share/anaconda/interactive-defaults.ks  
 #install  
 ignoredisk --only-use=vda  
 # Keyboard layouts  
 keyboard --xlayouts='us'  
 # System language  
 lang en_US.UTF-8  
8  selinux --disabled  selinux --disabled
 #firewall --disabled  
 #services --enabled=NetworkManager,sshd  
 #eula --agreed  
 #reboot  
9    
10    # services to activate
11    services --disabled=lm_sensors
12    
13  # System timezone  # default root pass, willbe changed in post-install process anyway
14  timezone America/New_York --isUtc  rootpw --lock
15  # System bootloader configuration  
16  bootloader --append=" crashkernel=auto quiet" --location=mbr --boot-drive=vda  # Accept eula
17    eula --agreed
18    
19  autopart --type=lvm  # include the partitioning logic from the pre section.
20  # Partition clearing information  %include /tmp/part-include
21  clearpart --all --initlabel --drives=vda  
22    # disable kdump
23    %addon com_redhat_kdump --disable
24    %end
25    
26    
27  bootloader --location=mbr  %pre
28    # pre section
29    #----- partitioning logic below--------------
30    # pick the first drive that is not removable and is over MINSIZE
31    DIR="/sys/block"
32    
33    # minimum size of hard drive needed specified in GIGABYTES
34    MINSIZE=5
35    
36    
37    # Number of detected drives
38    NDEV=0
39    
40    for DEV in $(lsblk -nl | grep disk | cut -d' ' -f1); do
41      if [ -d /sys/block/$DEV ]; then
42        REMOVABLE=`cat /sys/block/$DEV/removable`
43        if (( $REMOVABLE == 0 )); then
44          SIZE=`cat /sys/block/$DEV/size`
45          GB=$(($SIZE/2**21))
46          if [ $GB -gt $MINSIZE ]; then
47            DRIVES[$NDEV]=$DEV
48            ((NDEV++))
49          fi
50        fi
51      fi
52    done
53    
54    # For now keep things simple and just use the first one
55    # TODO:
56    # * Create software RAID depending on the number of detected drives
57    # * Allow non LVM install
58    
59    ROOTDRIVE=${DRIVES[0]}
60    if [ $ROOTDRIVE == "" ] ; then
61    echo "No drive suitable for installation found! Please proceed manually."
62    # first in case detection fails...
63    cat << EOF > /tmp/part-include
64    # Clear the Master Boot Record
65  zerombr  zerombr
66  #part swap --asprimary --fstype="swap" --size=1024  # System bootloader configuration
67  #part /boot --fstype xfs --size=200  clearpart --all  --initlabel
68  #part pv.01 --size=1 --grow  # Automatically create partitions, no LVM
69  #volgroup rootvg01 pv.01  autopart --lvm
 #logvol / --fstype xfs --name=lv01 --vgname=rootvg01 --size=1 --grow  
70    
71  services --disabled=lm_sensors  EOF
72    
73    else
74    cat <<_EOF > /tmp/part-include
75    zerombr
76    clearpart --all --drives=$ROOTDRIVE --initlabel
77    bootloader --boot-drive=$ROOTDRIVE
78    part /boot --fstype xfs --size=500 --ondisk=$ROOTDRIVE --label=BOOT
79    part pv.01 --size=4500 --grow --ondisk=$ROOTDRIVE
80    volgroup main pv.01
81    logvol / --fstype xfs --name=root --vgname=main --grow --size=3000 --label=ROOT
82    logvol swap --fstype swap --name=swap --vgname=main --recommended --label=SWAP
83    _EOF
84    
85    fi
86    
87    %end
88    
89    
90    
91    # packages to install
92  %packages  %packages
93  @^minimal  @^minimal
94  @base  @base
# Line 47  services --disabled=lm_sensors Line 99  services --disabled=lm_sensors
99  %end  %end
100    
101    
 # pre script could be inserted there to handle partitionning  
102    
103  %post --log=/root/ks-post.log --interpreter=/usr/bin/bash  %post  --interpreter=/usr/bin/bash --log=/var/log/ks.post02.log
104  # before reboot performing post-install  # before reboot performing post-install
105  # this is for first alpha iso. we should put this in anaconda  # this is for first alpha iso. we should put this in anaconda
106  # and / or handle possible upgrade later  # and / or handle possible upgrade later
107  /sbin/rsyslogd;  /sbin/rsyslogd;
108  sleep 2;  sleep 2;
109  /sbin/e-smith/signal-event post-install;  /sbin/e-smith/signal-event post-install;
110    sleep 2;
111    /sbin/e-smith/db configuration set UnsavedChanges no;
112  touch /forcequotacheck  touch /forcequotacheck
113    
114  %end  %end
115    
116    %post  --nochroot --log=/mnt/sysimage/var/log/ks.post01.log
117    #!/bin/bash
118    sysimage="/mnt/sysimage"
119    
120    cp -r /tmp/anaconda.log ${sysimage}/root/
121    %end


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed