In January 2018, in Cape Town, South Africa, two engineers from NOC Southampton and a scientist from BAS. Cambridge, joined the Alfred Wegener Institute icebreaker RV Polarstern. Two months later, after a fascinating and eventful cruise, we docked in Punta Arenas, Chile. The Autosub Long Range AUV had completed two successful missions under the Filchner and Ronne ice shelves (and we had not lost it)! The AUV had run beneath ice for over 3 days in total, penetrating over 25 km under the Filchner and Ronne floating ice shelves, which in places were over 500 m thick.The scientific goals were to quantify and help to understand the controlling factors for the flow of waters (particularly warm, melting water) beneath the ice shelves and to make direct measurements of the ice shelf and sea bed morphology. The AUV carried a microstructure probe, CTD, upward and downward looking ADCPs (for measurement of currents and ranges to the ice and seabed), returning very interesting scientific data. However, the foci of this paper are the engineering challenges and how we overcame them to safely conduct the sub-ice missions.The Autosub Long Range (ALR) AUV is a 3.6 m long, 800 kg displacement AUV with a depth rating of 6000 m. Known by some as "Boaty McBoatface", it is capable of endurances of several months (depending on sensor power drain and speed), and runs at speeds of between 1.8 to 2.9 km hr-1. The AUV navigates using ADCP aided dead-reckoning, relative to either the seabed or the under ice surface. It can be programmed for constant depth or profiling flight, while keeping a safe distance from the seabed and the ice overhead.There were several technical challenges. The AUV navigation needed to be accurate, particularly as (due to sea ice conditions) the AUV could not simply surface at the end its mission (and thence easily relocated using a satellite beacon). Rather, the AUV must circle at depth and await further instructions from the host ship via acoustic telemetry (which has limited range). Achieving this navigation accuracy was encumbered by both high currents in the operating area and the (scientific) requirement for the AUV to make measurements a moderate distance from the sea bed (out of Doppler sea bed lock). Another potential exacerbating factor was the use of a magnetic compass for AUV heading estimation. For cost reasons (the ALR is designed as a relatively low cost AUV), and to minimize power consumption, the ALR carries a magnetic compass for heading estimation (rather than the more expensing and power hungry laser gyro based technologies). This technology would not normally be considered accurate enough for the precise navigation requirements. However, NOC has developed in-situ self-calibration procedures and algorithms, giving very good navigation performance, particularly for missions where the end point is near the start point. Another challenge was to autonomously control the AUV depth trajectory, safely avoiding, in a largely unknown environment, the ice shelf overhead and the seabed below.Not everything went perfectly; a problem which the AUV encountered 25 km under the Filchner ice shelf would have caused us great concern (to say the least) if we had known about what was happening in real-time. Fortunately we were blissfully ignorant until after recovery of the AUV. The paper will describe this near calamity and its possible root cause.Launch and recovery of the AUV was hampered in this environment by rapidly forming and shifting masses of sea ice and very cold temperatures. It was necessary for the ship to break ice and for us to guide the AUV into the ephemeral ice hole overhead via the acoustic telemetry link.