strace Use Example - The Networked Client When an application serves as a network client, often tracing it can be used to identify networking problems. Lets see how a trace of a networked client looks: execve("/usr/bin/ftp", ["ftp", "actcom.co.il"], [/* 37 vars */]) = 0 uname({sys="Linux", node="simey", ...}) = 0 brk(0) = 0x8065b40 [.. snip ..] Now comes the interesting part - network address lookup. First, the /etc/nsswitch.conf is opened. Interesting? read the man page to know what it does. open("/etc/nsswitch.conf", O_RDONLY) = 3 fstat64(3, {st_mode=S_IFREG|0644, st_size=1744, ...}) = 0 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40013000 read(3, "#\n# /etc/nsswitch.conf\n#\n# An ex"..., 4096) = 1744 read(3, "", 4096) = 0 close(3) = 0 munmap(0x40013000, 4096) = 0