This content has been marked as final. Show 6 replies
sorry, I meant 192.168.1.105, this is on my LAN, and I do have DSL to work with.
The following works for me for using gmail:
Install the software:
Configure postfix smtp authentication. Use your own username and password credentials and use the echo command with single quotes ('):
su - root wget http://public-yum.oracle.com/public-yum-el5.repo \ --output-document=/etc/yum.repos.d/public-yum-el5.repo yum -y install postfix chkconfig sendmail --del chkconfig postfix --add
Configure postfix relay and authentication:
echo 'smtp.gmail.com username:password' > /etc/postfix/sasl_passwd postmap hash:/etc/postfix/sasl_passwd rm -f /etc/postfix/sasl_passwd
cat >> /etc/postfix/main.cf <<EOF smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd smtp_sasl_security_options = noanonymous smtp_tls_security_level = secure smtp_tls_mandatory_protocols = TLSv1 smtp_tls_mandatory_ciphers = high smtp_tls_secure_cert_match = nexthop smtp_tls_CAfile = /etc/pki/tls/certs/ca-bundle.crt relayhost = smtp.gmail.com:587 EOF
service postfix restart
echo "testmail " | mail -s "test" email@example.com
thank you, Dude, as soon as I can try it on my system, I'll be sure to give points. I appreciate the insights.
well, this offering looked very helpful at the front end, but I've run into a snag, in that my static IP setting 192.168.1.105 does not allow my system to take advantage of DHCP, and tuhs I lose my connection to outside. How can this be addresssed?
Sorry please explain. I have no idea what DHCP or static IP as such has to do with relaying your mail for outgoing connections? If your machine can connect to the Internet, the above should work. If you cannot connect to the Internet with your IP setup, that's a completely different story and needs to be addressed separately. If your service provider gives you an IP address for your router and provides NAT services than any private IP will work as long as you use your DSL router as your TCP/IP gateway.
to check if your network have connection to internet for mail, do
dig mx gmail.com
telnet gmail-smtp-in.l.google.com 25
if you see prompts, then you should be able to mail outside.
if the ip with you get internet doesn't match the domain of the same, your emails will probably get mark as spam..