I want to print in a log with the help of lsof
the information about opened resources but I don’t want the customer to see what libraries are used.
I browsed through the lsof man page but I cannot get a hold of how I can exclude only the libraries from the output. Is there an easy method to do this?
Advertisement
Answer
you can use sed, awk, cut for parsing output of lsof, show only those lines, which doesn’t have Lnn and ltx in their 4th field.