Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Jan 2006 16:33:47 -0600
From:      Dan Nelson <dnelson@allantgroup.com>
To:        Proniewski Patrick <patrick.proniewski@univ-lyon2.fr>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: truss and procfs strange problem.
Message-ID:  <20060126223346.GH52542@dan.emsphone.com>
In-Reply-To: <C0F6D9BE-C8EA-4CCA-AC98-AE621291A305@univ-lyon2.fr>
References:  <6F2F4E06-712A-4E3D-9124-7AC7E1B964BD@univ-lyon2.fr> <20060126171333.GB52542@dan.emsphone.com> <C0F6D9BE-C8EA-4CCA-AC98-AE621291A305@univ-lyon2.fr>

next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Jan 26), Proniewski Patrick said:
> I have some new details :
> 
> >>	$ truss ls
> >>	truss: cannot open /proc/4509/mem: No such file or directory
> 
> in that case, the command issued as a truss argument (ls, ...) is
> stuck in state "D". `man ps` says it "Marks a process in disk (or
> other short term, uninterruptible) wait."

I think that's this case:

parent                        child
------                        -----
call fork()
fork() returns
                              (being created)
open /proc/%d/mem (fails)
                              (still being created)
                              creation complete, waiting
                              for parent to trace


> these process wont be killed, I'll have to reboot. (procctl won't
> clear the processes...)

You can continue tracing these processes if you run "truss -p <pid>",
since that's pretty much what they're waiting for :)

-- 
	Dan Nelson
	dnelson@allantgroup.com



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