LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 04-15-2009, 02:37 PM   #1
Nel0
LQ Newbie
 
Registered: Apr 2009
Distribution: debian lenny, ubuntu, centos
Posts: 2

Rep: Reputation: 0
Red Hat Server not emailing because of squid, help please.


Hi, I have squid Installed on a Red Hat box as a server, and have a centOS box with a web server that uses the red hat one as a proxy. The centos box can browse the internet without problems, but I have a web application that needs to send emails out of the domain and they are not being sent. Yes, I know squid only works as a HTTP and doesn't understand all the SMTP jargle.

The problem is that the server is not sending emails to addresses outside the network (e.g. @gmail.com), but I tested sending emails inside the windows domain with PHP and it worked.

Centos is configured to have the red hat box as the default gateway.
I read somewhere that I could make the server forward the activity through port 25 using iptables, or that I could also configure sendmail to do the job.
Anyone knows how to get the job done? This has been killing me for the last two days.

Last edited by Nel0; 04-16-2009 at 11:21 AM.
 
Old 04-16-2009, 09:41 AM   #2
Nel0
LQ Newbie
 
Registered: Apr 2009
Distribution: debian lenny, ubuntu, centos
Posts: 2

Original Poster
Rep: Reputation: 0
Im using these Ip tables in the /etc/sysconfig/iptables in the redhat box, but they dont seem to be working:
10.12.0.10 is the Ip of a Microsoft exchange server that knows the route out of the network.

-A POSTROUTING -p tcp -m tcp --dport 995 -j SNAT --to 10.12.0.10 MASQUERADE
-A POSTROUTING -p tcp -m tcp --dport 443 -j SNAT --to 10.12.0.10 MASQUERADE
-A POSTROUTING -p tcp -m tcp --dport 25 -j SNAT --to 10.12.0.10 MASQUERADE

Last edited by Nel0; 04-16-2009 at 11:23 AM.
 
Old 04-16-2009, 01:58 PM   #3
jonnytabpni
Member
 
Registered: Sep 2008
Posts: 68

Rep: Reputation: 16
Is your Red Hat box configured as a gateway/router? When you say "browse the internet", do you mean by changing firefox's proxy settings?

What is the default gateway of the Red Hat box? You should probably use that for direct connections to the internet (You can still use the squid proxy though)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
emailing Four LQ Suggestions & Feedback 3 02-24-2006 09:09 PM
Squid: special configuration for remote Squid server hamish Linux - Software 0 12-06-2005 03:58 PM
Problems emailing to users on server mingo Linux - Networking 2 11-19-2004 12:49 PM
Server Emailing Information Lucasite Linux - Software 1 03-04-2004 11:20 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 07:39 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration