Which command, available with all MTAs, is used to list the contents of the MTA's mail queue? (Specify ONLY the command without any path or parameters.)
Correct Answer:
mailq, /usr/bin/mailq, sendmail -bp, /usr/sbin/sendmail -bp, /usr/lib/sendmail -bp, sendmail, /usr/sbin/sendmail, /usr/lib/sendmail
Explanation:
The command that is used to list the contents of the MTA's mail queue is mailq12. This command is available with all MTAs, such as sendmail, postfix, exim, etc12. The mailq command prints the mail queue, which is the list of messages that are waiting tobe sent12. The output of the mailq command shows the queue ID, size, time, sender, and recipient of each message12. The mailq command can also take various options to modify the output, such as -v for verbose mode, -Ac for mail submission queue, -qL for lost items, and -qQ for quarantined items3.
References: 1: mailq Command in Linux with Examples - GeeksforGeeks 2: mailq Command Examples in Linux - The Geek Diary 3: linux - How to see entire sendmail queue? - Server Fault