LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 11-05-2007, 04:32 PM   #1
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Rep: Reputation: 61
Question webserver + sendmail


Hello All,

I have a server inside my house hosted on my cable modem. And I can't seem to get it to send emails out. I realize this may be because my ISP is blocking the messages getting sent out, but I want to confirm it is that before I move my server out of my house.

So how I can check to see if sendmail is working or not? I am using Ubuntu 6.10, and as far as I can tell I have installed sendmail correctly using the apt-get install sendmail etc.

What can I do to see if it is actually working or not?

Also, just to let you guys know, I've been trying to send mail using PHPmailer, and also the generic php mail() function. Thanks in advance.
 
Old 11-06-2007, 12:28 PM   #2
flashingcurser
Member
 
Registered: Jan 2003
Distribution: many win/nix/mac
Posts: 259

Rep: Reputation: 32
Make sure your forwarding is correct. From the outside try to "telnet your.ip.add.ress 25" see what happens. If not, set up a firewall between you and your modem (or iptables locally) forward 1025 to 25 on the server. Then try "telnet your.ip.add.ress 1025"

Side note, I know at least postfix can be set up to authenticate to your isp's mail server and relay based on your account.

One other question: where is the function php mail() trying to mail to? If it is mailing to a local (to the webserver/mailserver that is) mail account, you should be able to get that mail from the local network. Regardless if they block 25.
 
Old 11-06-2007, 12:31 PM   #3
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Original Poster
Rep: Reputation: 61
I just realized actually that my home router/gateway does not have any forwarding rules in it... I didn't think I would need to set up a rule to allow the mail to go out... Should I do that?

I am emailing to my personal Gmail account. I will try what you suggested. Thank you.
 
Old 11-06-2007, 01:19 PM   #4
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Original Poster
Rep: Reputation: 61
C:\Documents and Settings\t33to>telnet 192.168.1.3 25
Connecting To 192.168.1.3...Could not open connection to the host, on port 25: Connect failed

Is what I get when I try to Telnet locally. Same from outside the network.
 
Old 11-09-2007, 02:57 PM   #5
koflanagan
LQ Newbie
 
Registered: Mar 2005
Location: San Antonio
Posts: 20

Rep: Reputation: 0
Well for me, since I use RR I have to define a smart hosts in /etc/mail/sendmail.mc
define(`SMART_HOST', `smtp-server.satx.rr.com')dnl
If you want to be able to telnet to the box via port 25 you need to have the DAEMON options below set as well.
DAEMON_OPTIONS(`Port=smtp,Name=MTA')dnl
After that you need to do a make -C /etc/mail and restart sendmail ( /sbin/service sendmail restart )
 
Old 11-10-2007, 07:02 AM   #6
mrcoffee11
LQ Newbie
 
Registered: Jul 2006
Posts: 18

Rep: Reputation: 0
Indeed you have to delete the 127.0.0.1 address in DAEMON_OPTIONS. Sendmail is just listening to 127.0.0.1 if this address is still configured. Or change it to the ip address 192.168.1.3.
 
Old 11-10-2007, 02:59 PM   #7
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Original Poster
Rep: Reputation: 61
Thanks guys. Ill try that out shortly.
 
  


Reply



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
Sendmail config questions + Sendmail not reflecting changes to access db wbuik Linux - Networking 2 03-26-2009 05:02 AM
sendmail is not working & on $prompt the cmd sendmail hangs Pavan mahoorker Linux - Software 1 04-04-2006 03:57 PM
Can't see WebServer from outside... Can see WebServer locally as http://localhost friddick Linux - Networking 13 08-19-2003 06:27 PM
Sendmail - RunAsUser=sendmail:mail/What files to i have to change ForumKid Linux - Security 45 01-18-2002 11:47 AM
sendmail (dont just ignore it 'cause its got sendmail in the subject :P) GnomeKing Linux - Networking 1 11-12-2001 09:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 10:46 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