hMail Receiving Problems

Use this forum if you have installed hMailServer and want to ask a question related to a production release of hMailServer. Before posting, please read the troubleshooting guide. A large part of all reported issues are already described in detail here.
Post Reply
robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

hMail Receiving Problems

Post by robustrobot » 2011-03-01 04:09

I am very stuck right now. I have a setup the hmail server following the directions to the letter. I installed the SquirrelMail interface and all works fine (kinda). I cannot receive email at all. I've made port forwards through my router for ports 25, 110, and 143. I've configured the settings to try and get it to work, but it doesn't. When I run the diagnostics test, it all checks out fine. I enabled SMTP logging and I always seem to get the same error:

"ERROR" 264 "2011-02-28 20:52:38.123" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 25. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 25. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 264 "2011-02-28 20:52:38.123" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 143. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 143. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 4328 "2011-02-28 20:52:54.030" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 25. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 25. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 4328 "2011-02-28 20:52:54.030" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 110. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 110. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 4328 "2011-02-28 20:52:54.030" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 143. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 143. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 2872 "2011-02-28 20:54:45.694" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 25. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 25. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."
"ERROR" 2872 "2011-02-28 20:54:45.694" "Severity: 2 (High), Code: HM4316, Source: TCPServer::Run(), Description: Failed to bind to local port. Error: The requested address is not valid in its context. Address: 74.69.197.142, Error code: 10049, Port: 110. This is often caused by another server listening on the same port.To determine which server is listening on the port, telnet your server on port 110. Make sure that no other email server is running and listening on this port, and then restart the hMailServer service."

I can't figure out what's wrong! I set the server up so that the email address is "example"@homesap.redirectme.net. I have the freedns which forwards to my public ip address, which then port forwards itself to my server. Any help would be greatly appreciated.

User avatar
daz69
Normal user
Normal user
Posts: 128
Joined: 2010-07-20 15:22
Location: Cornwall

Re: hMail Receiving Problems

Post by daz69 » 2011-03-01 09:33

Are you sure theres no other server on that machine like IIS?
What happens when you telnet to port 25, does it respond?
What os is it?

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-01 16:19

I am like 95% positive there's no other server. On the server, it's running Windows XP Media Center. And about telnet. it gives me an error! It says,

"421 Cannot connect to server 74.69.197.142 <74.69.197.142:25>, connect error 10060 Connection to host lost."

What do I do now?

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-01 16:40

Please go to

(don't change this, just report yes or no please)
Start >> Control Panel >> Add remove programs >> Add / remove windows components >> IIS >> SMTP

Is that checked? If so then IIS SMTP is installed
If not then we need to find what is...
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-01 21:49

Nope it's not checked. I wonder what it could be...

User avatar
daz69
Normal user
Normal user
Posts: 128
Joined: 2010-07-20 15:22
Location: Cornwall

Re: hMail Receiving Problems

Post by daz69 » 2011-03-01 23:34

Go to advanced settings > tcpip ports then hit default on the right hand side then restart the hmail service (not just start/stop in administrator) and see if that works.

When you tried to telnet did you try from the same machine as hmail is on with
Telnet localhost 25 ?

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-02 00:28

No, it still doesn't work. But when I telnet on the server that hMail is on like you said to to, daz69, it says:
"220 brandonmedia esmtp"

brandonmedia is the name of the computer. I'm not good with the Command Prompts, so I have no idea what that means.

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-02 02:02

open a command prompt on the server and type 'netstat -a -b'.

Look for SMTP and see which program is using that port
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-02 02:10

Looks like hMailServer.exe is using the smtp port. I doubt that makes sense.

EDIT: Just noticed that after I telnet-ed the local computer, i checked the log from hMail Server and I notice taht everything I typed was recorded. Don't know if that helps.

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-02 02:32

So you are no longer getting those error messages?
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-02 02:50

Doens't look like there are any error messages. But I'm still not receiving my test emails.

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-02 03:16

OK so how are you sending the test emails?
Where from?

You said that
robustrobot wrote:EDIT: Just noticed that after I telnet-ed the local computer, i checked the log from hMail Server and I notice taht everything I typed was recorded. Don't know if that helps.
Which indicates that you should be receiving email.

Can you PM me your domain name & I'll check it for you from here...?
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-02 04:59

Ok looks to me like you haven't forwarded port 25 on your router to your server, or that something else on your system (AV perhaps or firewall) is stopping port 25 traffic.

What brand of router do you have?
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-02 17:35

I have a Linksys WRT54G router.

EDIT: I thought I had port forwarded correctly. This is what my port forwrading screen from my router looks like:
Attachments
router.png

User avatar
daz69
Normal user
Normal user
Posts: 128
Joined: 2010-07-20 15:22
Location: Cornwall

Re: hMail Receiving Problems

Post by daz69 » 2011-03-03 00:53

Just a thought, have you got anything in the 'bind to local ip' field under settings>protocols>SMTP then the advanced tab

User avatar
mattg
Moderator
Moderator
Posts: 21025
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail Receiving Problems

Post by mattg » 2011-03-03 02:25

What are your server's local software firewall settings?
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-03 20:47

To respond to daz69: No, the field is blank. Is there supposed to be something there?
To respond to mattg: I just have the standard settings for Windows Firewall. Nothing fancy, nor have I configured it in anyway.

User avatar
daz69
Normal user
Normal user
Posts: 128
Joined: 2010-07-20 15:22
Location: Cornwall

Re: hMail Receiving Problems

Post by daz69 » 2011-03-03 21:02

Matt was asking because you do need to configure your servers firewall to accept inbound connections to the required ports at least 25, 110 and 143 if you're going to use IMAP.

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-03 22:55

Ok, so I just added exceptions in Windows Firewall for ports 25, 110, and 143. Guess what? It STILL doesn't receive mail. I did another Diagnostics test and now I get this error:

Test: Collect server details
hMailServer version: hMailServer 5.3.3-B1879
Database type: MSSQL Compact

Test: Test IPv6
IPv6 support is not available in operating system.

Test: Test outbound port
SMTP relayer not in use. Attempting mail.hmailserver.com:25
Trying to connect to host mail.hmailserver.com...
Trying to connect to TCP/IP address 83.169.11.240 on port 25.
Connected successfully.

Test: Test MX records
Trying to resolve MX records for homesap.redirectme.net...
Host name found: redirectme.net

Test: Test local connect
Connecting to TCP/IP address in MX records for local domain domain homesap.redirectme.net...
Trying to connect to host redirectme.net...
Trying to connect to TCP/IP address 204.16.252.112 on port 25.
ERROR: It was not possible to connect.
ERROR: Was not able to open connection.

rjk
Normal user
Normal user
Posts: 248
Joined: 2010-03-30 19:30
Location: uʍop ǝpısdn

Re: hMail Receiving Problems

Post by rjk » 2011-03-03 23:42

Well there is your problem. The MX records for your domain point to redirectme.net, which is incorrect - it needs to point to homesap.redirectme.net, which is your server. Does No-IP.com allow you to modify your MX records?
hMailServer 5.5.2-B2129 on Server 2008 R2 VM
MySQL 5.5.25, IIS 7.5, PHP 5.6.2 via FastCGI, RoundCube 1.0.3
XenServer 6.0 on HP DL380 G5 32GB RAM

robustrobot
Normal user
Normal user
Posts: 33
Joined: 2011-03-01 04:02

Re: hMail Receiving Problems

Post by robustrobot » 2011-03-04 18:01

YES!!!!!!!!!!!!!! It works! Thanks for that rjk. It seemed so obvious, but I think what happened is that when I had homesap.redirectme.net set as the MX record, it didn't work (for some other reason) so when I set it to just redirectme.net it passed diagnostics, which made me think it was working.Thanks to mattg and daz69 and anyone else who helped me, because I can guarantee that each one of you put me one step closer to making this work. Thanks all!

Post Reply