View previous topic :: View next topic |
Author |
Message |
Cyberwizzard Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Mon Mar 21, 2005 4:48 am Post subject: [solved] Courier-imap woes... |
|
|
After I found out the Postfix/Courier-imap/MySQL guide was updated in a way that my old install was next to useless (I needed to adjust some things - which ofcourse I didn't remember how to do) I decided to upgrade all packages and start over.
After a bit of tinkering with postfix and the courier-authlib packages I even managed to install courier-imap version 4.0.1 itself. 3 hours later after a lot of cursing and loads of googling I decided to throw in the towel and ask for help:
I got postfix to do its job again; its using the MySQL backend to authenticate users and deliver mail.
Brilliant, however, most people actually want to read their mail (silly I know, would've saved me loads of irritation if it wasn't so) and therefor need some POP or IMAP backend to retreive the email.
But after checking the configuration files hundreds of times I still can't log in on my server, not using pop3, not using imap. When I try to telnet my way in I get a "Connection closed by foreign host." immediately.
Now I might be able to track the problem down by looking at the logs, but here's the catch: there are no logs
I viewed every log file in /var/log and none show any entries of the imap or pop daemons - its like the programs don't even exist. Except for the fact that couriertcpd is running according to 'ps aux'.
Now why doesn't the imap server show up in the logs? Has it something to do with that courierlogger program? If so, why does it screw up or where is its config?
Last edited by Cyberwizzard on Mon Mar 21, 2005 5:31 am; edited 1 time in total |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
steveb Advocate
![Advocate Advocate](/images/ranks/rank-G-1-advocate.gif)
![](images/avatars/1198140199438f3db8ee800.gif)
Joined: 18 Sep 2002 Posts: 4564
|
Posted: Mon Mar 21, 2005 4:53 am Post subject: |
|
|
Post more stuff! Configuration and all that kind of things. Post as well, which version of courier, what type of encryption you use and and and.... |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Cyberwizzard Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Mon Mar 21, 2005 5:03 am Post subject: |
|
|
And as always I come up with the solution when I ask for help
It seems that the gentoo scripts are faulty: they invoke the wrong path for courierlogger when starting the couriertcpd program which in turn fails to start the daemons because of the logger not working...
In /usr/lib/courier-imap are the .rc scripts which fire up the service daemons - edit the files and replace the logger path to become:
Code: | -stderrlogger=/usr/sbin/courierlogger |
Do this for every service you want to use (in my case i just fixed imap and pop3, I won't be needing the SSL versions soon...) and fire up the /etc/init.d scripts again. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
steveb Advocate
![Advocate Advocate](/images/ranks/rank-G-1-advocate.gif)
![](images/avatars/1198140199438f3db8ee800.gif)
Joined: 18 Sep 2002 Posts: 4564
|
Posted: Mon Mar 21, 2005 5:19 am Post subject: |
|
|
on my installation: Code: | mail / # grep stderrlogger /usr/lib/courier-imap/*.rc
/usr/lib/courier-imap/gentoo-imapd-ssl.rc: -stderrlogger=/usr/lib/courier-imap/courierlogger \
/usr/lib/courier-imap/gentoo-imapd-ssl.rc: -stderrloggername=imapd-ssl \
/usr/lib/courier-imap/gentoo-imapd.rc: -stderrlogger=/usr/lib/courier-imap/courierlogger \
/usr/lib/courier-imap/gentoo-imapd.rc: -stderrloggername=imapd \
/usr/lib/courier-imap/gentoo-pop3d-ssl.rc: -stderrlogger=/usr/lib/courier-imap/courierlogger \
/usr/lib/courier-imap/gentoo-pop3d-ssl.rc: -stderrloggername=pop3d-ssl \
/usr/lib/courier-imap/gentoo-pop3d.rc: -stderrlogger=/usr/lib/courier-imap/courierlogger \
/usr/lib/courier-imap/gentoo-pop3d.rc: -stderrloggername=pop3d \
/usr/lib/courier-imap/imapd-ssl.rc: -stderrlogger=/usr/sbin/courierlogger \
/usr/lib/courier-imap/imapd-ssl.rc: -stderrloggername=imapd-ssl \
/usr/lib/courier-imap/imapd.rc: -stderrlogger=/usr/sbin/courierlogger \
/usr/lib/courier-imap/imapd.rc: -stderrloggername=imapd \
/usr/lib/courier-imap/pop3d-ssl.rc: -stderrlogger=/usr/sbin/courierlogger \
/usr/lib/courier-imap/pop3d-ssl.rc: -stderrloggername=pop3d-ssl \
/usr/lib/courier-imap/pop3d.rc: -stderrlogger=/usr/sbin/courierlogger \
/usr/lib/courier-imap/pop3d.rc: -stderrloggername=pop3d \
mail / # |
what is wrong with that? |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Cyberwizzard Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Mon Mar 21, 2005 5:31 am Post subject: |
|
|
The path to courierlogger was set to:
Code: | -stderrlogger=/usr/lib/courier-imap/courierlogger |
And that doesn't work because the program ain't there.... After changing it to /usr/sbin (using 'which' to locate the correct path) it works! I don't know which version you have but I just emerged all the packages without using masks and it seems that the default scripts use the wrong paths...
Anyway, after finding out that the new courier-libauth package uses a different location for its mysql configuration I got everything back up again! ![Very Happy :D](images/smiles/icon_biggrin.gif) |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
steveb Advocate
![Advocate Advocate](/images/ranks/rank-G-1-advocate.gif)
![](images/avatars/1198140199438f3db8ee800.gif)
Joined: 18 Sep 2002 Posts: 4564
|
Posted: Mon Mar 21, 2005 5:38 am Post subject: |
|
|
Cyberwizzard wrote: | The path to courierlogger was set to:
Code: | -stderrlogger=/usr/lib/courier-imap/courierlogger |
And that doesn't work because the program ain't there.... After changing it to /usr/sbin (using 'which' to locate the correct path) it works! I don't know which version you have but I just emerged all the packages without using masks and it seems that the default scripts use the wrong paths...
Anyway, after finding out that the new courier-libauth package uses a different location for its mysql configuration I got everything back up again! ![Very Happy :D](images/smiles/icon_biggrin.gif) | GREAT |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Cyberwizzard Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Mon Mar 21, 2005 5:41 am Post subject: |
|
|
LOL
Figures, I finally get a lightning fast response with one of my linux problems and it turns out to be something I fix when I go for a coffee ![Laughing :lol:](images/smiles/icon_lol.gif) |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
steveb Advocate
![Advocate Advocate](/images/ranks/rank-G-1-advocate.gif)
![](images/avatars/1198140199438f3db8ee800.gif)
Joined: 18 Sep 2002 Posts: 4564
|
Posted: Mon Mar 21, 2005 5:53 am Post subject: |
|
|
Cyberwizzard wrote: | LOL
Figures, I finally get a lightning fast response with one of my linux problems and it turns out to be something I fix when I go for a coffee ![Laughing :lol:](images/smiles/icon_lol.gif) | LOL |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Nicolinux Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/6054821313e6232494c94c.jpg)
Joined: 22 Dec 2002 Posts: 204
|
Posted: Mon Mar 21, 2005 7:36 pm Post subject: |
|
|
Cyberwizzard wrote: | The path to courierlogger was set to:
Code: | -stderrlogger=/usr/lib/courier-imap/courierlogger |
And that doesn't work because the program ain't there.... After changing it to /usr/sbin (using 'which' to locate the correct path) it works! I don't know which version you have but I just emerged all the packages without using masks and it seems that the default scripts use the wrong paths...
Anyway, after finding out that the new courier-libauth package uses a different location for its mysql configuration I got everything back up again! ![Very Happy :D](images/smiles/icon_biggrin.gif) |
Hi, I have courier-imap 3.0.8 and in /usr/lib/courier-imap/ is a link called "courierlogger" that points to /usr/sbin/courierlogger...
So courierlogger is there - but I still got no logs
Stefan |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Cyberwizzard Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Mon Mar 21, 2005 7:58 pm Post subject: |
|
|
Try changing the paths like I said to see if that makes a difference...
If it doesn't, try starting courierlogger by hand: provide the name for the syslog using one of the params and start typing. Every time you hit enter a new line in your logs should appear. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|