# pop imap on gentoo doesn't work, why is this so hard???

## michal65

Here is my situation.  Sendmail on my gentoo server works.  I can send files from a mail client on another pc (mozilla, kmail), that's fine.  But when I try to retrieve mail via pop or imap from that gentoo server it just doesn't want to work.  Using wu-imap package pop and imap works locally because I can retrieve email via pop using a webmail client on the server.  When I try to get email using mozilla-mail or kmail it says the connection to 192.168.1.1 is bad.  What the heck does that mean?  I had debian before, everything worked like a charm.  I don't see any config files for wu-imap/pop stuff.

Can someone point me in the right direction?

gentoo kernel 2.4.20, no firewall

Thanks.

----------

## seaweed

Assuming that the imap/pop packages are setup and running.  You might want to check your hosts.deny and hosts.allow files.

----------

## seaweed

Assuming that the imap/pop packages are setup and running.  You might want to check your hosts.deny and hosts.allow files.

----------

## joycea

What error message do you get from your mail client?  Is there any error messages appearing the logs of your gentoo mail server?

----------

## michal65

My hosts.allow and hosts.deny don't exist so I created hosts.allow and added:

ALL:   192.168.1.6 (machine thats trying to get the pop mail)

Still nothing.

As far as logs are concerned, I couldn't find anything, btw which logs should I be looking at?

Usually there is no error message in Mozilla mail, it just says: "connecting to 192.168.1.1 ..."  and nothing else happens, sometimes I get "bad connection" error, sometimes I get no status and no error messages but it's just not pulling any mail.  Ilohamail which is on the same server as the sendmail and pop servers can grab mail via pop with no problem.

Any suggestions?

----------

## caffiend

what does 

```
telnet your.mailserver.ip 143
```

do for you?

If it actually connects try this test...

```
1 LOGIN username password
```

and see if that gets you anything helpful

----------

## michal65

When I try telnet 192.168.1.1 110 from my pc it gives me this and exits right away:

Trying 192.168.1.1...

Connected to 192.168.1.1.

Escape character is '^]'.

Connection closed by foreign host.

When I try the same thing from 192.168.1.1 it connects:

Trying 127.0.0.1...

Connected to localhost.

Escape character is '^]'.

+OK POP3 localhost v2001.78 server ready

What's preventing me from making a connection to that port from a different machine?

----------

## cjs94

Whenever I've had problems like that, on a private network, it has been due to the server not knowing the workstations.  Does the server have hosts entries for the workstations?

What about a firewall, I assume you don't have a default 'reject everything' rule on the server?

Chris

----------

## vision

I put an "only_from = 192.168.7.0/24" in the /etc/xinetd.d/ipop3 file.  I know this isn't the 100% proper way to fix it, but it got me up and running for the time being.

Hope this helps

Daryl

thorin2 xinetd.d # cat ipop3

# default: off

# $Header: /home/cvsroot/gentoo-x86/net-mail/uw-imap/files/uw-ipop3.xinetd,v 1.2 2002/06/07 02:01:38 woodchip Exp $

# description: The POP3 service allows remote users to access their mail \

#              using an POP3 client such as Netscape Communicator, mutt, \

#              or fetchmail.

service pop-3

{

        only_from               = 192.168.7.0/24

        socket_type             = stream

        wait                    = no

        user                    = root

        server                  = /usr/sbin/ipop3d

        log_on_success          += USERID

        log_on_failure          += USERID

        disable                 = no

}

----------

## Crocodile

edit /etc/xinetd.conf  and comment out:

only_from      = localhost

then restart xinetd

/etc/init.d/xinetd restart

Should fix your problem I suspect.

----------

## michal65

I changed the line only_from = localhost to 

only_from = 192.168.1.0/24    in xined.conf and it worked right away.

Thanks guys.

----------

