Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 520264 - sys-process/fcron: getconfig() script does issue any result
Summary: sys-process/fcron: getconfig() script does issue any result
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Thomas Deutschmann (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-19 17:49 UTC by Peter Volkov (RETIRED)
Modified: 2016-11-17 22:06 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Volkov (RETIRED) gentoo-dev 2014-08-19 17:49:23 UTC
From the init script:
getconfig() {
    # if there is no configuration file return the default value
    if ! [ -f $(configfile) ]; then
        echo $2
        return 0
    fi

    sed -n -e 's:^$1[ \t]*=[ \t]*::p' $(configfile)
}

As we se $1 is quoted with single quotes and thus sed always returns empty result. This causes no pidfile to start-stop-daemon and as such it fails to start fcron on system with fcron started inside lxc/openvz container:

redstation virt # /etc/init.d/fcron start
 * Starting fcron ...
 * start-stop-daemon: /usr/libexec/fcron is already running
 * Failed to start fcron                                                                                            [ !! ]
 * ERROR: fcron failed to start


sed argument should be quoted in double qoutes. Please fix or give me or to commit fix.
Comment 1 Thomas Deutschmann (RETIRED) gentoo-dev 2016-11-17 22:06:53 UTC
Thanks for the report. This is now fixed:

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=531e27c45e1f413da44d8a51ece0f59e454586fb