How to check Timer job error on production server

I am new to sharepoint and want to ask a question. I have to deploy a custom timer job on production and if there will be an error on production then how to debug it. what are the different ways to capture that error.