Bug 196933 - mail/postfix-policyd-weight: rc.d script not working during boot
Summary: mail/postfix-policyd-weight: rc.d script not working during boot
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Olli Hauer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-20 15:20 UTC by Frank Reppin
Modified: 2015-01-20 22:43 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (ohauer)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Reppin 2015-01-20 15:20:28 UTC
OS:
====

FreeBSD amazone.undermydesk.org 10.1-STABLE FreeBSD 10.1-STABLE #0 r277236: Fri Jan 16 14:00:15 CET 2015     frank@undermydesk.org:/usr/obj/usr/src/sys/AMAZONE  amd64

problem description:
======================
policyd-weight rc.d script is not working during boot.

shebang in '/usr/local/bin/policyd-weight' is '#!/usr/bin/env perl'

My 'lang/perl5.20' doesn't come with a /usr/bin/perl symlink to /usr/local/bin/perl - and this is the obvious reason why the rc.d script doesn't
start policyd-weight during boot (beeing not in $PATH).
On the other hand - lang/perl5.20 didn't even offer to create a symlink iirc.

information about involved ports:
==================================
[root@amazone]/root/policyd-weight-usr-bin-env-perl-startup-during-boot-issue: pkg info postfix-policyd-weight
postfix-policyd-weight-0.1.15.2_3
Name           : postfix-policyd-weight
Version        : 0.1.15.2_3
Installed on   : Mon Jan 12 10:06:39 CET 2015
Origin         : mail/postfix-policyd-weight
Architecture   : freebsd:10:x86:64
Prefix         : /usr/local
Categories     : mail
Licenses       : GPLv2
Maintainer     : ohauer@FreeBSD.org
WWW            : http://www.policyd-weight.org
Comment        : Weighted policy daemon for postfix
Annotations    :
Flat size      : 151KiB
Description    :
Policyd-weight is (as the name says) a weighted policyd for Postfix.
It uses HELO, MAIL FROM and the MTA IP address for scoring their
correctness. It also uses definable DNSBLs and RHSBLs in a scored fashion.

WWW: http://www.policyd-weight.org

[root@amazone]/root/policyd-weight-usr-bin-env-perl-startup-during-boot-issue: pkg info perl5.20
perl5.20-5.20.1_10
Name           : perl5.20
Version        : 5.20.1_10
Installed on   : Wed Dec 17 20:07:24 CET 2014
Origin         : lang/perl5.20
Architecture   : freebsd:10:x86:64
Prefix         : /usr/local
Categories     : perl5 lang devel
Licenses       : GPLv1 or ART10
Maintainer     : perl@FreeBSD.org
WWW            : http://www.perl.org/
Comment        : Practical Extraction and Report Language
Options        :
	DEBUG          : off
	GDBM           : off
	MULTIPLICITY   : on
	PERL_64BITINT  : on
	PERL_MALLOC    : off
	PTHREAD        : on
	SITECUSTOMIZE  : off
	THREADS        : on
Shared Libs provided:
	libperl.so.5.20
Annotations    :
	cpe            : cpe:2.3:a:perl:perl:5.20.1:::::freebsd10:x64:10
Flat size      : 48.9MiB
Description    :
Perl is a language that combines some of the features of C, sed, awk and
shell.  See the manual page for more hype.  There are also many books
published by O'Reilly & Assoc.  See pod/perlbook.pod for more
information.

WWW: http://www.perl.org/


rc_debug=yes gives:
=====================
/etc/rc: DEBUG: checkyesno: policyd_weight_enable is set to YES.
/etc/rc: DEBUG: run_rc_command: doit: policyd_weight_start 
env: perl: No such file or directory

Not sure, but probably also related to:
  http://svnweb.freebsd.org/ports/head/Mk/Uses/shebangfix.mk
Comment 1 Bugzilla Automation freebsd_committer freebsd_triage 2015-01-20 15:20:28 UTC
Auto-assigned to maintainer ohauer@FreeBSD.org
Comment 2 commit-hook freebsd_committer freebsd_triage 2015-01-20 22:09:55 UTC
A commit references this bug:

Author: ohauer
Date: Tue Jan 20 22:09:50 UTC 2015
New revision: 377545
URL: https://svnweb.freebsd.org/changeset/ports/377545

Log:
  - use absolute perl path,
    seems '/usr/bin/env perl' does not play nice
    with perl 5.20 during system restarts

  PR:		196933
  Submitted by:	Frank Reppin

Changes:
  head/mail/postfix-policyd-weight/Makefile
Comment 3 Olli Hauer freebsd_committer freebsd_triage 2015-01-20 22:43:43 UTC
Thanks for the detailed report and diagnose of the failure!

The updated port uses the full perl path and should work with perl5.20.