No Google search yielded a result for the origin of this phrase but the meaning is clear. When someone digs through layers of earth they eventually hit rock - which is at the bottom. You've gone as far down as you can go. Here's an interesting article about what hitting rock bottom means.