Not able to calibrate compass 2

I am using Pixhawk 1 with Arduplane 3.6 firmware and Mission Planner 1.3.46 build 1.1.6310.11669. I have been recently facing problems in calibrating my compass. The external compass or the compass 1 calibrates flawlessly, But for some reason there is no error correction or offsets saved for compass 2. I dont have any issues in arming and in Auto mode it flies without any issues (I have unchecked internal compass). But Mission planner throws an error as “Error compass variance” and " Bad compass health". The EKF also turns red. The wires are around 5 cm away from the autopilot or the external gps. I am worried that it will just go crazy sometime and might crash. Please Help.
Log file
04b48e.png" width=“690” height=“366”>

Update: Tried with latest MP beta and Arduplane 3.7.1. Onboard calibration stops at 30 % for mag 1 and rest remains uncalibrated

My cable connecting compass to the autopilot was faulty. Sorry for the trouble.