So I have this cronjob on an Ubuntu 16.04 machine that ends in
if ...
echo "warning" | wall 2>&1 > /dev/null
fi
that I use to warn all users about some action taking place. Although I redirect its output to /dev/null
, the script somehow manages to output
wall: cannot get tty name: Inappropriate ioctl for device
which gets sent per e-mail to the root account. How do I make wall
silent? The broadcasting works, but I don't want to have those e-mails in my root mailbox.
# wall -V
wall from util-linux 2.27.1