incoming mail is refused

Jim Delany

Registered
I'm trying to get Pine working under OS 10.1 but have been unsuccessful. I can mail out but not receive mail. Messages sent from outside go undelivered and return the message...

... Deferred: Connection refused by mersenne.cosam.calpoly.edu.

I'ts not a Pine issue. The same thing happens using "mail". I can send mail to an outside person but they can't reply.

If I use "mail" to mail to another account on the same machine (mersenne) things work ok.

The machine has a fixed IP address and that seems to be set up OK because I can ping, telnet (i.e. ssh), and ftp to the machine.

Is there some configuration file where I have to tell the machine to allow incoming mail? Do I have to open some port? Could Keychain Access be a problem? I've been looking but don't know enough to do much good.

I guess I should mention that the application Mail works just fine.

Any ideas would certainly be appreciated
Thanks in advance
Jim
 
Originally posted by Jim Delany
I'm trying to get Pine working under OS 10.1 but have been unsuccessful. I can mail out but not receive mail. Messages sent from outside go undelivered and return the message...

... Deferred: Connection refused by mersenne.cosam.calpoly.edu.

I'ts not a Pine issue. The same thing happens using "mail". I can send mail to an outside person but they can't reply.

If I use "mail" to mail to another account on the same machine (mersenne) things work ok.

The machine has a fixed IP address and that seems to be set up OK because I can ping, telnet (i.e. ssh), and ftp to the machine.

Is there some configuration file where I have to tell the machine to allow incoming mail? Do I have to open some port? Could Keychain Access be a problem? I've been looking but don't know enough to do much good.

I guess I should mention that the application Mail works just fine.

Any ideas would certainly be appreciated
Thanks in advance
Jim

You probably don't have the port required for SMTP access open on your machine. You can use Brickhouse to open it up if you don't want to mess with the terminal. The port you need to open is port 25.

I'm not familiar with Pine, but when you open up port 25, make sure you don't have an open SMTP relay, which spammers could use. This can probably be done by restricting SMTP sending to only the IPs you want to be able to send with your server.
 
devonferns

Thanks for your reply. It sounded quite sensible so I did as you suggested; I downloaded Brickhouse and set it up it to allow incoming smtp. Alas, it had no effect on my problem. No mail gets through to the machine.

Since no one else seems to have had this problem, I'm beginning to think some file is busted. Unless someone has any other suggestions, I think I'll just try to reinstall 10.1 and see if that fixes anything.

Thanks for trying
Jim
 
Originally posted by Jim Delany
devonferns

Thanks for your reply. It sounded quite sensible so I did as you suggested; I downloaded Brickhouse and set it up it to allow incoming smtp. Alas, it had no effect on my problem. No mail gets through to the machine.

Since no one else seems to have had this problem, I'm beginning to think some file is busted. Unless someone has any other suggestions, I think I'll just try to reinstall 10.1 and see if that fixes anything.

Thanks for trying
Jim

That's weird that it wouldn't work. From the error message you gave before it sounds like either your mailserver isn't getting any request, or the request is being rejected.

Are you behind a router? If you are then you'll have to forward port 25 to your server as well.

Your welcome. :)
 
Uh... Please forgive me if I'm stating the obvious here...

I don't think that 10.1 runs an SMTP server by default. A quick look @ netstat doesn't reveal anything listening to port 25 at all on my machine. This would be consistent with the 'connection refused' message, which simply means that no process was available to answer the request on the port. Whether that means there's a firewall in the way is another issue altogether.

I only mention all of this because the original question only mentions Pine and Mail, both of which are only clients. I didn't see any mention of anything like sendmail (ack!) or procmail being installed here... :confused:
 
Originally posted by kenny
Uh... Please forgive me if I'm stating the obvious here...

I don't think that 10.1 runs an SMTP server by default. A quick look @ netstat doesn't reveal anything listening to port 25 at all on my machine. This would be consistent with the 'connection refused' message, which simply means that no process was available to answer the request on the port. Whether that means there's a firewall in the way is another issue altogether.

I only mention all of this because the original question only mentions Pine and Mail, both of which are only clients. I didn't see any mention of anything like sendmail (ack!) or procmail being installed here... :confused:

Well, if Pine isn't an SMTP server, then that would be his problem. I assumed that it was an SMTP server as he was talking about incoming SMTP connections being refused.
 
I guess it was wrong of me to mention Pine. The problem seemingly has nothing to do with that. I've now installed OS 10.1 on a second (older) machine and I'm having the same problem with the "mail" command that I had before. By "mail" I mean the primitive old unix command (with which I first learned to use email) not the Mail app shipped with OS X.

Using "mail" ...

a.) I can mail to other users of the same machine and they can reply using "mail".

b.) I can mail to users on other machines and they will receive the mail, but their replies will not be delivered because connection is refused.

A lot of what you write is over my head, for example, the business of telling the router what port I'm using. I've been using the same campus router for over 10 years, first with a NeXT, later with Macs running LinuxPPC and I've never had to do this in the past; I wouldn't even know how.

I'd be stunned to find out that smtp isn't included in the OS. A quick check for mail-related commands turns up a whole bunch. (See below)

I've tried dealing with the campus "Help Desk" but they aren't much help at this point, not being familiar with OS X. I'll see if I can get anywhere with "Network Administration" when they come to work on Monday.

Anyway, thanks again
and here are the supported mail commands.*
Jim

[fermat:~] jdelany% apropos mail
aliases(5) - aliases file for sendmail
biff(1) - be notified if mail arrives and who it is from
expn(1) - recursively expand mail aliases
fetchmail(1) - fetch mail from a POP, IMAP, ETRN, or ODMR-capable server
formail(1) - mail (re)formatter
from(1) - print names of those who have sent mail
mail(1) - send and receive mail
mail.local(8) - store mail in a mailbox
mailaddr(7) - mail addressing description
mailq(1) - print the mail queue
mailstats(8) - display mail statistics
makemap(8) - create database maps for sendmail
msgs(1) - system messages and junk mail program
newaliases(1) - rebuild the data base for the mail aliases file
praliases(8) - display system mail aliases
procmail(1) - autonomous mail processor
procmailex(5) - procmail rcfile examples
procmailrc(5) - procmail rcfile
procmailsc(5) - procmail weighted scoring technique
rmail(8) - handle remote mail received via uucp
sendmail(8) - an electronic mail transport agent
smrsh(8) - restricted shell for sendmail

*PS: I've heard that there are problems because this implementation is not case-sensitive. For example typing "mail" and typing "MAIL" have the same effect. But I don't suppose this has anthing to do with my problem.
 
Sorry, I don't know how to setup mail. If it has an SMTP server then it is most likely turned off by default to prevent spamming. There is also sendmail, but I'm not quite sure how to set that up either.
 
Originally posted by devonferns
Sorry, I don't know how to setup mail. If it has an SMTP server then it is most likely turned off by default to prevent spamming. There is also sendmail, but I'm not quite sure how to set that up either.

devonferns

Your responses pinpointed the problem and I was able to unearth the answer elsewhere. To make a long story short, one must edit /etc/hostconfig to change "MAILSERVER=-NO-" to "MAILSERVER=-YES-", then reboot. I've tested this with great success.

The full posting which included the answer was quite informative so I'll include it in it's entirety below fyi. It was posted by Larry Prall.

Thanks again for all your help
Jim

=========================================
Larry Prall RE: How to send/receive local mails?
(msg # 1.: Posted Nov 26, 01 5:22 pm)

You have to start the sendmail daemon, but you shouldn't need to modify sendmail.cf. You probably will need to change the permissions on "/", though because it ships as 1775 and sendmail doesn't like that. A "sudo chmod g-w /" will do the trick. You may want to modify the file /System/Library/StartupItems/Sendmail/Sendmail because it starts sendmail with a one hour queue time which seems a bit long. You can edit /etc/hostconfig to change "MAILSERVER=-NO-" to "MAILSERVER=-YES-" to get sendmail to start on boot.

If your users are using Mail.app they can set up UNIX accounts with it so that they can receive mail locally.

There is a Mail bug, though, that you will have to work around for each user: when Mail creates its mailbox to hold UNIX mail, it creates a file (not a directory) at ~/Library/Mail/UNIX:mad: and you will have to remove the file and create a directory of the same name. I don't believe the file will be created until Mail picks up its first UNIX mail for the user, so you might want to have each user set up a UNIX account in Mail, then send each of them a test message, then go in and delete the file and created the directory.
 
Back
Top