Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 23 Feb 2004 19:54:06 -0000
From:      "Dominic Bishop" <dom@bishnet.net>
To:        <freebsd-questions@FreeBSD.ORG>
Subject:   kern.shutdown_timeout sysctl
Message-ID:  <20040223195031.7C39F43D2F@mx1.FreeBSD.org>

next in thread | raw e-mail | index | archive | help
I just tried setting the value of the kern.shutdown_timeout sysctl and it
failed with:

sysctl: unknown oid 'kern.shutdown_timeout'

I am trying to increase the maximum time allowed for rc.shutdown to run for
reasons explained in my previous post "Help needed modifying shutdown
scripts"

>From the source code of init (ie init.c) it clearly reads the value of this
sysctl to override the default of 2 minutes:

if (sysctlbyname("kern.shutdown_timeout",
			 &shutdowntimeout,
			 &len, NULL, 0) == -1 || shutdowntimeout < 2)
	    shutdowntimeout = DEATH_SCRIPT;

But it appears that in reality this sysctl value doesn't exist, I looked
through sysctl.h and couldn't see it in there either.

Can I assume this is a bug and one or the other bit is wrong?

And is there anyway to fix this?

If it comes to it I can just override the default 2 minutes by altering the
#define in init.c but I would prefer to not hack the source and have to
re-edit after every src cvsup, especially since the sysctl would provide a
much neater way of accomplishing it.

Regards,

Dominic Bishop



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040223195031.7C39F43D2F>