Highly recommend using rr if you're in an environment that supports it. Once you've learned to use it, it feels like a debugging superpower. You can use most of the gdb commands you are familiar with, and most of the gdb interfaces listed here will still work.
The docs are here: https://rr-project.org/