Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jun 2010 11:33:10 +0400
From:      pluknet <pluknet@gmail.com>
To:        Andrey Zonov <andrey.zonov@gmail.com>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: How change process flags from userland?
Message-ID:  <AANLkTikU_KswcokmDN01cWI7Ms4IHGyVceVZV6weX_K2@mail.gmail.com>
In-Reply-To: <4C2AE37C.5060000@gmail.com>
References:  <4C2AE37C.5060000@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 30 June 2010 10:26, Andrey Zonov <andrey.zonov@gmail.com> wrote:
> Hi,
>
> I want to set P_PROTECTED flag for some daemons after it start, without
> patching application and kernel.
> It possible?
>

May be madvise(NULL, 0, MADV_PROTECT) will fit your needs?
(see howto example in usr.sbin/cron).
Note, this behav isn't portable.

-- 
wbr,
pluknet



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