diff --git a/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.download b/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.download index 92be3d4c..9c8e0e47 100755 --- a/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.download +++ b/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.download @@ -72,7 +72,7 @@ preparePartitions() { done fi ;; - [5-7]|9) + [5-7]|[9-11]) [[ ! -d $imagePath && ! -f $imagePath/sys.img.000 ]] && handleError "Unable to locate image store ($0)\n Args Passed: $*" sfdiskOriginalPartitionFileName "$imagePath" "1" sfdiskLegacyOriginalPartitionFileName "$imagePath" "1" @@ -245,7 +245,7 @@ putDataBack() { [1-2]) [[ ! -f $imagePath && ! -d $imagePath ]] && handleError "Fatal Error: Could not locate file ($0)\n Args Passed: $*" ;; - [5-7]|9) + [5-7]|[9-11]) [[ ! -d $imagePath && ! -f $imagePath/sys.img.000 ]] && handleError "Fatal Error: Could not locate file ($0)\n Args Passed: $*" ;; 4|50|51) diff --git a/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.upload b/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.upload index c1297182..1d50136c 100755 --- a/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.upload +++ b/Buildroot/board/FOG/FOS/rootfs_overlay/bin/fog.upload @@ -38,7 +38,7 @@ beginUpload() { parts="" getPartitions "$hd" [[ ${#parts} -lt 1 ]] && handleError "No partitions found ($0)\n Args Passed: $*" - [[ $osid == @([1-2]|[4-7]|9) ]] && win7partcnt=$(echo $parts | wc -w) + [[ $osid == @([1-2]|[4-7]|[9-11]) ]] && win7partcnt=$(echo $parts | wc -w) dots "Checking for fixed partitions" part_number=0 for part in $parts; do @@ -83,7 +83,7 @@ beginUpload() { echo " * Total Partition count of: $partscnt" debugPause case $osid in - [4-7]|9|50|51) + [4-7]|[9-11]|50|51) echo " * Setting up any additional fixed parts" part_number=0 for part in $parts; do diff --git a/Buildroot/board/FOG/FOS/rootfs_overlay/usr/share/fog/lib/funcs.sh b/Buildroot/board/FOG/FOS/rootfs_overlay/usr/share/fog/lib/funcs.sh index adb0968e..43daeb7f 100644 --- a/Buildroot/board/FOG/FOS/rootfs_overlay/usr/share/fog/lib/funcs.sh +++ b/Buildroot/board/FOG/FOS/rootfs_overlay/usr/share/fog/lib/funcs.sh @@ -79,7 +79,7 @@ verifyNetworkConnection() { } # Verifies that the OS is valid for resizing validResizeOS() { - [[ $osid != @([1-2]|4|[5-7]|9|50|51) ]] && handleError " * Invalid operating system id: $osname ($osid) (${FUNCNAME[0]})\n Args Passed: $*" + [[ $osid != @([1-2]|4|[5-7]|[9-11]|50|51) ]] && handleError " * Invalid operating system id: $osname ($osid) (${FUNCNAME[0]})\n Args Passed: $*" } # Gets the information from the system for inventory doInventory() { @@ -665,7 +665,7 @@ shrinkPartition() { resizePartition "$part" "$(calculate "$sizentfsresize*1024")" "$imagePath" [[ $osid -eq 2 ]] && correctVistaMBR "$disk" ;; - [5-7]|9) + [5-7]|[9-11]) [[ $part_number -eq $win7partcnt ]] && part_start=$(blkid -po udev $part 2>/dev/null | awk -F= '/PART_ENTRY_OFFSET=/{printf("%.0f\n",$2*'$part_block_size'/1000)}') || part_start=1048576 if [[ -z $part_start || $part_start -lt 1 ]]; then echo "Failed" @@ -921,7 +921,7 @@ getValidRestorePartitions() { [1-2]) [[ ! -f $imagePath ]] && imgpart="$imagePath/d${disk_number}p${part_number}.img${split}" || imgpart="$imagePath" ;; - 4|[5-7]|9) + 4|[5-7]|[9-11]) [[ ! -f $imagePath/sys.img.000 ]] && imgpart="$imagePath/d${disk_number}p${part_number}.img${split}" if [[ -z $imgpart ]]; then case $win7partcnt in @@ -1051,7 +1051,7 @@ changeHostname() { 1) regfile="$REG_LOCAL_MACHINE_XP" ;; - 2|4|[5-7]|9) + 2|4|[5-7]|[9-11]) regfile="$REG_LOCAL_MACHINE_7" ;; esac @@ -1208,7 +1208,7 @@ clearMountedDevices() { esac fi case $osid in - 4|[5-7]|9) + 4|[5-7]|[9-11]) local fstype="" fsTypeSetting "$part" REG_HOSTNAME_MOUNTED_DEVICES_7="\MountedDevices" @@ -1268,7 +1268,7 @@ removePageFile() { fsTypeSetting "$part" [[ ! $ignorepg -eq 1 ]] && return case $osid in - [1-2]|4|[5-7]|[9]|50|51) + [1-2]|4|[5-7]|[9-11]|50|51) case $fstype in ntfs) dots "Mounting partition ($part)" @@ -1381,6 +1381,14 @@ determineOS() { osname="Windows 10" mbrfile="" ;; + 10) + osname="Windows 11" + mbrfile="" + ;; + 11) + osname="Windows Server" + mbrfile="" + ;; 50) osname="Linux" mbrfile="" @@ -1589,7 +1597,7 @@ completeTasking() { . ${postdownpath}fog.postdownload fi [[ $capone -eq 1 ]] && exit 0 - if [[ $osid == +([1-2]|4|[5-7]|9) ]]; then + if [[ $osid == +([1-2]|4|[5-7]|[9-11]) ]]; then for disk in $disks; do getPartitions "$disk" for part in $parts; do @@ -1716,7 +1724,7 @@ handleError() { # Linux: if [[ -n $2 ]]; then case $osid in - [1-2]|4|[5-7]|9|50|51) + [1-2]|4|[5-7]|[9-11]|50|51) if [[ -n "$hd" ]]; then getPartitions "$hd" for part in $parts; do @@ -2367,7 +2375,7 @@ restorePartition() { 4|8|50|51|99) imgpart="$imagePath/d${disk_number}p${part_number}.img${split}" ;; - [5-7]|9) + [5-7]|[9-11]) [[ ! -f $imagePath/sys.img.000 ]] && imgpart="$imagePath/d${disk_number}p${part_number}.img${split}" if [[ -z $imgpart ]] ;then [[ -r $imagePath/sys.img.000 ]] && win7partcnt=1