Problem with index TTL and differences between Logical Data Size and Storage Size

We have seen that we have been near our limit of 40go, after having deleting a lot of document from a collection, we expected to lower it to not reach it. After the compact operation it has been ok, lower to 6go.

I understand that we have to do it manually but I don’t understand how do it on secondary ones.