Recently (who can track all those new kernels?) I've noticed that the commands in rc.local are not running, from which I conclude that it's not being executed. systemctl says: "rc-local.service (loaded active running)"
Any ideas.
On 05/15/2012 10:13 PM, Geoffrey Leach wrote:
Recently (who can track all those new kernels?) I've noticed that the commands in rc.local are not running, from which I conclude that it's not being executed. systemctl says: "rc-local.service (loaded active running)"
Any ideas.
If you can, please show us your /etc/rc.d/rc.local contents and file permissions. But that's weird, because I think usually it would give an error on starting up.
On 05/15/2012 03:23:03 PM, Bruno Martins wrote:
On 05/15/2012 10:13 PM, Geoffrey Leach wrote:
Recently (who can track all those new kernels?) I've noticed that the commands in rc.local are not running, from which I conclude that it's not being executed. systemctl says: "rc-local.service (loaded active running)"
Any ideas.
If you can, please show us your /etc/rc.d/rc.local contents and file permissions. But that's weird, because I think usually it would give an error on starting up.
root@puget[10]->cat /etc/rc.d/rc.local #! /bin/sh
# Run by /lib/systemd/system/rc-local.service
/usr/local/bin/check_running & systemctl restart nfs-lock.service systemctl restart nfs-idmap.service systemctl restart nfs-server.service /usr/bin/synclient TouchpadOff=1
exit 0
root@puget[11]->ls -l /etc/rc.d/rc.local -rwxr-xr-x 1 root root 239 May 14 21:16 /etc/rc.d/rc.local*
On Tue, 15 May 2012 16:52:08 -0700 Geoffrey Leach geoff@hughes.net wrote:
root@puget[10]->cat /etc/rc.d/rc.local #! /bin/sh
^ you have a " " here that shouldn't be there.
Should be simply: "#!/bin/sh"
kevin
On 05/17/2012 12:14 AM, Kevin Fenzi wrote:
On Tue, 15 May 2012 16:52:08 -0700 Geoffrey Leach geoff@hughes.net wrote:
root@puget[10]->cat /etc/rc.d/rc.local #! /bin/sh
^ you have a " " here that shouldn't be there.
Should be simply: "#!/bin/sh"
That was my theory too.... But I like to test my theories.... So I created an rc.local file with the following contents...
#! /bin/sh -e
#exit 0
touch /tmp/XXXX
and it worked just fine....
On 05/16/2012 09:14:11 AM, Kevin Fenzi wrote:
On Tue, 15 May 2012 16:52:08 -0700 Geoffrey Leach geoff@hughes.net wrote:
root@puget[10]->cat /etc/rc.d/rc.local #! /bin/sh
^ you have a " " here that shouldn't be there.
Should be simply: "#!/bin/sh"
Blush! The # is where it should be. Just a copy error.
On Wed, 16 May 2012 15:50:14 -0400 Tom Horsley horsley1953@gmail.com wrote:
On Wed, 16 May 2012 21:23:39 +0200 Heinz Diehl wrote:
This is not true, you can hav as many blanks as you like. Try it.
Not as many as you like - I think the exec() service looks only at about the first 32 characters or something like that.
I stand corrected. ;)
So, why are you restarting nfs services there?
The synclient won't work as rc.local has no connection to your DISPLAY to make changes.
How else are you seeing that commands there aren't running?
kevin
On 05/16/2012 03:15:24 PM, Kevin Fenzi wrote:
On Wed, 16 May 2012 15:50:14 -0400 Tom Horsley horsley1953@gmail.com wrote:
On Wed, 16 May 2012 21:23:39 +0200 Heinz Diehl wrote:
This is not true, you can hav as many blanks as you like. Try it.
Not as many as you like - I think the exec() service looks only at about the first 32 characters or something like that.
I stand corrected. ;)
So, why are you restarting nfs services there?
The synclient won't work as rc.local has no connection to your DISPLAY to make changes.
How else are you seeing that commands there aren't running?
Thanks for the tip on synclient
Restarting nfs services is being done because that was necessary in order to get a connection from the client. Admittedly that was several kernels ago :-)
On Wed, 16 May 2012 15:43:46 -0700 Geoffrey Leach geoff@hughes.net wrote:
Thanks for the tip on synclient
Restarting nfs services is being done because that was necessary in order to get a connection from the client. Admittedly that was several kernels ago :-)
Yeah, that seems odd. I'd just let systemd start them and then if something is not working, track that down and fix it.
kevin