Sendmail problem

Hi experts,

I am facing unique issue while sending mails from HP-UX box.

Mails are not delivered to mail addresses outside my company domain.

 
For e.g.
 
echo "hi" |mailx -s "test" myemail@mycomapny.com is working fine and delivering mails to my company mail address.
 
but 
 
If I give command like 
echo "hi" |mailx -s "test" myemail@gmail.com, it is not delivering mails to my gmail account.

Need your assistance, Do I need to change any configs so that mails can be delivered to email addresses outside my comapany domain also?

Are you able to send email to your gmail account using your company email address ?

May be its blocked to send out an email to gmail.

Hi itkamraj

Thanks for the reply.

Yes I am able to send mails to my gmail account using my company mail address, its just when I try to send it through hp-ux box, it is not able to deliver the message.

In order to do that you would heve to with your mail team if they would relay...and the name of the relaying mail server.
In which case you would configure your HP /etc/mail/senmail.cf:
Look for with vi (Slash DS...)

 #DS
 DSsmtp.mycompany.com  # the name of the relaying mail server...#
#
.

Hi Vbe,

Thanks for the reply.

Yes..relay server is already configured as highlighted below in sendmail.cf file,are there any other configs that needs to be checked?

 
more /etc/mail/sendmail.cf |grep DS
# Relay all non-local mail to the "Smart" relay host (DS) via smtp:            #
#      to a smart relay via SMTP just set macro S (DS) to the name of the      #
# Relay all non-local mail to the "Smart" relay host (DS) via UUCP:            #
#      make two chnages to this file. First, set macro S (DS) to the name      #
DSmailserver
# noreceipts    Don't return success DSN's
# Return-Receipt-To: header implies DSN request if this option is set
# DHParameters (only required if DSA/DH is used)

Is that you who replaced the servername to show us the DS line is uncommented and completed, because if that is your server name I doubt it work...

Hi Vbe

Thanks for the reply...

No I have not changed nything,just pasted the output of command there, its acutally written as mailserver in sendmail.cf file.

Corresponding ip for the mailserver is available in the /etc/hosts file.

The name on the DS line has to be the fully qualifyed hostname (meaning with domain...): the same as the output of

nslookup <ip.of.ya.box>