aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcarey.xu <carey.xuhan@huawei.com>2016-02-26 16:41:21 +0800
committerJustin chi <chigang@huawei.com>2016-02-27 07:17:42 +0000
commit7a45023d02b13a282a592bc8b1edbda7ee3e2bae (patch)
tree06d03778af6a576c6dc4c7f8db0cd8c61f6de650
parent519706e5c3d5905975a59add1f3c5c4960343227 (diff)
bugfix: nfs space is too small on compass core, need make it bigger
JIRA: COMPASS-320 Change-Id: I54876943b4ff0a70cd7fac1e05f48aa06b0f1aa9 Signed-off-by: carey.xu <carey.xuhan@huawei.com>
-rw-r--r--util/ks.cfg31
1 files changed, 14 insertions, 17 deletions
diff --git a/util/ks.cfg b/util/ks.cfg
index dd31d8fd..76ce0ff6 100644
--- a/util/ks.cfg
+++ b/util/ks.cfg
@@ -34,20 +34,15 @@ skipx
# System timezone
timezone America/Los_Angeles --isUtc
# System bootloader configuration
-bootloader --append=" crashkernel=auto" --location=mbr --boot-drive=sda
+
+%include /tmp/bootloader.ks
+
# Clear the Master Boot Record
zerombr
# Partition clearing information
clearpart --all --initlabel
# Disk partitioning information
-part swap --asprimary --fstype="swap" --ondisk=sda --size=3072
-part /boot --asprimary --fstype="ext3" --ondisk=sda --size=500
-part pv.64 --fstype="lvmpv" --ondisk=sda --size=27145
-volgroup os --pesize=4096 pv.64
-logvol /var --fstype="ext3" --grow --percent=40 --name=varvol --vgname=os
-logvol /tmp --fstype="ext3" --grow --percent=5 --name=tmpvol --vgname=os
-logvol / --fstype="ext3" --grow --percent=50 --name=rootvol --vgname=os
-logvol /home --fstype="ext3" --grow --percent=5 --name=homevol --vgname=os
+%include /tmp/partition.ks
%pre
#!/bin/sh
@@ -124,14 +119,16 @@ sleep 3
hdparm -z /dev/${tgtdrive}
# partition
-echo > /tmp/partition.ks
-echo "partition /boot --onpart=/dev/${tgtdrive}3" >> /tmp/partition.ks
-echo "partition pv.001 --ondisk=${tgtdrive} --size=30000 --grow" >> /tmp/partition.ks
-echo "volgroup os pv.001" >> /tmp/partition.ks
-echo "logvol swap --vgname=os --recommended --name=swap" >> /tmp/partition.ks
-echo "logvol / --vgname=os --size=10000 --name=root --fstype=ext4" >> /tmp/partition.ks
-echo "logvol /var --vgname=os --size=10000 --percent 60 --grow --name=var --fstype=ext4" >> /tmp/partition.ks
-echo "logvol /var/log --vgname=os --size=4096 --percent 40 --grow --name=varlog --fstype=ext4" >> /tmp/partition.ks
+cat << EOF > /tmp/partition.ks
+part swap --asprimary --fstype="swap" --ondisk=sda --size=3072
+part /boot --asprimary --fstype="ext3" --ondisk=sda --size=500
+part pv.64 --fstype="lvmpv" --ondisk=sda --size=$((tgtdrivesize-3600))
+volgroup os --pesize=4096 pv.64
+logvol /var --fstype="ext3" --grow --percent=40 --name=varvol --vgname=os
+logvol /tmp --fstype="ext3" --grow --percent=5 --name=tmpvol --vgname=os
+logvol / --fstype="ext3" --grow --percent=50 --name=rootvol --vgname=os
+logvol /home --fstype="ext3" --grow --percent=5 --name=homevol --vgname=os
+EOF
# bootloader setting
echo "bootloader --location=mbr --driveorder=${tgtdrive} --append=' biosdevname=0 crashkernel=none'" > /tmp/bootloader.ks