This file is indexed.

/etc/init/ceph-osd.conf is in ceph 0.80.7-2+deb8u2.

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

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
description "Ceph OSD"

start on ceph-osd
stop on runlevel [!2345] or stopping ceph-osd-all

respawn
respawn limit 5 30

limit nofile 32768 32768

pre-start script
    set -e
    test -x /usr/bin/ceph-osd || { stop; exit 0; }
    test -d "/var/lib/ceph/osd/${cluster:-ceph}-$id" || { stop; exit 0; }

    install -d -m0755 /var/run/ceph

    update="$(ceph-conf --cluster=${cluster:-ceph} --name=osd.$id --lookup osd_crush_update_on_start || :)"
    if [ "${update:-1}" = "1" -o "${update:-1}" = "true" ]; then
        # update location in crush
	hook="$(ceph-conf --cluster=${cluster:-ceph} --name=osd.$id --lookup osd_crush_location_hook || :)"
	if [ -z "$hook" ]; then
	    hook="/usr/bin/ceph-crush-location"
	fi
	location="$($hook --cluster ${cluster:-ceph} --id $id --type osd)"
	weight="$(ceph-conf --cluster=${cluster:-ceph} --name=osd.$id --lookup osd_crush_initial_weight || :)"
	defaultweight=`df -P -k /var/lib/ceph/osd/${cluster:-ceph}-$id/ | tail -1 | awk '{ d= $2/1073741824 ; r = sprintf("%.2f", d); print r }'`
	ceph \
            --cluster="${cluster:-ceph}" \
            --name="osd.$id" \
            --keyring="/var/lib/ceph/osd/${cluster:-ceph}-$id/keyring" \
            osd crush create-or-move \
	    -- \
            "$id" \
	    "${weight:-${defaultweight:-1}}" \
	    $location
    fi

    journal="/var/lib/ceph/osd/${cluster:-ceph}-$id/journal"
    if [ -L "$journal" -a ! -e "$journal" ]; then
        udevadm settle --timeout=5 || :
	if [ -L "$journal" -a ! -e "$journal" ]; then
            echo "ceph-osd($UPSTART_INSTANCE): journal not present, not starting yet." 1>&2
	    stop
	    exit 0
	fi
    fi
end script

instance ${cluster:-ceph}/$id
export cluster
export id

exec /usr/bin/ceph-osd --cluster="${cluster:-ceph}" -i "$id" -f