[Android Apps and Games] tag68:
The requirements for OTA are changing. I'm not sure what must be untouched. Until KitKat you undid system changes (deactivate AdAway, restore original build.prop, original kernel and recovery, uninstall xposed and logo iirc - nearly all could be avoided, I always kept a list what I did and I tried to keep it small), did a unroot and could do OTA.

With Lollipop the update was changed from file oriented to block oriented. But the check was not changed. That means it can work, but it is not sure. If you care about the contents of your partitions OTA should work after the original boot partition is restored as this is the only thing which gets modified by systemless root (if you don't change build.prop, logo, recovery). I don't know if boot partition is checked in the meantime, it was said there was a time in lollipop where you could do OTA without unroot. Never tested it myself.

You see, there are no guarantees. So my idea is:

1. Do a Nandroid backup before rooting.

2. Do a Nandroid backup before OTA

3. Just try what you want, many things that one doesn't expect work fine - but you can't rely on them. That's what you got backups for.

It makes things easier if you don't touch system by activating AdAway. But I did exactly that what you did now when I changed from lollipop to marshmallow on Moto X Play: having a modified hosts directly on system, deactivate AdAway, did unroot, and the OTA worked fine. That unroot probably wasn't necessary, at that time I wasn't aware of what systemless root does. But I was lucky: I didn't know about that change to block oriented behavior. If any contents of the partition is changed anyway, like from lollipop to marshmallow, it does work by accident. Update from marshmallow to nougat has a good probability to work fine, although you activated and deactivated AdAway directly on system.

You want to know if it works but are not sure? Do a Nandroid, and you can go back to the point where it worked.

Oh, I must add that I never flash twrp. I'm always using fastboot boot twrp via cable when I want to do Nandroid backup or change anything, so my recovery stays original. This of course is also a condition that it works.

Disadvantage these days: Nandroid on Moto Z Play is unreliable! I don't know why, if it is the Chinese twrp or some other bug. Trying to restore Nandroid always failed and let me flash an older ROM and do an orgy of about 4-5 updates until being current which consumed a lot of time. But fortunately it was never a problem keeping userdata (data partition) untouched. So all backups being worthless didn't harm when flashing older ROM without erase userdata.

[MENTION=528201]NLBeev[/MENTION], it is wrong that OTA for rooted devices does not work in general. Not touching system is one of the preconditions to make it work. Since lollipop it's not that easy, but possible.

That's why I remarked at some place in this thread that AdAway could warn when you are touching system, although your root is systemless and you may have the idea of leaving system untouched Passing SafetyNet when hiding SU or unroot, doing OTA get much more complicated if you touch it - and it is not necessary nowadays.