Avinash Duggirala
Avinash Duggirala

Reputation: 371

remote secure_mkdirs failed: Operation not permitted adb: error: failed to read copy response

I am having a mobile with following configurations:

I enabled developer options and USB debugging and I am able to execute adb devices, adb install filename.apk.

I need to push some bin and python files into the location /sdcard/Android/data/com.company.lc.us.lm/files/.

I am using this command:

adb push MyFolder /sdcard/Android/data/com.company.lc.us.lm/files/

Following is the error I am getting:

remote secure_mkdirs failed: Operation not permitted adb: error: failed to read copy response

I had gone through multiple threads with this error. Most of the solutions needs to root the mobile phone. I actually dont want to root my phone as in my remaining samsung phones I am able to adb push successfully without any error without root.

Had anyone faced this issue? If so please let me know the solution. Thanks in advance.

Upvotes: 6

Views: 11387

Answers (1)

Semmu
Semmu

Reputation: 133

i had this same error when trying to push a whole directory to an android device. it uploaded the first file in the directory (which took time), but failed immediately when trying to actually create the file on the other end. but it DID create the directory for the file, so the second time the same push command worked without issues.

my workaround is to create the directory first (with adb shell mkdir) before pushing a directory of files to the device. that works flawlessly every time.

this is a very strange and silly bug in adb to be honest.

Upvotes: 2

Related Questions