Try to use [SPWorkflowEventReceiver][1]. If I'm not wrong the [WorkflowPostponed][2] is invoked when the exception is thrown. In this method you have access to the [SPWorkflowEventProperties][3]. There are ErrorException and ErrorMessage properties that can be used by you.


  [1]: http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.workflow.spworkfloweventreceiver.aspx
  [2]: http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.workflow.spworkfloweventreceiver.workflowpostponed.aspx
  [3]: http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.workflow.spworkfloweventproperties_members.aspx