random server crashes

can someone tell me how to get my server to log whats making the server crash or were to look ?
thanks