Comment 3 for bug 531123

Revision history for this message
Dmitry Ljautov (dljautov) wrote :

# cat /etc/default/tftpd-hpa
#Defaults for tftpd-hpa
TFTP_USERNAME="tftp"
TFTP_DIRECTORY="/var/pxe"
TFTP_ADDRESS="0.0.0.0:69"
TFTP_OPTIONS="-l -vvvvvvvvvv -B 512 -r blksize2 -m /etc/default/tftpd.rules"

do_start function in /etc/init.d/tftpd-hpa before fixing:

do_start()
{
        if [ ! -d "${TFTP_DIRECTORY}" ]
        then
                echo "${TFTP_DIRECTORY} missing, aborting."
                exit 1
        fi

        start-stop-daemon --start --quiet --oknodo --exec ${DAEMON} -- \
                --listen --user ${TFTP_USERNAME} --address ${TFTP_ADDRESS} \
                ${TFTP_OPTIONS} ${TFTP_DIRECTORY}
}

do_start function in /etc/init.d/tftpd-hpa after fixing:
o_start()
{
        if [ ! -d "${TFTP_DIRECTORY}" ]
        then
                echo "${TFTP_DIRECTORY} missing, aborting."
                exit 1
        fi

        start-stop-daemon --start --quiet --oknodo --exec ${DAEMON} -- \
                --listen --user ${TFTP_USERNAME} --address ${TFTP_ADDRESS} \
                ${TFTP_OPTIONS} -s ${TFTP_DIRECTORY}
}