I have installed lineage os on a Samsung Galaxy S5. I tried to bring Link2SD to work. I gave it root access via the root add-on in lineageos. Link2SD complains about not being able to mount the 2nd partition which already had worked on a different Phone for the same purpose. I can unmount the second partition in Android settings and then it works, but after rebooting Link2sd can't mount the second partition, because the system already has mounted it.
How can I prevent Android from mounting the second partition before Link2SD can access it?
Android 7.1.2 Lineageos 14.1 20180411