Permalink
Browse files

Improve the install process, skip integrity check, and mount usr.uzip

directly from media, in order to leave the maximum ammount of RAM
available for the install process
  • Loading branch information...
1 parent 584b6ff commit 6e0ee8d83d59c4a5cb2e1c2888e131565013a042 @kmoore134 kmoore134 committed Jun 26, 2013
Showing with 6 additions and 43 deletions.
  1. +6 −28 overlays/install-overlay/etc/SetupInstall.sh
  2. +0 −15 overlays/install-overlay/etc/pcbsd-rc.sh
View
34 overlays/install-overlay/etc/SetupInstall.sh
@@ -4,35 +4,13 @@
# Setup the /memfs memory device
echo "Mounting /memfs"
-# Do a check of available memory
-sysMem=`/sbin/sysctl hw.realmem | /bin/cut -d ' ' -f 2`
-minSize=`/bin/expr 500 \* 1024 \* 1024`
-if [ $sysMem -lt $minSize ] ; then
- MDSIZE="2"
- echo "Creating ${MDSIZE}MB ramdisk..."
- /sbin/mdmfs -S -s ${MDSIZE}M -O space md2 /memfs
+MDSIZE="2"
+echo "Creating ${MDSIZE}MB ramdisk..."
+/sbin/mdmfs -S -s ${MDSIZE}M -O space md2 /memfs
- echo "Mounting /usr"
- MDDEVICE="`/sbin/mdconfig -a -t vnode -o readonly -f /uzip/usr.uzip`.uzip"
- /sbin/mount -r /dev/$MDDEVICE /usr
-
-else
- # Copy uzip to memory which lets us run faster
- MDSIZE="`/bin/du -m /uzip/usr.uzip | /bin/cut -f 1`"
- MDSIZE="`/bin/expr ${MDSIZE} + 10`"
- echo "Creating ${MDSIZE}MB ramdisk..."
- /sbin/mdmfs -S -s ${MDSIZE}M -O space md2 /memfs
-
- echo "Copying setup image into memory... Please Wait..."
- /bin/cp /uzip/usr.uzip /memfs/
-
- # Mount the "usr" directory
- echo "Mounting /usr"
- MDDEVICE="`/sbin/mdconfig -a -t vnode -o readonly -f /memfs/usr.uzip`.uzip"
- /sbin/mount -r /dev/$MDDEVICE /usr
-
- # End of loading if we have > 512MB ram
-fi
+echo "Mounting /usr"
+MDDEVICE="`/sbin/mdconfig -a -t vnode -o readonly -f /uzip/usr.uzip`.uzip"
+/sbin/mount -r /dev/$MDDEVICE /usr
PATH="${PATH}:/usr/bin"
export PATH
View
15 overlays/install-overlay/etc/pcbsd-rc.sh
@@ -30,21 +30,6 @@ then
else
# Installation medium ONLY
- # Run integrity checks
- /etc/IntegrityCheck.sh
- if [ "$?" != "0" ]
- then
- echo "One or more integrity checks failed. This can indicate a corrupt
-installation medium. Please reburn your CD and check the md5 of your ISO
-against the md5 displayed on the PC-BSD site. To reboot press ENTER.
-To continue at your own peril type 'continue': "
- read integrityResponse
- if [ "$integrityResponse" != "continue" ]
- then
- /sbin/reboot
- fi
- fi
-
# We are running a regular Install
sh /etc/SetupInstall.sh
fi

0 comments on commit 6e0ee8d

Please sign in to comment.