You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Brandon Williams (JIRA)" <ji...@apache.org> on 2013/10/24 00:32:45 UTC

[jira] [Assigned] (CASSANDRA-6232) Installation shouldn't fail if /etc/sysctl.d/cassandra is deleted

     [ https://issues.apache.org/jira/browse/CASSANDRA-6232?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brandon Williams reassigned CASSANDRA-6232:
-------------------------------------------

    Assignee: Brandon Williams

> Installation shouldn't fail if /etc/sysctl.d/cassandra is deleted
> -----------------------------------------------------------------
>
>                 Key: CASSANDRA-6232
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-6232
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Packaging
>            Reporter: Faidon Liambotis
>            Assignee: Brandon Williams
>            Priority: Minor
>
> The Debian package's postinst currently has this snippet code, under the "configure" action (i.e. what runs when installing or upgrading):
> {code:none}
>         if ! sysctl -p /etc/sysctl.d/cassandra.conf; then
>             [...]
>             rm -v /etc/sysctl.d/cassandra.conf
>         fi
> {code}
> /etc/sysctl.d/cassandra.conf is a conffile and might be removed by the system administrator. The sysadmin might not want this sysctl setting or have an entirely different system of managing the /etc/sysctl.d hierarchy (in our case that would be puppet).
> Since this piece of code doesn't check for the existence and doesn't use rm's "-f" argument, if the file doesn't exist the rm call fails and the package installation is aborted.
> I'd propose checking for the file's existence instead of just "sysctl -p", so that you can avoid the nasty warnings too, but adding -f to rm shouldn't hurt either.
> Note that this would probably fail on package upgrades under OpenVZ too, which according to the error message should be a supported configuration.



--
This message was sent by Atlassian JIRA
(v6.1#6144)