From owner-freebsd-doc@FreeBSD.ORG Sun Oct 19 14:00:10 2008 Return-Path: Delivered-To: freebsd-doc@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3619F106568A for ; Sun, 19 Oct 2008 14:00:10 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 133318FC0A for ; Sun, 19 Oct 2008 14:00:10 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id m9JE09wI034027 for ; Sun, 19 Oct 2008 14:00:09 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id m9JE09vJ034026; Sun, 19 Oct 2008 14:00:09 GMT (envelope-from gnats) Resent-Date: Sun, 19 Oct 2008 14:00:09 GMT Resent-Message-Id: <200810191400.m9JE09vJ034026@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-doc@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Mateusz Guzik Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D60921065688 for ; Sun, 19 Oct 2008 13:53:45 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id C52F08FC0A for ; Sun, 19 Oct 2008 13:53:45 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id m9JDrj3e055432 for ; Sun, 19 Oct 2008 13:53:45 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id m9JDrj00055431; Sun, 19 Oct 2008 13:53:45 GMT (envelope-from nobody) Message-Id: <200810191353.m9JDrj00055431@www.freebsd.org> Date: Sun, 19 Oct 2008 13:53:45 GMT From: Mateusz Guzik To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: docs/128222: [patch] man page truss(1) claims that init(8) can be traced X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Oct 2008 14:00:10 -0000 >Number: 128222 >Category: docs >Synopsis: [patch] man page truss(1) claims that init(8) can be traced >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-doc >State: open >Quarter: >Keywords: >Date-Required: >Class: doc-bug >Submitter-Id: current-users >Arrival-Date: Sun Oct 19 14:00:09 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Mateusz Guzik >Release: 8.0-CURRENT >Organization: >Environment: FreeBSD eternal 8.0-CURRENT FreeBSD 8.0-CURRENT #14: Mon Sep 15 17:38:51 CEST 2008 f@eternal:/usr/obj/usr/src/sys/ETERNAL i386 >Description: In truss(1) one can find the following: # Follow an already-running process $ truss -p 1 but: # truss -p 1 truss: can not attach to target process: Invalid argument (It fails because init(8) is marked as a system process and ptrace doesn't allow to trace these.) >How-To-Repeat: Run `trace -p 1` >Fix: Change pid 1 to for example 34, as in the man page for ktrace(1). Patch attached with submission follows: --- usr.bin/truss/truss.1.orig 2008-10-19 14:47:33.000000000 +0200 +++ usr.bin/truss/truss.1 2008-10-19 15:41:01.000000000 +0200 @@ -85,7 +85,7 @@ # Do the same, but put the output into a file .Dl $ truss -o /tmp/truss.out /bin/echo hello # Follow an already-running process -.Dl $ truss -p 1 +.Dl $ truss -p 34 .Sh SEE ALSO .Xr kdump 1 , .Xr ktrace 1 , >Release-Note: >Audit-Trail: >Unformatted: