Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,737,675 Members 46,718 Now Online
XDA Developers Android and Mobile Development Forum

[APP] Scheduled Automatic CWM Nandroid Backup - Intika Automatic Backup MoD

Tip us?
 
intika
Old
(Last edited by intika; 21st July 2012 at 04:26 AM.) Reason: error on script
#1  
intika's Avatar
Senior Member - OP
Thanks Meter 186
Posts: 152
Join Date: Dec 2008

 
DONATE TO ME
Talking [APP] Scheduled Automatic CWM Nandroid Backup - Intika Automatic Backup MoD

Waw Grrrr... a whole day to make it possible
as i never posted... i can not post link... so google is your friend for downloading lol
Here is a little tutorial to make

Scheduled Automatic CWM Nandroid Backup


Intika Automatic Backup MoD ^^



First what you need :
- Rooted device
- CWM Recovery
- Application SL4A (Free google dev. sl4a_r5.apk)
- Apllication "TaskBomb Task Scheduler" (Free on market)
- Application "SL4A Script Launcher" (Free plugin on market)
- A Script to do the stuff


How it work ? :
The idea is simple, it's running an automated task with a script without any interact... the Automated nandroid backup will erase her self for a new one when the task is launched...
the backup is always made at the same place under your clockworkmod backup folder "IntikaAutomaticTask" so it will always take the size of one backup even if the task is scheduled every day ... and naturally you will keep your manually make backup.
You can set up the backup to made different backup of keep 3 last one or else... not explained but easy to do with TaskBomb


The Script For a backup to "sdcard/clockworkmod" :
Code:
Select Code
cd \ ;
mkdir -p /cache/recovery ; 
rm /cache/recovery/mounter? ;
rm /cache/recovery/extendedcommand? ;
rm /cache/recovery/mounter ;
rm /cache/recovery/extendedcommand ;
echo '#!/sbin/ext/busybox sh' > /cache/recovery/mounter ;
echo '/sbin/ext/busybox mount /sdcard' >> /cache/recovery/mounter ;
echo '/sbin/ext/busybox mount /dev/block/mmcblk1p1 /emmc' >> /cache/recovery/mounter ;
echo '/sbin/ext/busybox rm /cache/recovery/mounter' >> /cache/recovery/mounter ;
chmod 777 /cache/recovery/mounter ;
echo 'run_program("/cache/recovery/mounter");' > /cache/recovery/extendedcommand ;
echo 'ui_print("Intika Backup MoD... Processing Backup...");' > /cache/recovery/extendedcommand ;
echo 'backup_rom("/emmc/clockworkmod/backup/IntikaAutomaticTask");' >> /cache/recovery/extendedcommand ;
sync ;
echo 1 > /sdcard/external_sd/clockworkmod/.recoverycheckpoint ;  
echo 1 > /sdcard/clockworkmod/.recoverycheckpoint ;  
sync ;
reboot recovery ;

The Script For a backup to "sdcard/external_sd/clockworkmod" :
Code:
Select Code
cd \ ;
mkdir -p /cache/recovery ; 
rm /cache/recovery/mounter? ;
rm /cache/recovery/extendedcommand? ;
rm /cache/recovery/mounter ;
rm /cache/recovery/extendedcommand ;
echo '#!/sbin/ext/busybox sh' > /cache/recovery/mounter ;
echo '/sbin/ext/busybox mount /sdcard' >> /cache/recovery/mounter ;
echo '/sbin/ext/busybox mount /dev/block/mmcblk1p1 /emmc' >> /cache/recovery/mounter ;
echo '/sbin/ext/busybox rm /cache/recovery/mounter' >> /cache/recovery/mounter ;
chmod 777 /cache/recovery/mounter ;
echo 'run_program("/cache/recovery/mounter");' > /cache/recovery/extendedcommand ;
echo 'ui_print("Intika Backup MoD... Processing Backup...");' > /cache/recovery/extendedcommand ;
echo 'backup_rom("/sdcard/clockworkmod/backup/IntikaAutomaticTask");' >> /cache/recovery/extendedcommand ;
sync ;
echo 1 > /sdcard/external_sd/clockworkmod/.recoverycheckpoint ;  
echo 1 > /sdcard/clockworkmod/.recoverycheckpoint ;  
sync ;
reboot recovery ;

Installing needed stuff :
Considering you have a rooted device and CWM installed...
You can use different file and folder name regarding the tutorial

1. Copy the scripts to your device and name it backup.sh and backup.ext.sh
1.1 Copy the script to :
1.1 \sdcard\Intika.Backup.MoD\backup.sh
1.2 \sdcard\Intika.Backup.MoD\backup.ext.sh
1.3 You can test the script with a terminal by writing this
Code:
Select Code
su -c sh \sdcard\Intika.Backup.MoD\backup.sh
2. Install SL4A (Free google dev. sl4a_r5.apk)
3. Install "TaskBomb Task Scheduler" (Free on market)
4. Install "SL4A Script Launcher" (Free plugin on market)


How to Setup ? :
1. Open SL4A hit menu and then "add" select "Shell" if you are asked to select the application to continue with select SL4A... put backup.sh or backup.ext.sh on the title and put the code below on the script after that hit menu and then "save & exit"
Code:
Select Code
su -c sh \sdcard\Intika.Backup.MoD\backup.sh
or
Code:
Select Code
su -c sh \sdcard\Intika.Backup.MoD\backup.ext.sh
2. Open TaskBomb hit "Task" click " + " to add a new one , on action type leave or set VIEW and on data choose "Select script" and choose backup.sh ... on Activity choose background or foreground if you want to see when the script is launched.

3. Here we are, we just need to specify when to run the task ... on TaskBomb hit Alarm and then " + " and then select the wanted script
choose a start time and then the day you want to launch the backup.


Bla Bla :

AAAhhhhhh !!!!!!! finally get it work after many research and after trying Rom Manager (not working with every device and he tray to install an other CWM "very dangerous" )

My way is not the only one

Any way good luck
The Following 2 Users Say Thank You to intika For This Useful Post: [ Click to Expand ]
 
intika
Old
#2  
intika's Avatar
Senior Member - OP
Thanks Meter 186
Posts: 152
Join Date: Dec 2008

 
DONATE TO ME
I don't have the time for the moment but when i got some free time i will make an application to do the stuff
 
LA_
Old
#3  
Junior Member
Thanks Meter 0
Posts: 29
Join Date: Sep 2009
Could you please explain how it works? Does it reboot your phone to make backup?
 
intika
Old
#4  
intika's Avatar
Senior Member - OP
Thanks Meter 186
Posts: 152
Join Date: Dec 2008

 
DONATE TO ME
Hello

Here what it do :

1. Set a backup at a time and day (or every day or every week or what you want regarding time and repetition)

2. On selected time, the phone reboot to recovery without any interact make the backup (every think is displayed) ... once finish it reboot the phone to normal state.

example you set to make a backup every day at 4h o clock... your phone will reboot and make the backup and then restart to normal mode... so when you wake up you just have to enter the Code pin of the phone or just unlock it if it's does not ask for a code pin.
 
LA_
Old
#5  
Junior Member
Thanks Meter 0
Posts: 29
Join Date: Sep 2009
Ok, so user will have to input PIN... not like that really.
 
intika
Old
#6  
intika's Avatar
Senior Member - OP
Thanks Meter 186
Posts: 152
Join Date: Dec 2008

 
DONATE TO ME
best stable backup are backup made from recovery...

generally we would make an automatic backup when we are not using the phone so at night... so it's not really a problem to do not have incoming call after backup until the pin is entered...

any way all other stuff like wake up alarm and other application will be running they don't need the pin to be entered ! ...

you can also remove pin request and put just a code to unlock the screen, it's a solution if you want to be reachable any time...
 
kemikelx
Old
#7  
Member
Thanks Meter 8
Posts: 63
Join Date: Jul 2011
Quote:
Originally Posted by LA_ View Post
Ok, so user will have to input PIN... not like that really.
I think intika means that it will reboot once the backup are done.
The pin input is normal if you enabled it in security settings. It happens when you reboot your phone.

---------- Post added at 05:06 PM ---------- Previous post was at 05:01 PM ----------

Quote:
Originally Posted by intika View Post
Bla Bla :

AAAhhhhhh !!!!!!! finally get it work after many research and after trying Rom Manager (not working with every device and he tray to install an other CWM "very dangerous" )

My way is not the only one

Any way good luck
Any screenshots for this? Seems like the script is too simple to be true.
 
ktoonsez
Old
#8  
ktoonsez's Avatar
Recognized Contributor / Recognized Developer
Thanks Meter 37714
Posts: 13,767
Join Date: Nov 2011
Location: Tempe

 
DONATE TO ME
Is there a command to stop Recovery from rebooting? I have an OTA app that flashes a ROM and I want Recovery to stay in it and not just auto reboot, because the user might want to install gapps before rebooting.

If you like my work, donate with this link:
http://forum.xda-developers.com/dona....php?u=4325945
_____________________________
Do NOT flash my kernels if you are allergic to AWESOME!!!!!!!!!!!!!!!
_____________________________
 
hawk1996
Old
#9  
Junior Member
Thanks Meter 0
Posts: 1
Join Date: Jul 2009
Sorry to bump an old thread, but has anyone gotten this to work? I really miss the automated full backup from my windows mobile device.
 
VampiruX
Old
(Last edited by VampiruX; 16th September 2012 at 02:08 AM.)
#10  
Member
Thanks Meter 3
Posts: 72
Join Date: Jan 2007
Sorry, mistake.

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes