trying to transfer a large (13 GB) folder via USB to my phone with adb push
. if I try singular, smaller files they go through, pushing the whole folder hangs adb and then gets OOM killed.
adb pull
from phone #1 worked without issues, pushing it to phone #2 starts eating up all RAM (16 GB) and then gets killed. so I created a 16 GB swap file, swapon
, push - same thing, eats up all RAM, then all swap, then OOM manager kills konsole. no files are created on the phone.
transferring via MTP isn’t viable, it’s like 700 bytes/sec.
tried everything suggested here.
edit: tried adb over wifi, different terminal, same deal.
Create a tar, push it, then untar using adb shell?
works. still would like to know what the issue is with adb.
My guess it is zip’ping the directory in memory to send it as single zip file, hence use a lot of memory. Better to zip/tar directory yourself and send that file over.
possible. I tried it at one point with the
-Z
option, which should disable compression but no change, same result.
Fire up a trivial http server and download over http?