[Stable5] Exclude ext storage from quota

Raised a backport PR because this needed additional changes to fix the quota calculation which was different in OC 5.

Please review @karlitschek @kabum @icewind1991 @DeepDiver1975