• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

A Backup Routine for us all

Yeah, you're covered for now, especially if you have both an internal and external sd card and you're copying both of them.

Thanks for your support and patience, please keep an eye here for future updates. :)

And better instructions by us. :D

And once everything's copied over and I format the card and partition it, I can just drag and drop the SD card files right back? I lost connections to games the last time even though I unmounted properly. They weren't recognized as existing by my tablet.
 
Upvote 0
Hey guys, sorry I'm pretty late to this party...yesterday's storms (and lightning strikes) put a bit of a damper on my availability and access here (my router got zapped).

Anyway, I couldn't necessarily tell from @hamstrman screenshot he first posted what issues he might have been having, but I spent some time this morning reviewing and updating the win-backup-sd.zip file and the backup-sd.bat script inside it. I also have created a short instruction list that might be helpful:

A. download the new-win-backup-sd.zip from the Attached Files section at the bottom of this post

this new-win-backup-sd.zip file is identical to the original one except I updated the adb files to use the newest ones from the http://androidforums.com/threads/adb-guide-updated-2014-11-11.443072/#post-5389081 post

B. extract the contents of the new-win-backup-sd.zip file that you just downloaded to your c:\ drive or your choice of a work directory (you can do this using winzip or winrar or the native Windows Explorer)

So, a general overview of what you'll need to have and do to use this Windows version of the win-backup-sd script:

1. working USB drivers on your Windows PC

2. USB debugging has been enabled on your device

3. your Android device has been connected to your Windows PC with a USB cable

4. if applicable, ensure you SD card is mounted as 'Charge only' instead of 'USB Mass Storage';
you might also need to temporarily disable MTP to allow adb to connect to your device

5. a download of the new-win-backup-sd.zip file as described above

6. extract the contents of the new-win-backup-sd.zip file to a work directory on your Windows PC

7. launch a Windows Command Prompt and change your directory to where the new-win-backup-sd.zip files were extracted

8. run the backup-sd.bat script and follow it's instructions

Code:
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Users\Scary Alien>cd \
C:\>cd win-backup-sd
C:\>win-backup-sd>dir
Volume in drive C has no label.
Volume Serial Number is 843C-52A5

Directory of C:\win-backup-sd

05/31/2015  12:29 PM    <DIR>          .
05/31/2015  12:29 PM    <DIR>          ..
11/11/2014  03:50 PM         1,009,664 adb.exe
11/11/2014  03:50 PM            96,256 AdbWinApi.dll
11/11/2014  03:50 PM            60,928 AdbWinUsbApi.dll
01/21/2013  08:49 PM            58,521 afutil.exe
05/31/2015  12:18 PM    <DIR>          android_storage_backups
05/31/2015  12:29 PM             7,984 backup-sd.bat
05/31/2015  11:38 AM             7,989 backup-sd.bat~
10/19/2012  07:40 AM         2,858,355 cygwin1.dll
               7 File(s)      4,099,697 bytes
               3 Dir(s)  321,491,255,296 bytes free

C:\win-backup-sd>backup-sd.bat
#
# ----------------------------------------------------------------------
# AndroidForums.com backup-sd.bat (version 31-May-2015)
#
#  Instructions:
#
#  1. make sure you have the proper adb USB drivers installed
#  2. make sure you have USB debugging enabled
#  3. make sure you device is connected to your computer via a USB cable
#  4. if applicable, ensure your SD card is mounted as 'Charge only'
#     instead of 'USB Mass Storage'; if your Android device supports MTP,
#     you might need to temporarily disable it for adb to work properly
#
# ----------------------------------------------------------------------
#
# Please reboot your device, then press the [Enter] key to
# start the backup or [control-c] to quit:
#
Press any key to continue . . .
#
# pwd:       C:\win-backup-sd\
# save_path: C:\win-backup-sd\android_storage_backups
# adb:       C:\win-backup-sd\adb.exe
# snum:      0441cbcc25237d8c
# nc:        1
# card1:     /mnt/shell/emulated
# card2:     none
# wdate:     20150531
# wtime:     1218
# target1:   C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218
# target2:   C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218_2nd
#
# okay, the real rubber hits the road here/now...
#
#
[about to do the actual backup--press [Enter] to continue]
[backup command: "C:\win-backup-sd\adb.exe" pull /mnt/shell/emulated "C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218"]
#
Press any key to continue . . .
# here we go...
pull: building file list...
pull: /mnt/shell/emulated/0/Ringtones/hangouts_incoming_call.ogg -> C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218/0/Ringtones/hangouts_incoming_call.ogg
:
:
pull: /mnt/shell/emulated/obb/.nomedia -> C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218/obb/.nomedia
611 files pulled. 0 files skipped.
2866 KB/s (256261136 bytes in 87.304s)
#
# no secondary SD card found needing to be backed-up
#
# backup started:   Sun 05/31/2015  12:18 PM
# backup completed: Sun 05/31/2015  12:20 PM
#
# all done! [press [Enter] to exit the script]
#
Press any key to continue . . .

C:\win-backup-sd>

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.

C:\Users\Scary Alien>cd \
C:\>cd win-backup-sd
C:\>win-backup-sd>dir
Volume in drive C has no label.
Volume Serial Number is 843C-52A5

Directory of C:\win-backup-sd

05/31/2015 12:29 PM <DIR> .
05/31/2015 12:29 PM <DIR> ..
11/11/2014 03:50 PM 1,009,664 adb.exe
11/11/2014 03:50 PM 96,256 AdbWinApi.dll
11/11/2014 03:50 PM 60,928 AdbWinUsbApi.dll
01/21/2013 08:49 PM 58,521 afutil.exe
05/31/2015 12:18 PM <DIR> android_storage_backups
05/31/2015 12:29 PM 7,984 backup-sd.bat
05/31/2015 11:38 AM 7,989 backup-sd.bat~
10/19/2012 07:40 AM 2,858,355 cygwin1.dll
7 File(s) 4,099,697 bytes
3 Dir(s) 321,491,255,296 bytes free

C:\win-backup-sd>backup-sd.bat
#
# ----------------------------------------------------------------------
# AndroidForums.com backup-sd.bat (version 31-May-2015)
#
# Instructions:
#
# 1. make sure you have the proper adb USB drivers installed
# 2. make sure you have USB debugging enabled
# 3. make sure you device is connected to your computer via a USB cable
# 4. if applicable, ensure your SD card is mounted as 'Charge only'
# instead of 'USB Mass Storage'; if your Android device supports MTP,
# you might need to temporarily disable it for adb to work properly
#
# ----------------------------------------------------------------------
#
# Please reboot your device, then press the [Enter] key to
# start the backup or [control-c] to quit:
#
Press any key to continue . . .
#
# pwd: C:\win-backup-sd\
# save_path: C:\win-backup-sd\android_storage_backups
# adb: C:\win-backup-sd\adb.exe
# snum: 0441cbcc25237d8c
# nc: 1
# card1: /mnt/shell/emulated
# card2: none
# wdate: 20150531
# wtime: 1218
# target1: C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218
# target2: C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218_2nd
#
# okay, the real rubber hits the road here/now...
#
#
[about to do the actual backup--press [Enter] to continue]
[backup command: "C:\win-backup-sd\adb.exe" pull /mnt/shell/emulated "C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218"]
#
Press any key to continue . . .
# here we go...
pull: building file list...
pull: /mnt/shell/emulated/0/Ringtones/hangouts_incoming_call.ogg -> C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218/0/Ringtones/hangouts_incoming_call.ogg
:
:
pull: /mnt/shell/emulated/obb/.nomedia -> C:\win-backup-sd\android_storage_backups\0441cbcc25237d8c_20150531_1218/obb/.nomedia
611 files pulled. 0 files skipped.
2866 KB/s (256261136 bytes in 87.304s)
#
# no secondary SD card found needing to be backed-up
#
# backup started: Sun 05/31/2015 12:18 PM
# backup completed: Sun 05/31/2015 12:20 PM
#
# all done! [press [Enter] to exit the script]
#
Press any key to continue . . .

C:\win-backup-sd>

Cheers!
 

Attachments

  • new-win-backup-sd.zip
    1.5 MB · Views: 632
Last edited:
Upvote 0
Quick question that you guys might be able to help with: is there an easy way to identify the REAL folder path for the internal memory and micro sdcard besides trial and error?

Example: My internal storage can be accessed via /mnt/media_rw/ via /storage/ via /sdcard/ and via /data/media/ the only way that I figured out the true path (/data/media/) was trial and error with the adb pull command (it wouldn't recognize the other paths.) The same thing was true of my attempts to pull my microSD. I have a feeling there's an easier way to figure this out, but I can't seem to turn it up (I'm probably searching for the wrong terms.) Suggestions?

PS. The automated backup files posted here (including the new one) do not work for me (I believe you know that already, though.) It looked like it identified the incorrect location of the internal storage (/mnt/media_rw/) which could have caused the failure. Doesn't matter really, because like I said, I'm using the 'pull' command to do what I need.
 
  • Like
Reactions: scary alien
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones