public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug translator/12729] New: stap error message needs improvement
@ 2011-05-04 17:09 dsmith at redhat dot com
  2011-05-14 15:29 ` [Bug translator/12729] " fche at redhat dot com
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: dsmith at redhat dot com @ 2011-05-04 17:09 UTC (permalink / raw)
  To: systemtap

http://sourceware.org/bugzilla/show_bug.cgi?id=12729

           Summary: stap error message needs improvement
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap@sourceware.org
        ReportedBy: dsmith@redhat.com


Original attempt:

# stap -v -e 'probe begin { printf("hello\n") }'
Pass 1: parsed user script and 76 library script(s) using
150020virt/21580res/2040shr kb, in 90usr/0sys/99real ms.
Pass 2: analyzed script: 1 probe(s), 0 function(s), 0 embed(s), 0 global(s)
using 150556virt/22276res/2204shr kb, in 0usr/0sys/4real ms.
Pass 3: translated to C into
"/tmp/stapEq7Bvr/stap_12e49ab5f0b148f23233944cba45c6a2_649.c" using
150556virt/22440res/2360shr kb, in 0usr/0sys/0real ms.
Pass 4: compiled C into "stap_12e49ab5f0b148f23233944cba45c6a2_649.ko" in
2750usr/780sys/3600real ms.
Pass 5: starting run.
Pass 5: run completed in 0usr/0sys/0real ms.
Pass 5: run failed.  Try again with another '--vp 00001' option.

OK, so stap failed for some reason.  Let's take stap's suggestion and add
'--vp' (but bump it up to 5 because we *really* want to see what's going
wrong):

# stap -v --vp 00005 -e 'probe begin { printf("hello\n") }'
Pass 1: parsed user script and 76 library script(s) using
150020virt/21576res/2040shr kb, in 90usr/10sys/99real ms.
Pass 2: analyzed script: 1 probe(s), 0 function(s), 0 embed(s), 0 global(s)
using 150556virt/22268res/2204shr kb, in 0usr/0sys/4real ms.
Pass 3: using cached
/home/dsmith/.systemtap/cache/12/stap_12e49ab5f0b148f23233944cba45c6a2_649.c
Pass 4: using cached
/home/dsmith/.systemtap/cache/12/stap_12e49ab5f0b148f23233944cba45c6a2_649.ko
Pass 5: starting run.
Running /usr/local/bin/staprun -v -v
/tmp/stapfOABGl/stap_12e49ab5f0b148f23233944cba45c6a2_649.ko
Spawn waitpid result (0x7f00): 127
Pass 5: run completed in 0usr/0sys/0real ms.
Pass 5: run failed.  Try again with another '--vp 00001' option.
Running rm -rf /tmp/stapfOABGl
Spawn waitpid result (0x0): 0

Not much new information.  To find out what's wrong, let's run the staprun
command directly:

# /usr/local/bin/staprun -v -v
/tmp/stapfOABGl/stap_12e49ab5f0b148f23233944cba45c6a2_649.ko
bash: /usr/local/bin/staprun: Permission denied

Long story short, on this computer my account was only in the 'stapdev' group
and to use systemtap I'd need to be in both the 'stapdev' and 'stapusr' groups.

Systemtap needs a better error message here.  One possibility would be for the
stap executable to check for stapusr group membership before running staprun.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug translator/12729] stap error message needs improvement
  2011-05-04 17:09 [Bug translator/12729] New: stap error message needs improvement dsmith at redhat dot com
@ 2011-05-14 15:29 ` fche at redhat dot com
  2011-06-07 18:14 ` dsmith at redhat dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: fche at redhat dot com @ 2011-05-14 15:29 UTC (permalink / raw)
  To: systemtap

http://sourceware.org/bugzilla/show_bug.cgi?id=12729

Frank Ch. Eigler <fche at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |fche at redhat dot com
         Resolution|                            |FIXED

--- Comment #1 from Frank Ch. Eigler <fche at redhat dot com> 2011-05-14 15:28:34 UTC ---
Earlier commits have improved logging in this area.
commit 483cf56 does the last bit probably needed.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug translator/12729] stap error message needs improvement
  2011-05-04 17:09 [Bug translator/12729] New: stap error message needs improvement dsmith at redhat dot com
  2011-05-14 15:29 ` [Bug translator/12729] " fche at redhat dot com
@ 2011-06-07 18:14 ` dsmith at redhat dot com
  2011-06-07 18:35 ` fche at redhat dot com
  2011-06-08 15:38 ` lberk at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: dsmith at redhat dot com @ 2011-06-07 18:14 UTC (permalink / raw)
  To: systemtap

http://sourceware.org/bugzilla/show_bug.cgi?id=12729

David Smith <dsmith at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |

--- Comment #2 from David Smith <dsmith at redhat dot com> 2011-06-07 18:13:50 UTC ---
(In reply to comment #1)
> Earlier commits have improved logging in this area.
> commit 483cf56 does the last bit probably needed.

Even with commit 483cf56, I see the exact same output as in comment #1.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug translator/12729] stap error message needs improvement
  2011-05-04 17:09 [Bug translator/12729] New: stap error message needs improvement dsmith at redhat dot com
  2011-05-14 15:29 ` [Bug translator/12729] " fche at redhat dot com
  2011-06-07 18:14 ` dsmith at redhat dot com
@ 2011-06-07 18:35 ` fche at redhat dot com
  2011-06-08 15:38 ` lberk at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: fche at redhat dot com @ 2011-06-07 18:35 UTC (permalink / raw)
  To: systemtap

http://sourceware.org/bugzilla/show_bug.cgi?id=12729

--- Comment #3 from Frank Ch. Eigler <fche at redhat dot com> 2011-06-07 18:34:43 UTC ---
Unfortunately posix_spawnp() does not appear to give us -EPERM or
such detailed execve errors; it returns such errors instead with the
exit-status-127 catch-all that systemtap does print out (with stap -vv).

We could change remote.cxx users of stap_spawn / make_run_command()
to report that we had a problem launching staprun, like class
ssh_legacy_remote() does.

Or maybe util.cxx stap_spawn itself should print an error unconditionally upon
a failure.  (Are there any cases where stap_spawn's failure is supposed
to be an acceptable situation?)

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug translator/12729] stap error message needs improvement
  2011-05-04 17:09 [Bug translator/12729] New: stap error message needs improvement dsmith at redhat dot com
                   ` (2 preceding siblings ...)
  2011-06-07 18:35 ` fche at redhat dot com
@ 2011-06-08 15:38 ` lberk at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: lberk at redhat dot com @ 2011-06-08 15:38 UTC (permalink / raw)
  To: systemtap

http://sourceware.org/bugzilla/show_bug.cgi?id=12729

Lukas Berk <lberk at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lberk at redhat dot com
         AssignedTo|systemtap at sourceware dot |lberk at redhat dot com
                   |org                         |

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-06-08 15:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-04 17:09 [Bug translator/12729] New: stap error message needs improvement dsmith at redhat dot com
2011-05-14 15:29 ` [Bug translator/12729] " fche at redhat dot com
2011-06-07 18:14 ` dsmith at redhat dot com
2011-06-07 18:35 ` fche at redhat dot com
2011-06-08 15:38 ` lberk at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).