Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 156358 - init script has a bug
Summary: init script has a bug
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: postfix
Version: 4.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: ---
Assignee: Thomas Woerner
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-04-29 11:42 UTC by Levente Farkas
Modified: 2007-11-30 22:07 UTC (History)
1 user (show)

Fixed In Version: 2.2.10-1.RHEL4.2
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-03-09 16:41:06 UTC


Attachments (Terms of Use)

Description Levente Farkas 2005-04-29 11:42:18 UTC
Description of problem:
this line of the script are wrong!:
/usr/sbin/postalias ${alias_database//,} 2>/dev/null
just try to use the following settings in your main.cf:
alias_database = hash:/etc/aliases, hash:$config_directory/aliases.lists
which is very common and corret while you not think about the usage of
$config_directory in this case

Version-Release number of selected component (if applicable):
2.1.5

How reproducible:
see baove

Steps to Reproduce:
1.
2.
3.
  
Actual results:
postfix/postalias[27541]: fatal: open /etc/aliases
hash:$config_directory/aliases.lists hash:$config_directory/aliases.groups: No
such file or directory

Expected results:
to works:-0

Additional info:

Comment 1 Anchor Systems Managed Hosting 2005-05-06 08:08:21 UTC
We are also experiencing this problem. It appears to be the same bug as
described in #139983 (Fedora Core 3) - related to the machine not being able to
resolve its own hostname.

Comment 2 Levente Farkas 2005-05-06 08:27:00 UTC
it has nothing to do with that bug. it's simple a error since the script can't
replace $config_directory to it's proper value (which is not so obvoius from a
shell script). it shoud lrun newalias without parameters (at let postfix find
the right values) rather then call postalias!

Comment 3 Anchor Systems Managed Hosting 2005-05-06 08:40:55 UTC
As far as I can tell $config_directory is not specified in /etc/init.d/postfix.
Furthermore newaliases also seg faults if run while the machine cannot resolve
its own hostname. It does not seem to matter what (if any) parameters are passed
to either postalias or newaliases, they will segfault every time until the
machine can resolve its own hostname.

Comment 4 Levente Farkas 2005-05-06 08:56:12 UTC
it seems you don't understand the problem here!
- it's legal (and advised) to use $config_directory in main.cf
- postalias parameters must be a valid path 
  /etc/postfix/aliases.lists is a valid path
  $config_directory/aliases.lists is NOT a valid path
so simple the init script writer of postfix do not think about it.
that's the problem!

Comment 5 Levente Farkas 2005-09-27 21:32:12 UTC
any progress???

Comment 6 Thomas Woerner 2005-11-11 14:22:22 UTC
Fixed in rawhide in package postfix-2.2.5-2.1, for now.

Comment 7 Thomas Woerner 2007-03-09 16:41:06 UTC
This has been fixed in U4 in package postfix-2.2.10-1.RHEL4.2.


Note You need to log in before you can comment on or make changes to this bug.