Starts with data logging, everything is logged. Then you inspect that area and look for anomalies in the metals in that area. At 5Gs, a little piece of wire becomes a razor blade and leaves evidence. A lot of odd nicks in an avionics bay will lead to testing, interviews and more testing. A worker has no reason to hide details, it would be criminal, so the interviews look at all the possible anomalies and then narrows down to the root cause.
Really amazing work, read NTSB crash reports and they outline the methods used