Options

Help with setting up Sendmail.

TechJunkyTechJunky Member Posts: 881
I am pretty much a windows guy but I have dealt with some linux in the past. I have configured bind already and I thought I configured the sendmail.mc correctly but for some reason I cannot telnet to port 25 or 110. I have double checked to make sure the service was started. This is a virtual hosted server.

Any ideas what I may need to change to make sure my sendmail is working properly?

Server address is mail.akdns.org

Thanks!

Comments

  • Options
    GrynderGrynder Member Posts: 106
    Have you made sure the ports are open on the firewall?
  • Options
    sprkymrksprkymrk Member Posts: 4,884 ■■■□□□□□□□
    Did you run your sendmail.mc through the m4 processor and restart sendmail?

    m4 /etc/mail/sendmail.mc > /etc/sendmail.cf

    /etc/rc.d/init.d/sendmail restart

    You also need to edit the /etc/mail/access to tell sendmail who it can send mail for (relay), otherwise only accounts on the local system (server) will be able to.
    All things are possible, only believe.
  • Options
    TechJunkyTechJunky Member Posts: 881
    My structure for my mail is located under...

    /etc/mail

    I have tried etc/rc.d/init.d/sendmail restart

    What would I put in the access file exactly?

    I have to put each ip address I want connecting to the mail server? Or can i just specifiy a range.. IE: 66.58.*.*

    Everything else looks normal.

    I could create an account for you on the server if you wanted to ssh in and check the config files and see what i am doing wrong.
  • Options
    marco71marco71 Member Posts: 152 ■■■□□□□□□□
    Interesting ports on 67.223.232.159 (mail.akdns.org):
    Not shown: 1681 closed ports
    PORT STATE SERVICE
    22/tcp open ssh
    25/tcp filtered smtp
    53/tcp open domain
    80/tcp open http
    110/tcp open pop3
    135/tcp filtered msrpc
    136/tcp filtered profile
    137/tcp filtered netbios-ns
    138/tcp filtered netbios-dgm
    139/tcp filtered netbios-ssn
    143/tcp open imap
    445/tcp filtered microsoft-ds
    623/tcp filtered unknown
    664/tcp filtered unknown
    993/tcp open imaps
    995/tcp open pop3s

    smtp port (25) should be open !!!
  • Options
    sprkymrksprkymrk Member Posts: 4,884 ■■■□□□□□□□
    TechJunky wrote:
    What would I put in the access file exactly?

    I have to put each ip address I want connecting to the mail server? Or can i just specifiy a range.. IE: 66.58.*.*

    The access file can contain domain names, host names, and ip addresses. You could use:

    akdns.org RELAY

    If you wanted to explicitly block or reject email from certain domains or hosts we could use this file to do so. Instead of “RELAY” you use a “REJECT” or “DISCARD”.

    Then save your changes and issue the following commands:

    make
    /etc/rc.d/init.d/sendmail restart
    All things are possible, only believe.
  • Options
    TechJunkyTechJunky Member Posts: 881
    Thanks. I have had some time to mess around with the server. I think I have everything squared away except for my PTR records. I am using www.pingability.com to check my server.

    It looks like everything is working but my PTR records. I know I have them in my config but for some reason they are not resolving correctly.

    Any information would be greatly appreciated.

    Here is my reverse DNS...

    http://www.akdns.org/reverse.zone

    Nevermind, I contacted the ISP that maintains that block of IP's and submitted a reverse DNS request. I forgot they had to have the reverse record in order for it to function.
  • Options
    TechJunkyTechJunky Member Posts: 881
    Ok, so my reverse is working but I am still getting 550 relay denied errors. Is there something special I should be configuring with my sendmail?

    I am at a loss.

    Here is my output using telnet..

    220 60303 ESMTP Sendmail 8.13.8/8.13.8; Thu, 10 Jul 2008 22:13:42 GMT
    ehlo akdns.org
    250-60303 Hello 209-112-135-2-dsl-rb1.nwc.acsalaska.net [209.112.135.2], pleased
    to meet you
    250-ENHANCEDSTATUSCODES
    250-PIPELINING
    250-8BITMIME
    250-SIZE
    250-DSN
    250-ETRN
    250-AUTH GSSAPI
    250-DELIVERBY
    250 HELP
    mail from: kendall@akdns.org
    250 2.1.0 kendall@akdns.org... Sender ok
    rcpt to: kendall@akgaming.com
    250 2.1.5 kendall@akgaming.com... Recipient ok

    So I dont get a relaying error from the server when trying to send from the server, but if I try to send from another email address to my domain (akdns.org) I get a relaying error.
  • Options
    TechJunkyTechJunky Member Posts: 881
    Ok. I figured it out.

    Thanks anyhow.
  • Options
    dynamikdynamik Banned Posts: 12,312 ■■■■■■■■■□
    Don't leave us hanging!

    What was the problem?
  • Options
    TechJunkyTechJunky Member Posts: 881
    My local-host-names file didnt have my domain in it. So it didn't know to accept email from other domains. I also changed my host name at the same time. I restarted the service and voula!

    Now to get spamassassin working and spamd.
  • Options
    mike3mike3 Member Posts: 136
    Good for you. I know ISP's that run this exact setup so feel good about your setup.
  • Options
    ally_ukally_uk Member Posts: 1,145 ■■■■□□□□□□
    Fancy writing a tutorial on setting up a mail server? Lol I am interested in developing this area of my skillset as I am thinking about volunteering for a charity on a weekend to improve my computer skills it would be a excellent bonus if I could walk in and implement a open source Mail solution to keep the cost down.

    But mail servers confuse the hell out of me registering domains? MX records? protocols to use? and finally how the hell it all works and to set it up I have tried numerous tutorials but they all presume that you a are a Linux Vet or UNIX wiz.


    Can somebody give me the basics?
    Microsoft's strategy to conquer the I.T industry

    " Embrace, evolve, extinguish "
  • Options
    mike3mike3 Member Posts: 136
    It's to bad I couldn't sit down and explain this all to you.

    Maybe you should start your research in simply understanding MX records and how domains and such all work before jumping into setting it up??
  • Options
    MishraMishra Member Posts: 2,468 ■■■■□□□□□□
    www.linuxhomenetworking.com

    Setup and lab and use some of their tutorials.
    My blog http://www.calegp.com

    You may learn something!
  • Options
    ally_ukally_uk Member Posts: 1,145 ■■■■□□□□□□
    Thanks for the feedback guys the question I have currently I am with a ISP do I get the email addresses I want to use for my network from my ISP? or do I register a domain?
    Microsoft's strategy to conquer the I.T industry

    " Embrace, evolve, extinguish "
  • Options
    rossonieri#1rossonieri#1 Member Posts: 799 ■■■□□□□□□□
    hi ally,
    the question I have currently I am with a ISP do I get the email addresses I want to use for my network from my ISP? or do I register a domain?

    you need at least a static public IP and need to register a domain name of your own. eg. ally.tld - after that point your DNS A (or CNAME) for your www/ftp server and MX record to your internal mail server (or the router - and do NAT).

    HTH.
    the More I know, that is more and More I dont know.
  • Options
    undomielundomiel Member Posts: 2,818
    The dynamic dns I use (afraid.org) allows me to set up an MX record pointing to my A record. It was just a matter of making sure my router would update the A record whenever its ip changed. Of course since the ISP filtered port 25 it did no good but it was a good experience in learning how to set all of that up.
    Jumping on the IT blogging band wagon -- http://www.jefferyland.com/
  • Options
    FlexTecFlexTec Member Posts: 3 ■□□□□□□□□□
    I need to get my sendmail working properly again. My asterisk for some reason stopped sending the mails out so that needs work.

    I live in a co-op so my personal duty assigment is to Understand DNS,BIND,Sendmail and perhaps Apache well and implement it to the complex and its members.

    I am not new to linux but never dove in hardcore when I started using it a decade ago. Now I think there is a real need to use it. One is cost. Complex has priorities where its money is going.

    Two, It would help me considerably in preparing or my LPI cirtification. I need to get my linux skills polished on the command line like I always have :) I currently run IP-cop/? and Centos/Asterisk. Notice how I put the question mark. Frigen IP-Cop so dam reliable I have cold power off and booted it 300 times and it comes up running every time. So no need to know Distro at this moment.

    Anyway, I am working on sendmail. If I start to run into issues getting it to run tonight will come back to ask questions.
  • Options
    bensenbensen Member Posts: 12 ■□□□□□□□□□
    whcih linux are u running? redhat 5.0?
  • Options
    sprkymrksprkymrk Member Posts: 4,884 ■■■□□□□□□□
    bensen wrote:
    whcih linux are u running? redhat 5.0?

    He said he is running CentOS. A Red Hat clone.
    All things are possible, only believe.
Sign In or Register to comment.