functions-cleanup.sh (210700) | functions-cleanup.sh (211730) |
---|---|
1#!/bin/sh 2#- 3# Copyright (c) 2010 iXsystems, Inc. All rights reserved. 4# 5# Redistribution and use in source and binary forms, with or without 6# modification, are permitted provided that the following conditions 7# are met: 8# 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24# SUCH DAMAGE. 25# | 1#!/bin/sh 2#- 3# Copyright (c) 2010 iXsystems, Inc. All rights reserved. 4# 5# Redistribution and use in source and binary forms, with or without 6# modification, are permitted provided that the following conditions 7# are met: 8# 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24# SUCH DAMAGE. 25# |
26# $FreeBSD: head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh 210700 2010-07-31 19:25:51Z imp $ | 26# $FreeBSD: head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh 211730 2010-08-24 06:11:46Z imp $ |
27 28# Functions which perform the final cleanup after an install 29 30# Finishes up with ZFS setup before unmounting 31zfs_cleanup_unmount() 32{ 33 # Loop through our FS and see if we have any ZFS partitions to cleanup 34 for PART in `ls ${PARTDIR}` --- 126 unchanged lines hidden (view full) --- 161 fi 162 163 # Unset EXT 164 EXT="" 165 166 # Set mount options for file-systems 167 case $PARTFS in 168 UFS+J) MNTOPTS="rw,noatime,async" ;; | 27 28# Functions which perform the final cleanup after an install 29 30# Finishes up with ZFS setup before unmounting 31zfs_cleanup_unmount() 32{ 33 # Loop through our FS and see if we have any ZFS partitions to cleanup 34 for PART in `ls ${PARTDIR}` --- 126 unchanged lines hidden (view full) --- 161 fi 162 163 # Unset EXT 164 EXT="" 165 166 # Set mount options for file-systems 167 case $PARTFS in 168 UFS+J) MNTOPTS="rw,noatime,async" ;; |
169 SWAP) MNTOPTS="sw" ;; 170 *) MNTOPTS="rw,noatime" ;; | 169 SWAP) MNTOPTS="sw" ;; 170 *) MNTOPTS="rw,noatime" ;; |
171 esac 172 173 174 # Figure out if we are using a glabel, or the raw name for this entry 175 if [ ! -z "${PARTLABEL}" ] 176 then 177 DEVICE="label/${PARTLABEL}" 178 else --- 207 unchanged lines hidden (view full) --- 386 run_chroot_cmd "cat /.rootpw | pw usermod root -h 0" 387 rc_halt "rm ${FSMNT}/.rootpw" 388 389}; 390 391 392run_final_cleanup() 393{ | 171 esac 172 173 174 # Figure out if we are using a glabel, or the raw name for this entry 175 if [ ! -z "${PARTLABEL}" ] 176 then 177 DEVICE="label/${PARTLABEL}" 178 else --- 207 unchanged lines hidden (view full) --- 386 run_chroot_cmd "cat /.rootpw | pw usermod root -h 0" 387 rc_halt "rm ${FSMNT}/.rootpw" 388 389}; 390 391 392run_final_cleanup() 393{ |
394 # Check if we need to run any gmirror setup 395 ls ${MIRRORCFGDIR}/* >/dev/null 2>/dev/null 396 if [ "$?" = "0" ] 397 then 398 # Lets setup gmirror now 399 setup_gmirror 400 fi |
|
394 | 401 |
395 # Check if we need to run any gmirror setup 396 ls ${MIRRORCFGDIR}/* >/dev/null 2>/dev/null 397 if [ "$?" = "0" ] 398 then 399 # Lets setup gmirror now 400 setup_gmirror 401 fi | 402 # Check if we need to save any geli keys 403 ls ${GELIKEYDIR}/* >/dev/null 2>/dev/null 404 if [ "$?" = "0" ] 405 then 406 # Lets setup geli loading 407 setup_geli_loading 408 fi |
402 | 409 |
403 # Check if we need to save any geli keys 404 ls ${GELIKEYDIR}/* >/dev/null 2>/dev/null 405 if [ "$?" = "0" ] 406 then 407 # Lets setup geli loading 408 setup_geli_loading 409 fi | 410 # Set a hostname on the install system 411 setup_hostname |
410 | 412 |
411 # Set a hostname on the install system 412 setup_hostname | 413 # Set the root_pw if it is specified 414 set_root_pw |
413 | 415 |
414 # Set the root_pw if it is specified 415 set_root_pw 416 417 # Generate the fstab for the installed system 418 setup_fstab 419 | 416 # Generate the fstab for the installed system 417 setup_fstab |
420}; | 418}; |