systemd: Is it wrong?
"Jóhann B. Guðmundsson"
johannbg at gmail.com
Fri Jul 8 13:15:29 UTC 2011
On 07/08/2011 12:41 PM, JB wrote:
> Johann,
> I think you are "fixing" it to work according to your world view :-)
>
Nope
> $ man sysctl
> ...
> SYNOPSIS
> ...
> sysctl [-n] [-e] [-q] -w variable=value ...
> ...
>
> So, if nfslock.service file contains:
> ...
> ExecStart=/sbin/sysctl -w fs.nfs.nlm_tcpport=$LOCKD_TCPPORT
> ...
>
> then this is the correct syntax.
>
> If this does not work as processed by systemd, then that means a bug ...
Or more likely this means that the content of the $LOCKD_TCPPORT
variable is not being delivered to /sbin/sysctl -w fs.nfs.nlm_tcpport=
Like for instance if he left it hashed out in the sysconfig file the
service would fail since fs.nfs.nlm_tcpport= is expecting to have some
value
as I explained on the bug report in comment 43
I repeatly asked to see that sysconfig file so I could diagnose the
problem further but I got responses like..
"How does your /etc/sysconfig file look like basically
why does this matter? Its the default one that is installed..."
( Which eventually led me to loose my cool because I really needed to
see what he was passing if any to that command something I'm not
particularly proud of )
So does not the default have the $LOCKD_TCPPORT line hashed out
#$LOCKD_TCPPORT which means you arent passing anything to /sbin/sysctl
-w fs.nfs.nlm_tcpport= which then would result in this..
[root at valhalla system]# /sbin/sysctl -w fs.nfs.nlm_tcpport=
error: Malformed setting "fs.nfs.nlm_tcpport="
And the service would fail to start..
Nothing to do with systemd to but everything to do with the command and
or the sysconfig file
Anyway I fixed his service and it works now as he wanted to be afaikt so
he should be happy and ships the native systemd service file which makes
me be happy and I can cross nfs off
https://fedoraproject.org/wiki/User:Johannbg/Features/SysVtoSystemd
JBG
More information about the devel
mailing list