I would suggest something like this assuming you have a SIP trunk between Asterisk 1 (Originator) and Asterisk 2(Terminator).
(1) Create one channel variable with some uniqueID for a call on Asterisk 1 and pass this uniqueID in SIP header when forwarding call to Asterisk 2
(2) Store value of SIP header with uniqueID in a channel variable on Asterisk 2.
(3) Write a script (in your preferred language) to compare active channels on Asterisk 1 and Asterisk 2 using AMI and check the uniqueID present on one Asterisk server is available on other or not. If not then hangup the channel (using AMI).