This is a follow-up to the question here: Sum of divisors below threshold. User "Lucia" gave an excellent answer there, and probably the question below is very closely related. Still, since I am not an expert in these things, I cannot figure out the solution (or the precise connection between the two problems). Any help is very much appreciated.
So here is the problem: Consider the set $\{1, \dots, n\}$, and assume that you remove from this set all the elements $m$ which satisfy $$ m \equiv 0 \mod d $$ for at least one divisor $d$ of $n$ which satisfies $d > D$. Question: How large do I have to take $D$ (as a function of $n$) such that the number of "surviving" elements is always at least $\varepsilon n$?