Sendmail: invalid option -- 'd'

This question seems to be asked here already as well, but it didn't get an answer.

[root@un~]# sendmail -d0.1 -bt < /dev/null
sendmail: invalid option -- 'd'
sendmail: invalid option -- '0'
sendmail: invalid option -- '.'
sendmail: invalid option -- '1'
sendmail: invalid option -- 'd'
sendmail: fatal: usage: sendmail [options]

How do I resolve this issue? I'm following "UNIX and Linux System Administration Handbook" by evi nemeth 5th edition.

Suggest you read the online documentation for the app

man sendmail

NB: command options are dependent upon the version installed !

1 Like

-d category . level...
Set the debugging flag for category to level. Category is either an integer or a name specifying the topic, and level an integer specifying the level of debugging output desired. Higher levels generally mean more output. More than one flag can be specified by separating them with commas. A list of numeric debugging categories can be found in the TRACEFLAGS file in the sendmail source distribution.
The option -d0.1 prints the version of sendmail and the options it was compiled with.
Most other categories are only useful with, and documented in, sendmail's source code.

-bt

Run in address test mode. This mode reads addresses and shows the steps in parsing; it is used for debugging configuration tables.

This should work right?

if the text youve posted is not from man sendmail then the jury is out as to whether 'This should work right?` should work !

on my current host (macpro OS) there is no -d or -bt options, its the 'Postfix sendmail' implementation. ,
I can try on another host later, but if the command says invalid option its pretty clear.
See if the sendmail command is an alias type sendmail and see what it returns

1 Like

Run the
man sendmail
on your box!
It tells you if the installed sendmail is a wrapper for postfix.

ok about to sleep. will do tommorow.