To configure Automatic Backup batch file properly follow the below Steps:
First Download the Automatic Backup batch file Click Here
See the comprehensive Video Tutorial on YouTube to configure this:-
https://www.youtube.com/watch?v=UFuvZaCleT0
[ C:\Backups-All\ ]
Step 2. Open the following file [ C:\Backups-All\Schedul-backup-Task.xml ] into the text editor and replace the following TECH.PETERCRYS.COM\Administrator with your computer name\user name and save. See the below example:
<!-- Change below TECH.PETERCRYS.COM\Administrator with your computer name\user name -->
<Author>TECH.PETERCRYS.COM\Administrator</Author>
<!-- Change below TECH.PETERCRYS.COM\Administrator with your computer name\user name -->
<UserId>TECH.PETERCRYS.COM\Administrator</UserId>
Open the Task Scheduler goto -> run -> taskschd.msc
On the Task Scheduler click on Action -> Import Task -> [ C:\Backups-All\Schedul-backup-Task.xml ] See the below example:
Schedul-backup-Task.xml : This will backup your the data at 11:00 AM everyday
Note: You can edit the scheduled task anytime you want by double-clicking task -> target -> edit
Once you have completed the above steps do the following:
Open the following file [ C:\Backups-All\backup.bat ] into the text editor. Find the row where it says
[ Path of the source and destination of the backup folder ]
This will look something like this:-
-----
%backupbatch% "D:\Work\*.*" "e:\backup\work\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\Desktop\ppt\*.*" "e:\backup\ppt\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\AppData\Local\Microsoft\Outlook\*.*" "e:\backup\outlook\"
%backupbatch% "e:\backup\*.*" "\\192.168.1.100\backup"
-----
Here you have to change the path for example the source is [ D:\Work\ ] and the destination of the backup folder is [ e:\backup\work\ ]
Wild card [ *.* ]
To take the backup in separate folders you can use [ %TIMESTAMP% ] at the end of the destination folder path [ e:\backup\work\%TIMESTAMP% ].
See the comprehensive Video Tutorial on YouTube to configure this:-
https://www.youtube.com/watch?v=UFuvZaCleT0
[=================================]
[=================================]
@echo OFF
:: ====================================================================================
:: = THis batch file is Created by: Sachin Samy =
:: = For comprehensive videos tutorial visit: http://www.youtube.com/user/petercrys =
:: = For more information please visit our website: http://tech.petercrys.com =
:: ====================================================================================
REM ===============
REM Define colour
REM Color attributes are specified by TWO hex digits
REM -- the first corresponds to the background;
REM the second the foreground. Each digit
REM can be any of the following values:
REM 0 = Black 8 = Gray
REM 1 = Blue 9 = Light Blue
REM 2 = Green A = Light Green
REM 3 = Aqua B = Light Aqua
REM 4 = Red C = Light Red
REM 5 = Purple D = Light Purple
REM 6 = Yellow E = Light Yellow
REM 7 = White F = Bright White
color 0A
REM ===============
REM ===============
REM Show the text on the Title Bar
TITLE Automate - Backup
REM ===============
REM ===============
REM Pauses the command processor for the specified number of seconds.
TIMEOUT 2
REM ===============
REM ===============
REM echo. Is used to give space between the lines
echo.
echo.
REM ===============
REM ===============
REM set - specifies the environment-variable name.
REM Displays the system date and time in the following format [ yyyy-mm-yy-hh-mm-ss. ]
set TIMESTAMP=%DATE:~10,4%-%DATE:~4,2%-%DATE:~7,2%-%TIME:~0,2%-%TIME:~3,2%-%TIME:~6,2%
echo ## Todays Time Stamp %TIMESTAMP%
echo.
echo.
REM ===============
REM ===============
REM xcopy - Copies files and directories, including subdirectories.
REM /s Copies directories and subdirectories, unless they are empty.
REM /c Ignores errors.
REM /d This option allows you to update files that have changed.
REM /e Copies all subdirectories, even if they are empty.
REM /h Copies files with hidden and system file attributes.
REM /i If Source is a directory or contains wildcards and Destination does not
REM exist, xcopy assumes destination specifies a directory name and creates a new directory
REM /r Copies read-only files.
REM /y Suppresses prompting to confirm that you want to overwrite an existing destination file.
set backupbatch=xcopy /s /c /d /e /h /i /r /y
:: set backupbatch=C:\Windows\System32\xcopy /s /c /d /e /h /i /r /y
REM ===============
REM ===============
REM This will display the following text [ ## Backing Up data ]
echo ## Backing Up data
echo.
echo.
REM ===============
REM ===============
REM tskill - Ends a process which is running.
tskill outlook
TIMEOUT 5
echo.
echo.
REM ===============
REM ===============
REM Path of the source and destination of the backup folder
%backupbatch% "D:\Work\*.*" "e:\backup\work\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\Desktop\ppt\*.*" "e:\backup\ppt\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\AppData\Local\Microsoft\Outlook\*.*" "e:\backup\outlook\"
echo.
echo.
REM ===============
REM ===============
REM This will display the following text [ ## Backup Complete! ]
echo ## Backup Completed!
echo.
echo.
REM ===============
TIMEOUT 100
[=================================]
[=================================]
First Download the Automatic Backup batch file Click Here
See the comprehensive Video Tutorial on YouTube to configure this:-
https://www.youtube.com/watch?v=UFuvZaCleT0
From this batch script you can Automate Backup of your data including the outlook and other mailing clients.
Step 1. Copy and paste the extracted file in c: drive see the example below:[ C:\Backups-All\ ]
Step 2. Open the following file [ C:\Backups-All\Schedul-backup-Task.xml ] into the text editor and replace the following TECH.PETERCRYS.COM\Administrator with your computer name\user name and save. See the below example:
<!-- Change below TECH.PETERCRYS.COM\Administrator with your computer name\user name -->
<Author>TECH.PETERCRYS.COM\Administrator</Author>
<!-- Change below TECH.PETERCRYS.COM\Administrator with your computer name\user name -->
<UserId>TECH.PETERCRYS.COM\Administrator</UserId>
Open the Task Scheduler goto -> run -> taskschd.msc
On the Task Scheduler click on Action -> Import Task -> [ C:\Backups-All\Schedul-backup-Task.xml ] See the below example:
Schedul-backup-Task.xml : This will backup your the data at 11:00 AM everyday
Note: You can edit the scheduled task anytime you want by double-clicking task -> target -> edit
Once you have completed the above steps do the following:
Open the following file [ C:\Backups-All\backup.bat ] into the text editor. Find the row where it says
[ Path of the source and destination of the backup folder ]
This will look something like this:-
-----
%backupbatch% "D:\Work\*.*" "e:\backup\work\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\Desktop\ppt\*.*" "e:\backup\ppt\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\AppData\Local\Microsoft\Outlook\*.*" "e:\backup\outlook\"
%backupbatch% "e:\backup\*.*" "\\192.168.1.100\backup"
-----
Here you have to change the path for example the source is [ D:\Work\ ] and the destination of the backup folder is [ e:\backup\work\ ]
Wild card [ *.* ]
To take the backup in separate folders you can use [ %TIMESTAMP% ] at the end of the destination folder path [ e:\backup\work\%TIMESTAMP% ].
See the comprehensive Video Tutorial on YouTube to configure this:-
https://www.youtube.com/watch?v=UFuvZaCleT0
Click Here to Download the Automatic Backup batch file or copy the below script past it into the text file and rename the form .txt to .bat
[=================================]
[=================================]
@echo OFF
:: ====================================================================================
:: = THis batch file is Created by: Sachin Samy =
:: = For comprehensive videos tutorial visit: http://www.youtube.com/user/petercrys =
:: = For more information please visit our website: http://tech.petercrys.com =
:: ====================================================================================
REM ===============
REM Define colour
REM Color attributes are specified by TWO hex digits
REM -- the first corresponds to the background;
REM the second the foreground. Each digit
REM can be any of the following values:
REM 0 = Black 8 = Gray
REM 1 = Blue 9 = Light Blue
REM 2 = Green A = Light Green
REM 3 = Aqua B = Light Aqua
REM 4 = Red C = Light Red
REM 5 = Purple D = Light Purple
REM 6 = Yellow E = Light Yellow
REM 7 = White F = Bright White
color 0A
REM ===============
REM ===============
REM Show the text on the Title Bar
TITLE Automate - Backup
REM ===============
REM ===============
REM Pauses the command processor for the specified number of seconds.
TIMEOUT 2
REM ===============
REM ===============
REM echo. Is used to give space between the lines
echo.
echo.
REM ===============
REM ===============
REM set - specifies the environment-variable name.
REM Displays the system date and time in the following format [ yyyy-mm-yy-hh-mm-ss. ]
set TIMESTAMP=%DATE:~10,4%-%DATE:~4,2%-%DATE:~7,2%-%TIME:~0,2%-%TIME:~3,2%-%TIME:~6,2%
echo ## Todays Time Stamp %TIMESTAMP%
echo.
echo.
REM ===============
REM ===============
REM xcopy - Copies files and directories, including subdirectories.
REM /s Copies directories and subdirectories, unless they are empty.
REM /c Ignores errors.
REM /d This option allows you to update files that have changed.
REM /e Copies all subdirectories, even if they are empty.
REM /h Copies files with hidden and system file attributes.
REM /i If Source is a directory or contains wildcards and Destination does not
REM exist, xcopy assumes destination specifies a directory name and creates a new directory
REM /r Copies read-only files.
REM /y Suppresses prompting to confirm that you want to overwrite an existing destination file.
set backupbatch=xcopy /s /c /d /e /h /i /r /y
:: set backupbatch=C:\Windows\System32\xcopy /s /c /d /e /h /i /r /y
REM ===============
REM ===============
REM This will display the following text [ ## Backing Up data ]
echo ## Backing Up data
echo.
echo.
REM ===============
REM ===============
REM tskill - Ends a process which is running.
tskill outlook
TIMEOUT 5
echo.
echo.
REM ===============
REM ===============
REM Path of the source and destination of the backup folder
%backupbatch% "D:\Work\*.*" "e:\backup\work\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\Desktop\ppt\*.*" "e:\backup\ppt\%TIMESTAMP%"
%backupbatch% "C:\Users\admin\AppData\Local\Microsoft\Outlook\*.*" "e:\backup\outlook\"
echo.
echo.
REM ===============
REM ===============
REM This will display the following text [ ## Backup Complete! ]
echo ## Backup Completed!
echo.
echo.
REM ===============
TIMEOUT 100
[=================================]
[=================================]
Video Tutorial on YouTube
Very Nice Video. I am Looking Folder Backup this is very nice.
ReplyDeleteThanks, let me know if you have any problem See ya.
DeleteGood After Sachin Samy i need one help from you..plz help me.
ReplyDeleteIssue:-I have a Wndows 2008 R2 Standard Server.I join my company 23rd, September 2013.This Windows 2008 R2 Server is a file server, there are 11 shared folder in this.Earlier when we access server by \\192.168.1.100 (My Server IP) it was ask for username and password prompt.After 0ne month of joining my boss told me to install Active Directory on this file server but after one month AD creating problem and server hanged and speed slow issue.So i uninstalled AD on this and when i restart the pc Server wallpaper changed and now server is not accessing from the client pc after a lot search i found now SSDP and UPnP service was disable,so i enable this and enable network discovery setting and now server is accessible only when i add entry on client pc credential manager otherwise it give error logon failure: the user has not been granted the request logon type at this computer and not prompt username and password i want it back.when someone access from \\servername or \\serverip it prompt for username and password.My all network works on WORKGROUP.I done evrything but my problem has not solved yet.Please bro help me.
Excellent informative blog, keep for sharing.
ReplyDeleteBest System Integration services | Massil Technologies