This file is indexed.

/usr/share/tcos/scripts/tcos-premount/20hdd is in initramfs-tools-tcos 0.89.86.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/bin/sh
# 
if [ "$1" = "prereqs" ]; then
  exit 0
fi

quiet=n


. /scripts/functions
# if break=sqmount STOP here
maybe_break hdd


. /conf/tcos.conf
. /conf/tcos-run-functions




# check if we are booting from HD / USB
_INITRD=$(read_cmdline_var "initrd" "")
if [ "$_INITRD" = "initrd.gz" ]; then
   # booting from hdd, use usr.squashfs from HDD if exists
   mkdir -p /mnt/tmp

   for part in $(grep -e ext3 -e vfat /etc/fstab| awk '{print $1":"$3}'); do
     device=$(echo $part | awk -F":" '{print $1}')
     fs=$(echo $part | awk -F":" '{print $2}')
     mount -t${fs} ${device} /mnt/tmp

     if [ -f /mnt/tmp/usr.squashfs ]; then
       USR_SQUASH=/mnt/tmp/usr.squashfs
       _log "SQMOUNT found usr.squashfs in $device "
       break
     elif [ -f /mnt/tmp/usr-$(uname -r).squashfs ]; then
       USR_SQUASH=/mnt/tmp/usr-$(uname -r).squashfs
       _log "SQMOUNT found usr-$(uname -r).squashfs in $device "
       break
     else
       umount /mnt/tmp
     fi
   done
fi





##############################################


exit 0