::V1.5-Added Minecraft Overviewer Option for mapping-----------------------------------::
::----Edited by instinx - smithtec(AT)gmail.com----------------------------------------::
::----October 6th, 2010 - Added Option for using Minecraft Overviewer------------------::
::----http://github.com/brownan/Minecraft-Overviewer-----------------------------------
::V1.6-Cleaned up a lot of code. Added option to only run Overviewer after a certain----::
::-----amount of time. Instructions for Overviewer found in User Variables-------------::
Overviewer has been added and I highly recommend it be used if you want a very detailed zoomable map of your world. Thanks to instinx for the integration of it. I'm currently working on FTP to upload Overviewer files to webserver after it is ran. Instinx is working on an incremental backup.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
::V1.7-Added ability to use WinSCP FTP to upload Overviewer map to remote website-------::
::-----Runs a Synchronize command so only files that have changed will be uploaded------::
::-----Also cleaned up some more code and rearranged User Variables.--------------------::
::-----Download WinSCP Here: http://winscp.net : Required for FTP Upload but Free App---::
Next revision will hopefully have incremental backups working. This should help reduce the backup time and system resources required to perform it.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
::V1.7-Added ability to use WinSCP FTP to upload Overviewer map to remote website-------::
::-----Runs a Synchronize command so only files that have changed will be uploaded------::
::-----Also cleaned up some more code and rearranged User Variables.--------------------::
::-----Download WinSCP Here: http://winscp.net : Required for FTP Upload but Free App---::
Next revision will hopefully have incremental backups working. This should help reduce the backup time and system resources required to perform it.
I found this work of yours today and am very excited because I basically run the same exact file. I was using task scheduler to run a simple batch file to create a 7z archive every hour. I finally decided I wanted to start using overviewer and was looking into a method of syncing the files over ftp with my site when I found your script.
Doesn't "Runs a Synchronize command so only files that have changed will be uploaded" mean the system already does incremental updates?Or are you referring to the cache directory used by Overviewer? Either way I look forward to any and all updates as we all love efficiency.
::V1.7-Added ability to use WinSCP FTP to upload Overviewer map to remote website-------::
::-----Runs a Synchronize command so only files that have changed will be uploaded------::
::-----Also cleaned up some more code and rearranged User Variables.--------------------::
::-----Download WinSCP Here: http://winscp.net : Required for FTP Upload but Free App---::
Next revision will hopefully have incremental backups working. This should help reduce the backup time and system resources required to perform it.
I found this work of yours today and am very excited because I basically run the same exact file. I was using task scheduler to run a simple batch file to create a 7z archive every hour. I finally decided I wanted to start using overviewer and was looking into a method of syncing the files over ftp with my site when I found your script.
Doesn't "Runs a Synchronize command so only files that have changed will be uploaded" mean the system already does incremental updates?Or are you referring to the cache directory used by Overviewer? Either way I look forward to any and all updates as we all love efficiency.
Thank you for all the hard work
That is referring to the ftp program. The sync process takes a long time to check the ftp vs local files, but it ONLY uploads changed files to your site. This way you're not wasting bandwidth uploading the same Overviewer files over and over.
Thanks for the thanks btw. I'm glad it's useful to other people besides me. As far as incremental. Look at the next post and enjoy :smile.gif:
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Incremental Backups are finally here! Refer to the OP for full details.
::V1.8-MAJOR UPDATE! Added option to use Incremental Updates. Incremental updates-----::
::-----greatly reduce total backup time and space. Incremental updates store one master::
::-----backup file in a dated directory. Then dated incremental updates of only changes::
::-----are produced on the next backup run. The very first run will create Cache files-::
::-----of both the world directory and the compressed backup in your backup directory.--::
::-----They will be used to produce incremental updates without recopying the full world::
::-----directory or recompressing the full directory. They will only be deleted if the-::
::-----backup script detectes a restored backup. This is done by a folder named--------::
::-----_IncrBackupRestored being created in the archives. If you restore a backup it----::
::-----will be placed in your world folder so the backup script will know to purge the--::
::-----cache. Otherwise you can manually delete the files in IncrBackupCache to force--::
::-----what is basically a full backup to be done. I'm working on a simple restore-----::
::-----script, but for now you must first extract the IncrMaster_Worldname.7z and then--::
::-----extract, in order overwriting existing files the incr_# until you get to the time::
::-----you wish to restore. Everytime you restart the script or restore a backup a new-::
::-----dated folder is created with a new master and it's own set of incremental backups::
::-----**************************IMPORTANT READ BELOW****************************-------::
::-----WinRAR is NOT SUPPORTED FOR INCREMENTAL BACKUPS. You must use the 7-zip method.-::
::-----With the addition of Incremental backup 7z.exe is no longer REQUIRED to be in----::
::-----the backup directory, but there now is an option to set the path to the exe------::
::-----This must be set for either FULL or INCREMENTAL backups to work------------------::
::-----**************************************************************************-------::
::-----Additionally I added the option to change how often Cartograph runs, and---------::
::-----rearranged some of the code for a smoother script. Along with modifications to---::
::-----check for winrar methods and notify user that Incremental backups are not--------::
::-----Supported for WinRAR. 7-ZIP is a free program so RAR support seemed uneccessary-::
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Bug in your latest version. You ask for the maps directory for overviewer but in the code below the -dont touch below here line-. You still have G:\maps directory hardcoded and are not using the overviewer maps directory
Thanks for the heads up. I had fixed that, but then rolled back when I ran into a different bug. I've updated the archives and the code in the OP.
Let me know what you think of incremental backups if you're using them. I had an idea for a different type of incremental backups, but wasn't sure if I wanted to do it or not. At the least I'm thinking of making an option to create a new dated folder every X hourss
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
I'm not using vbs, overviewer.
Every backup file is exactly the same as the initial save! Why isn't this working? I ran the backup T=10 minutes. For an hour and all 7 files are identical
Can you copy and paste the settings you set under User Variables and post it here? If you are using the Full backups then the files can be very similar in size unless something major is changed on your server. If they are actually identical it is most likely a setting problem or a problem with the server saving to disk.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
I'll update the code a little later, but see if this works:
( should appear twice. once under :startincr and once under :tempcopy)
Find this line:
SET WorldNamDate=%WorldNAM%-%DATE:~-4%-%DATE:~4,2%-%DATE:~7,2%---%TIME:~0,2%%TIME:~3,2%
( all three lines need to go in directly where the old line was.)
and replace it with this:
for /f "tokens=1-5 delims=/ " %%d in ("%date%") do SET Date1=%%g-%%e-%%f
for /f "tokens=1-5 delims=: " %%d in ("%time%") do SET Time1=%%d%%e
SET WorldNamDate=%worldNAM%-%Date1%---%Time1%
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
::V2.0-Modified the way batch captures time/date from system. Added the ability to-----::
::-----change the date format. Refer to User Variables for more information------------::
@h0us3cat
Try the latest version. It should solve your problems. If you are using a different date format then look in user variables for the dateformat settings. You can change the date format to what you prefer.
If you still have issues after trying v2.0 please post the exact folder/file names created by the batch and the exact windows time format reported by typing DATE into the command prompt.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Great! I'm glad its working for you now. I'm glad you brought it up because the new code is much better anyhow. My next updates will hopefully have an option to upload the backups to FTP, and to create new incremental folders every so many hours.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Dateranoth, first of all I love your script. It's much better than anything I could have put together.
With that said, I had to make a few changes to get it to work. On the "start winscp.exe" line in your code, you have your backup directory hardcoded instead of using the variable. It also wouldnt work with "Exit" in that line, here's what worked for me:
start winscp.exe /console /command "open %ftploginname%:%ftploginpass%@%ftpurlport%" "synchronize remote -delete -criteria=both -speed=%ftpspeed% "%OVWROUTDIR%" "%ftpovwrdirectory%"
with "exit" i got the error that there were too many parameters or something.
With your latest update, 2.0, it broke incremental backups. Non-incremental work fine, but with incremental enabled I get this issue: http://db.tt/XsPJVAm
Dateranoth, first of all I love your script. It's much better than anything I could have put together.
With that said, I had to make a few changes to get it to work. On the "start winscp.exe" line in your code, you have your backup directory hardcoded instead of using the variable. It also wouldnt work with "Exit" in that line, here's what worked for me:
start winscp.exe /console /command "open %ftploginname%:%ftploginpass%@%ftpurlport%" "synchronize remote -delete -criteria=both -speed=%ftpspeed% "%OVWROUTDIR%" "%ftpovwrdirectory%"
with "exit" i got the error that there were too many parameters or something.
With your latest update, 2.0, it broke incremental backups. Non-incremental work fine, but with incremental enabled I get this issue: http://db.tt/XsPJVAm
Thank you for your help and hard work!
Ok, sorry for the stupid hard coded directory. I've been chasing that one around forever and I finally have fixed it. There should be no more hard coded directories. If you use the latest version the 'exit' command should work. Your too many parameter issue looks like it was due to improper quotation.
As for incremental backups, they are working fine on my end. I suggest deleting the cache directory and trying it again. If you still get the error, search your computer for IncrMaster_World1.7z.tmp and delete that file.
Before trying the above fixes update to V2.1 . It adds the option to start a new Incremental backup folder after X amounts of backups if you choose. Along with the fix for that pesky hardcoded line.
Oh, and thanks for the appreciation :smile.gif: . I'm glad to help. Let me know if you continue to have problems after clearing the cache and updating to v2.1 . I'll see what I can do to help.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
::V2.1-Added a max incremental count. This counter will create X number of incremental-::
::-----backups before starting a new folder and master file. This is so users who use--::
::-----regular incremental backups can create a new master folder daily or whenever.----::
::-----Which will in turn make restoring much easier and faster. If you do not wish to--::
::-----use the feature then set it to a very high number. ie. 9999999-------------------::
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Ok, sorry for the stupid hard coded directory. I've been chasing that one around forever and I finally have fixed it. There should be no more hard coded directories. If you use the latest version the 'exit' command should work. Your too many parameter issue looks like it was due to improper quotation.
As for incremental backups, they are working fine on my end. I suggest deleting the cache directory and trying it again. If you still get the error, search your computer for IncrMaster_World1.7z.tmp and delete that file.
Before trying the above fixes update to V2.1 . It adds the option to start a new Incremental backup folder after X amounts of backups if you choose. Along with the fix for that pesky hardcoded line.
Oh, and thanks for the appreciation :smile.gif: . I'm glad to help. Let me know if you continue to have problems after clearing the cache and updating to v2.1 . I'll see what I can do to help.
I tried everything you said and I'm still getting errors. Incremental did work for me with 1.9 of your script.
I commented out the cls and include images to show what happens when i clear the cache vs not clear the cache: http://db.tt/XY1a7YZ
Here's the directory structure I use. Server is in C:\Minecraft, backup bat is in that same folder. I backup to the D:\MC_backup directory. The temp directory is called IncrBackupCache. If incremental is off, filenames such as World1-2010-10-23---1857 .7z are created and no folders are made. If incremental is on, folders named World1-2010-10-23---1927 and files named IncrMaster_World1.7z are created inside each folder, no incremental files are successfully created.
I've restarted the pc, searched for the .tmp file (no luck), ran disc cleanup and ccleaner -- no changes :sad.gif:
I've been digging around your code with no luck and I believe this to be the line that's executing when I get the error:
"%_7zipdir%\7z.exe" u "%BackupDIR%\IncrBackupCache\IncrMaster_%WorldNam%.7z" -up0q0r2x2y2z1w2 -up3q3r2x2y2z0w2!"%BackupDIR%\%WorldNamIncrDate%\incr_#%IncrCounterDate%.7z" "%BackupDIR%\IncrBackupCache\%WorldNam%" -ms=off
Open up MCBackup.bat and remove the first line "@ECHO OFF"
Then place this batch: MCDebug.bat in the directory with MCBackup.bat and run it. It will create a log file of everything that's going on here. Send me that log file or post it here.
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
I really appreciate you helping me get through this. I ran the debug file:
Created: 2010-10-23--2058_MCBackupDebug.log
Contents:
Sat 10/23/2010
20:58:57.52
Testing 1.9 to see if it works. Will update.
Edit: 1.9 not working either now. I guess I need to do a deep search of system directories for this tmp file.
Did you place the Debug file in the same directory as MCBackup.bat? It should have ran MCBackup and logged what MCBackup did.
Rollback Post to RevisionRollBack
MC AutoBackup:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
::----Edited by instinx - smithtec(AT)gmail.com----------------------------------------::
::----October 6th, 2010 - Added Option for using Minecraft Overviewer------------------::
::----http://github.com/brownan/Minecraft-Overviewer-----------------------------------
::V1.6-Cleaned up a lot of code. Added option to only run Overviewer after a certain----::
::-----amount of time. Instructions for Overviewer found in User Variables-------------::
Overviewer has been added and I highly recommend it be used if you want a very detailed zoomable map of your world. Thanks to instinx for the integration of it. I'm currently working on FTP to upload Overviewer files to webserver after it is ran. Instinx is working on an incremental backup.
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
::-----Runs a Synchronize command so only files that have changed will be uploaded------::
::-----Also cleaned up some more code and rearranged User Variables.--------------------::
::-----Download WinSCP Here: http://winscp.net : Required for FTP Upload but Free App---::
Next revision will hopefully have incremental backups working. This should help reduce the backup time and system resources required to perform it.
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
I found this work of yours today and am very excited because I basically run the same exact file. I was using task scheduler to run a simple batch file to create a 7z archive every hour. I finally decided I wanted to start using overviewer and was looking into a method of syncing the files over ftp with my site when I found your script.
Doesn't "Runs a Synchronize command so only files that have changed will be uploaded" mean the system already does incremental updates?Or are you referring to the cache directory used by Overviewer? Either way I look forward to any and all updates as we all love efficiency.
Thank you for all the hard work
That is referring to the ftp program. The sync process takes a long time to check the ftp vs local files, but it ONLY uploads changed files to your site. This way you're not wasting bandwidth uploading the same Overviewer files over and over.
Thanks for the thanks btw. I'm glad it's useful to other people besides me. As far as incremental. Look at the next post and enjoy :smile.gif:
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
::V1.8-MAJOR UPDATE! Added option to use Incremental Updates. Incremental updates-----::
::-----greatly reduce total backup time and space. Incremental updates store one master::
::-----backup file in a dated directory. Then dated incremental updates of only changes::
::-----are produced on the next backup run. The very first run will create Cache files-::
::-----of both the world directory and the compressed backup in your backup directory.--::
::-----They will be used to produce incremental updates without recopying the full world::
::-----directory or recompressing the full directory. They will only be deleted if the-::
::-----backup script detectes a restored backup. This is done by a folder named--------::
::-----_IncrBackupRestored being created in the archives. If you restore a backup it----::
::-----will be placed in your world folder so the backup script will know to purge the--::
::-----cache. Otherwise you can manually delete the files in IncrBackupCache to force--::
::-----what is basically a full backup to be done. I'm working on a simple restore-----::
::-----script, but for now you must first extract the IncrMaster_Worldname.7z and then--::
::-----extract, in order overwriting existing files the incr_# until you get to the time::
::-----you wish to restore. Everytime you restart the script or restore a backup a new-::
::-----dated folder is created with a new master and it's own set of incremental backups::
::-----**************************IMPORTANT READ BELOW****************************-------::
::-----WinRAR is NOT SUPPORTED FOR INCREMENTAL BACKUPS. You must use the 7-zip method.-::
::-----With the addition of Incremental backup 7z.exe is no longer REQUIRED to be in----::
::-----the backup directory, but there now is an option to set the path to the exe------::
::-----This must be set for either FULL or INCREMENTAL backups to work------------------::
::-----**************************************************************************-------::
::-----Additionally I added the option to change how often Cartograph runs, and---------::
::-----rearranged some of the code for a smoother script. Along with modifications to---::
::-----check for winrar methods and notify user that Incremental backups are not--------::
::-----Supported for WinRAR. 7-ZIP is a free program so RAR support seemed uneccessary-::
::V1.9-Name Changed from SMPBackup to MCBackup. The backup package now includes a------::
::-----script to easily and quickly restore backups. Refer to it for directions.-------::
::-----http://www.dateranoth.com/gamercide/MCRestore.zip--------------------------------
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
Let me know what you think of incremental backups if you're using them. I had an idea for a different type of incremental backups, but wasn't sure if I wanted to do it or not. At the least I'm thinking of making an option to create a new dated folder every X hourss
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
Every backup file is exactly the same as the initial save! Why isn't this working? I ran the backup T=10 minutes. For an hour and all 7 files are identical
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
http://i54.tinypic.com/11tvsb5.jpg
[Edit]
I'll update the code a little later, but see if this works:
( should appear twice. once under :startincr and once under :tempcopy)
Find this line:
SET WorldNamDate=%WorldNAM%-%DATE:~-4%-%DATE:~4,2%-%DATE:~7,2%---%TIME:~0,2%%TIME:~3,2%
( all three lines need to go in directly where the old line was.)
and replace it with this:
for /f "tokens=1-5 delims=/ " %%d in ("%date%") do SET Date1=%%g-%%e-%%f
for /f "tokens=1-5 delims=: " %%d in ("%time%") do SET Time1=%%d%%e
SET WorldNamDate=%worldNAM%-%Date1%---%Time1%
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
::-----change the date format. Refer to User Variables for more information------------::
@h0us3cat
Try the latest version. It should solve your problems. If you are using a different date format then look in user variables for the dateformat settings. You can change the date format to what you prefer.
If you still have issues after trying v2.0 please post the exact folder/file names created by the batch and the exact windows time format reported by typing DATE into the command prompt.
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
With that said, I had to make a few changes to get it to work. On the "start winscp.exe" line in your code, you have your backup directory hardcoded instead of using the variable. It also wouldnt work with "Exit" in that line, here's what worked for me:
start winscp.exe /console /command "open %ftploginname%:%ftploginpass%@%ftpurlport%" "synchronize remote -delete -criteria=both -speed=%ftpspeed% "%OVWROUTDIR%" "%ftpovwrdirectory%"
with "exit" i got the error that there were too many parameters or something.
With your latest update, 2.0, it broke incremental backups. Non-incremental work fine, but with incremental enabled I get this issue:
http://db.tt/XsPJVAm
Thank you for your help and hard work!
Ok, sorry for the stupid hard coded directory. I've been chasing that one around forever and I finally have fixed it. There should be no more hard coded directories. If you use the latest version the 'exit' command should work. Your too many parameter issue looks like it was due to improper quotation.
As for incremental backups, they are working fine on my end. I suggest deleting the cache directory and trying it again. If you still get the error, search your computer for IncrMaster_World1.7z.tmp and delete that file.
Before trying the above fixes update to V2.1 . It adds the option to start a new Incremental backup folder after X amounts of backups if you choose. Along with the fix for that pesky hardcoded line.
Oh, and thanks for the appreciation :smile.gif: . I'm glad to help. Let me know if you continue to have problems after clearing the cache and updating to v2.1 . I'll see what I can do to help.
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
::-----backups before starting a new folder and master file. This is so users who use--::
::-----regular incremental backups can create a new master folder daily or whenever.----::
::-----Which will in turn make restoring much easier and faster. If you do not wish to--::
::-----use the feature then set it to a very high number. ie. 9999999-------------------::
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
I tried everything you said and I'm still getting errors. Incremental did work for me with 1.9 of your script.
I commented out the cls and include images to show what happens when i clear the cache vs not clear the cache:
http://db.tt/XY1a7YZ
Here's the directory structure I use. Server is in C:\Minecraft, backup bat is in that same folder. I backup to the D:\MC_backup directory. The temp directory is called IncrBackupCache. If incremental is off, filenames such as World1-2010-10-23---1857 .7z are created and no folders are made. If incremental is on, folders named World1-2010-10-23---1927 and files named IncrMaster_World1.7z are created inside each folder, no incremental files are successfully created.
I've restarted the pc, searched for the .tmp file (no luck), ran disc cleanup and ccleaner -- no changes :sad.gif:
I've been digging around your code with no luck and I believe this to be the line that's executing when I get the error:
http://www.dateranoth.com/gamercide/MCDebug.zip
This is a debug batch.
Open up MCBackup.bat and remove the first line "@ECHO OFF"
Then place this batch: MCDebug.bat in the directory with MCBackup.bat and run it. It will create a log file of everything that's going on here. Send me that log file or post it here.
You can also try V1.9 and see if it works for you:
http://www.dateranoth.com/gamercide/MCBackupv1.9.zip
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org
Created: 2010-10-23--2058_MCBackupDebug.log
Contents:
Sat 10/23/2010
20:58:57.52
Testing 1.9 to see if it works. Will update.
Edit: 1.9 not working either now. I guess I need to do a deep search of system directories for this tmp file.
Forces server auto-save, incremental backup options,Cartograph, and Overviewer options with ftp upload of Overviewer for your Minecraft Server.
Visit Gamercide.org