[Dnsmasq-discuss] Android untracked pid on startup
Simon Kelley
simon at thekelleys.org.uk
Thu Oct 9 15:23:59 BST 2014
On 08/10/14 16:42, Kyle Manna wrote:
> Your issue is definitely related to Android's init system. Android
> has an init system (think extremely crippled systemd or launchd) that
> launches processes and restarts them when they die if so configured,
> among many other things.
>
> The init system on Android is complaining that your dnsmasq parent
> process is exiting and the init system doesn't know anything about it.
> This is likely because it was launched manually by you or by something
> else in Android. The process that generates the warning is the parent
> process that immediately exits after forking/daemonizing dnsmasq. The
> daemonized dnsmasq would generate a the same message with a different
> PID should it exit/crash. The message is mostly harmless, but
> suggests that you're not doing things the way Android init system
> expects.
>
> To fix this, modify your /init.<device>.rc file to have a dnsmasq
> service. You can start (or stop) the service with `start dnsmasq`.
> Should dnsmasq crash and die, the init system will detect this and
> restart it, unless oneshot is specified. Do include the the '-d' flag
> (or better yet the '-k' flag) so that process stays in the foreground
^^
This. -k is designed for use in this case, not -d.
Cheers,
Simon.
> and will signal it's caller (the init system) with a SIG_CHILD should
> it exit.
>
> On Wed, Oct 8, 2014 at 1:27 AM, Bruno De Paoli
> <bruno.depaoli at bluetreesystems.com> wrote:
>> I’m running dnsmasq on an Android Gingerbread platform acting as a wifi
>> Access Point. When dnsmasq starts up I get the following
>>
>>
>>
>> init: untracked pid 2407 exited
>>
>>
>>https://www1.firstdirect.com/1/2/!ut/p/c5/04_SB8K8xLLM9MSSzPy8xBz9CP0os3gDd-NQv1BDg2AXA3cP_2CXEFdDAwjQL8h2VAQAHpBRLQ!!/
>> I suspect it has something to do with dnsmasq changing its user id because
>> if I run it with dnsmasq –d then I don’t get this behaviour. Among other
>> things the –d option causes it to not change user Id. The dnsmasq process is
>> still running however and seems to behave so I’m unsure if this is really an
>> error. Here's the snippet of the 'ps' output, the pid of dmsmasq is always 1
>> higher than the pid in the message.
>>
>>
>>
>> app_20 2377 2083 93392 16024 ffffffff 6fd0c51c S com.cooliris.media
>>
>> nobody 2408 1 924 324 80206038 6fd0b45c S /system/bin/dnsmasq
>>
>> root 2409 2077 904 316 00000000 6fd0b45c R ps
>>
>>
>>
>> Having google'd this a bit it looks like an Android specific issue but there
>> is no definite explanation as to what can cause it.
>>
>> Has anyone seen this when running in an Android environment? Can anyone
>> suggest the cause?
>>
>>
>>
>> Thanks,
>>
>> Bruno
>>
>>
>>https://www1.firstdirect.com/1/2/!ut/p/c5/04_SB8K8xLLM9MSSzPy8xBz9CP0os3gDd-NQv1BDg2AXA3cP_2CXEFdDAwjQL8h2VAQAHpBRLQ!!/
>>
>> _______________________________________________
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss at lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
More information about the Dnsmasq-discuss
mailing list