Creating a backup with adb results in 41 byte file I have an old droid RAZR Maxx (4.1.2) that I decided I want to root, but I want to make a backup first just in case. I've followed instructions from this site:

How To Create a Full Android Phone or Tablet Backup Without Rooting or Unlocking Your Device

My command was this:

adb backup -apk -shared -all -f c:\backup.ab


The resulting backup.ab file on the C: drive was only 41 bytes and, when opened in a hex editor, appears to only be the header of the backup file. I'm wondering what I'm doing wrong here, I've googled but can't find anything that helps. Any suggestions?

Edit: This is not a duplicate of the suggested a topic linked by beeshyams. That topic explains why the user couldn't back up one single app's files, I'm trying to back up everything. I don't care if I don't get SMS included in that backup because it's an old phone, I'm not using it to text, but there are other apps and settings that should back up without issue.
Found solution here, worked for me:

https://docs.j7k6.org/android-adb-backup-41-bytes-549-bytes-bug-fix/


  Appearantly the adb backup command stopped working for older Android
  devices in recent versions of the Android Debug Bridge. When invoking
  a backup with adb, the backup process is started but stops
  immediately, leaving a local backup.ab file with a filesize of only 49
  bytes (549 bytes when the backup is encrypted with a password). This
  bug is well known, but hasn’t been fixed at least until recently
  (version 1.0.39). To fix this behaviour, download the last working
  version of the adb executable (1.0.31) and invoke the backup with
  this. The executables for all platforms can be downloaded at Mozilla.


https://archive.mozilla.org/pub/labs/android-tools/

adb-1.0.31-linux.zip    479K    09-Sep-2015 18:44
adb-1.0.31-linux64.zip  455K    09-Sep-2015 18:44
adb-1.0.31-mac.zip  433K    09-Sep-2015 18:44
adb-1.0.31-windows.zip  474K    09-Sep-2015 18:44


Download, unzip, run unzipped adb:

(linux, mac)

./adb devices
./adb backup -apk -shared -all -f backup-file.adb


(win)

adb devices
adb backup -apk -shared -all -f backup-file.adb


Enjoy! ;)