mailx SMTP; 554 Domains without a subdomain are not allowed
While I’m trying to send mail to another domain mail id from root linux terminal using by mailx, It shows the below error
SMTP; 554 Domains without a subdomain are not allowed
first my mind focused on sendmail configuration , Is any configuration issues there while configure sendmail?. But I checked everything here, I can not found any solutions from here. Finally I found the solution.
Add hostname with domain in hosts file
[root@siebelpoc ~]# cat /etc/hosts # Do not remove the following line, or various programs # that require network functionality will fail. 127.0.0.1 localhost.localdomain localhost ::1 localhost6.localdomain6 localhost6 10.xx.xx.xx domaintest.xxx.com domaintest
After add it here, just restart the network service. you can able to send mail other domain related mail id like (email@example.com).