strace v5.11 releases: diagnostic, debugging and instructional userspace utility
strace – the Linux syscall tracer
strace is a diagnostic, debugging and instructional userspace utility for Linux. It is used to monitor and tamper with interactions between processes and the Linux kernel, which include system calls, signal deliveries, and changes of process state.
System administrators, diagnosticians, and troubleshooters will find it invaluable for solving problems with programs for which the source is not readily available since they do not need to be recompiled in order to trace them.
The operation of strace is made possible by the kernel feature known as ptrace.
Some of the features
- Attach to an already running process
- Filter by type of syscall
- Trace only system calls accessing given path
- Perform a full hexadecimal and ASCII dump of all the data read from/written to file descriptors
- Perform a syscall fault injection
- Count time, calls, and errors for each system call
Changelog v5.11
- Improvements
- Implemented poke injection (–inject=SET:poke_enter= and
–inject=SET:poke_exit= options). - Implemented decoding of epoll_pwait2 syscall introduced in Linux 5.11.
- Implemented decoding of GPIO_* ioctl commands.
- Implemented decoding of FS_IOC_FS[GS]ETXATTR, FS_IOC_[GS]ETFLAGS,
and FS_IOC32_[GS]ETFLAGS ioctl commands. - Implemented decoding of SIOCADDMULTI, SIOCDELMULTI, SIOCGIFENCAP,
SIOCOUTQNSD, SIOCSIFENCAP, and SIOCSIFHWBROADCAST ioctl commands. - Implemented decoding of UBI_IOCRPEB and UBI_IOCSPEB ioctl commands.
- Implemented decoding of V4L2_BUF_TYPE_META_CAPTURE,
V4L2_BUF_TYPE_META_OUTPUT, and VIDIOC_QUERY_EXT_CTRL ioctl commands. - Updated lists of BPF_*, BTRFS_*, CLOSE_RANGE_*, ETH_*, IORING_*, KVM_*,
PR_*, PTRACE_*, RTA_*, RTAX_*, RTM_*, RTNH_*, SCTP_*, SO_*, SYS_*, UFFD_*,
and V4L2_* constants. - Updated lists of ioctl commands from Linux 5.11.
- Implemented poke injection (–inject=SET:poke_enter= and
- Bug fixes
- Fixed decoding of SIOCGIFINDEX, SIOCBRADDIF, and SIOCBRDELIF ioctl commands.
- Fixed decoding of FIO[GS]ETOWN, SIOC[GS]PGRP, and SIOCATMARK ioctl commands
on alpha, mips, sh, and xtensa architectures. - Fixed fork–pidns-translation test on sparc and sparc64.
- Fixed build on hppa with uapi headers from Linux >= 5.10.
Install
git clone https://github.com/strace/strace.git cd strace ./configure && make && make install
Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
Copyright (c) 1995, 1996 Michael Elizabeth Chastain <mec@duracef.shout.net>
Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
Copyright (c) 1998-2001 Wichert Akkerman <wakkerma@deephackmode.org>
Copyright (c) 2001-2018 The strace developers.
All rights reserved.
Source: https://github.com/strace/