<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Jan 22, 2016 at 11:17 PM, David Timothy Strauss <span dir="ltr"><<a href="mailto:david@davidstrauss.net" target="_blank">david@davidstrauss.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Rebooting an old thread now that we're finally testing this out.<br><div><br>> "strace" should do the job. It should give you a pretty good idea of all<br>
syscalls a process uses. That's what I used when testing SyscallFilters=.<br><br></div><div>This turns out to be less useful than it seems.<br><br>There are two major ways to invoke strace, each with caveats:<br><ul><li>Launch the process with strace. This captures everything from the first syscall to daemonized operation, but it's hard to create an equivalent context and environment versus how the service runs normally. This is especially bad for socket-activated services because 
those may actually use fewer or different syscalls than if they have to 
open their own listener sockets.<br></li><li>
Attach to an existing process. This allows seeing behavior under systemd, but it misses early service startup because the PID is only knowable after the service has started. We've specifically seen issues where some syscalls are only used in early service startup.</li></ul></div></div></blockquote><div>There's a third way:</div><div><br></div><div>ExecStart=/usr/bin/strace -D -ff -o /tmp/myservice.trace /usr/bin/myservlce --foo</div></div><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr">Mantas Mikulėnas <<a href="mailto:grawity@gmail.com" target="_blank">grawity@gmail.com</a>></div></div>
</div></div>