News for hackers. Stuff that matters.
Re:Ask HN: What Linux diagnostic tools/commands do you use? by bennofs on Saturday July 15, 2017 @06:32PM (#14779408)
strace - to see what a program is doing / where exactly something is failing if the error message is bad

ltrace - same as above, if strace is not enough

perf trace - if you don't know the exact process to strace upfront

https://github.com/brendangregg/perf-tools - to track disk accesses or exec calls

env LD_DEBUG=all - debugging dynamic linker issues

Re:Ask HN: What Linux diagnostic tools/commands do you use? by JosephRedfern on Saturday July 15, 2017 @06:17PM (#14779325)
I guess it depends what I'm trying to debug, but one thing that seems to be missing from your wrapper is quick logfile inspection. Tailing the last n lines of syslog (or something more specific) is often a good starting point when diagnosing problems.

Perhaps something that performs basic connectivity tests might be useful, too -- pinging the router, an external IP (like 8.8.8.8), and a FQDN (like google.com) would be a good quick test of both internal connectivity, external connectivity, and DNS resolver.

Re:Ask HN: What Linux diagnostic tools/commands do you use? by adampie on Saturday July 15, 2017 @06:32PM (#14779410)
Good idea, I will add that in once I figure out a better way to deal with the output; I feel like it needs to be cleaner. Might make it menu driven.
Re:Ask HN: What Linux diagnostic tools/commands do you use? by irundebian on Sunday July 16, 2017 @05:56AM (#14781324)
Have a look on this picture which maps subsystems to tools: http://www.brendangregg.com/linuxperf.html
Re:Ask HN: What Linux diagnostic tools/commands do you use? by lobster_johnson on Saturday July 15, 2017 @07:14PM (#14779625)
Per-process I/O and network metrics are super important. I usually use pidstat (-d flag gives you I/O) for this, or read data from /proc directly.
Re:Ask HN: What Linux diagnostic tools/commands do you use? by amingilani on Sunday July 16, 2017 @02:04AM (#14780732)
top, ps aux, which, find, ls, rm, cd, cat, echo, touch, pbcopy, ssh

That's pretty much it, otherwise I have a whole lot of cli tools too. Things like git, tmux, mosh, rails.. but I guess they don't count.

Re:Ask HN: What Linux diagnostic tools/commands do you use? by deckarep on Sunday July 16, 2017 @01:17PM (#14783001)
htop, iftop, ngrep, tcpdump, lsof, strace, wireshark, nc, telnet, ping, netstat, ps, grep, awk, pv, middleman, curl, jq, mitmproxy, tail, tr....

Okay, ok pretty much all of them. :)

Re:Ask HN: What Linux diagnostic tools/commands do you use? by assafmo on Sunday July 16, 2017 @03:32PM (#14783743)
mostly htop, iotop, pv -d...

EDIT: ... curl, jq, cat, less, grep, awk, lynx, watch, parallel, xargs, head, tail, sqlite3, rsync, scp...

Re:Ask HN: What Linux diagnostic tools/commands do you use? by b0n40 on Sunday July 16, 2017 @02:23AM (#14780791)
nc, tcpdump, ethtool, htop
Re:Ask HN: What Linux diagnostic tools/commands do you use? by gricardo99 on Sunday July 16, 2017 @01:53AM (#14780704)
lsof

netstat

strace

top