Description
The following bit of code from flume-daemon.sh fails to produce the correct result under sudo-type of execution:
if [ "$FLUME_IDENT_STRING" = "" ]; then
export FLUME_IDENT_STRING="$USER"
fi
This is because $USER is not always set for shell. A more robust solution would be to use the output of id -nu