Sounds like making bin/mask.sh executable by root ONLY might help you forget to use sudo to run it
Sudo chmod /bin/mask.sh x=r should do it -- All the best Keith Bainbridge keithr...@gmail.com +61 (0)447 667 468 GMT+ 10:00 Sent from my Aphone. Please excuse my brevity. On 21 November 2024 9:49:00 am AEDT, Greg Wooledge <g...@wooledge.org> wrote: >On Thu, Nov 21, 2024 at 06:17:31 +0800, Bitfox wrote: >> sudo echo "something" >>/etc/postfix/virtual_alias_maps > >https://mywiki.wooledge.org/BashPitfalls#pf53 > >> Can you help me why the first sudo failed? > >The redirection >> is being done before sudo is executed. >