This file is indexed.

/usr/sbin/upgradedb is in 389-ds-base 1.3.3.5-4.

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
54
55
56
57
58
59
#!/bin/bash

source /usr/share/dirsrv/data/DSSharedLib

libpath_add "/usr/lib/x86_64-linux-gnu/dirsrv/"
libpath_add "/usr/lib/x86_64-linux-gnu"
libpath_add ""
libpath_add "/usr/lib/x86_64-linux-gnu"

export LD_LIBRARY_PATH
SHLIB_PATH=$LD_LIBRARY_PATH
export SHLIB_PATH

usage ()
{
    echo "Usage: upgradedb [-a archivedir] [-Z serverID] [-f] [-v] [-d debuglevel] [-h]"
    echo "Options:"
    echo "        -a archivedir  - Location of database backup"
    echo "        -Z serverID    - Server instance identifier"
    echo "        -f             - Force upgrade"
    echo "        -v             - Display version"
    echo "        -d debuglevel  - Debugging level"
    echo "        -h             - Display usage"
}
while getopts "Z:vfrd:h" flag
do
    case $flag in
        Z) servid=$OPTARG;;
        v) args=$args" -v";;
        f) args=$args" -f";;
        r) args=$args" -r";;
        d) args=$args" -d $OPTARG";;
        a) args=$args" -a $OPTARG"
           archive_provided="yes";;
        D) args=$args" -D $OPTARG";;
        h) usage
           exit 0;;
    esac
done

initfile=$(get_init_file "/etc/default" $servid)
if [ $? == 1 ]
then
    echo "You must supply a valid server instance identifier.  Use -Z to specify instance name"
    echo "Available instances: $initfile"
    exit 1
fi

servid=`normalize_server_id $initfile`
. $initfile

if [ "$archive_provided" != "yes" ]
then
    bak_dir=/var/lib/dirsrv/slapd-$servid/bak/upgradedb_`date +%Y_%m_%d_%H_%M_%S`
    args=$args" -a $bak_dir"
fi

echo upgrade index files ...
/usr/sbin/ns-slapd upgradedb -D $CONFIG_DIR $args