First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 88574
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Net-Mail Packages <net-mail@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Alexander Stoll <as@ha-networks.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
gld my init script for gld text/plain Alexander Stoll 2005-04-11 02:09 0000 322 bytes Details
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 88574 depends on: Show dependency tree
Show dependency graph
Bug 88574 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)







View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-04-10 04:56 0000
The provided init script does not appropriate dependency checking for proper
startup:

In /etc/init.d/gld
depend() {
        need
        use dns
        before postfix
}

should be

depend() {
        need net
        use dns mysql
        before postfix
}

need -> "net"  if mysql database is not local
use -> "mysql" to start AFTER local mysql database

Without this and not running / reachable mysql database the daemon dies at
startup and leaves you in worst case with a non functional postfix which
rejects all email and this is no fun... ;-)

Reproducible: Always
Steps to Reproduce:
1.setup postfix, mysql, gld
2.boot up
3.gld is not started if mysql is not running

Actual Results:  
postfix rejects email

Expected Results:  
proper startup of gld, functional greylisting for postfix

------- Comment #1 From Alexander Stoll 2005-04-11 02:09:04 0000 -------
Created an attachment (id=55965) [edit]
my init script for gld

Since the startup is also time critical, I

------- Comment #2 From Alexander Stoll 2005-04-11 02:09:04 0000 -------
Created an attachment (id=55965) [edit]
my init script for gld

Since the startup is also time critical, I´ve added a "sleep 3" to give mysql a
little time to load so that gld can connect to the service. This is a bit ugly
since heavy dependend on the local maschine if this is enough time to load all
mysql databases...
It should be replaced by a loop that checks for the mysql pid, maybe issuse a
"sql ping" with connection data in gld.conf and if this succeds, fire up gld...

------- Comment #3 From Tom Martin (RETIRED) 2005-04-20 08:13:58 0000 -------
Okay, I've made these changes, however, I don't see the MySQL not being
properly started as a problem we should have to fix in the gld init script. The
MySQL init script shouldn't eend $? before it's running completely. Feel free
to reopen if you still feel differently.

Thanks for the fixes, Alexander!

------- Comment #4 From Alexander Stoll 2005-04-26 02:04:51 0000 -------
After having time to look further into init scripts, I have to agree that the
mysql init script is the place to fix that time critical startup since other
applications are highly likely to be affected too...
Some last thing on gld before this goes stable, a dedicated user with least
priviledges for this program should be generated at install time, but I will
file a new bug regarding this... (#90468)

------- Comment #5 From Francesco R. (RETIRED) 2005-04-26 06:13:43 0000 -------
bug referred in #c3 is bug# 90471

First Last Prev Next    No search results available      Search page      Enter new bug