tl;dr
MTP sucks hard, and none of the free linux music players seem to have a reliable method for syncing a library subset (such as a playlist) to another device. rsync plus SSH plus ADB (and a little light shell scripting) to the rescue!
the problem
I have music in my library that is not and will never be available on streaming services (well, not until it is cost-effective to stream Plex from the home that is ;o). Consequently I need to have that music copied onto my phone. The set of files is a subset of my entire library and is around 25GB. Wireless syncing is all well and good, but I don’t need the sync to be wireless and wired would be way faster.
the solution
write a shell script that takes the path of your music library and a playlist file as input, then rsync’s the files listed in the playlist over SSH to a localhost port. How in hell is that useful? Well, rather conveniently, ADB allows you to map a local port to one on your connected phone:
adb forward tcp:2222 tcp:2222
So as long as you have an SSH server running on your phone on that port (I use SSHelper, author’s home page here) then the files will end up in SDCard/Music on the phone (this path is hard-coded in the script but obvious so can be changed). I get roughly 50MB/s transfer rate, which seems none too shabby; the whole 25GB playlist in around 11 minutes.
update 07.01.2024
rsync’s behaviour is such that it builds a temporary file list before performing any file movement actions. With a large playlist this means a long wait until the script attempts an ssh login to the phone, when one would have to enter the password configured in the SSH server software. This is an irritation, because if you don’t notice the prompt in time then the login will time out and you will have to start again from the beginning.
To avoid this (and gain improved security in passing) I recommend setting up public key authentication. The usual method for this is achieved entirely on the client side; assuming you already created your RSA key pair and are using the Android default SSH port the command would be :
ssh-copy-id -i ~/.ssh/id_rsa.pub -p 2222 127.0.0.1
If your Android SSH server supports it, you can then disable password authentication entirely. Thereafter rsync will be able to log in without user interaction, allowing the script to run to completion without your needing to keep an eye on it.