![]() : : : : Copyright (C) 2009 Dario Borreguero : : : : This program is free software: you can redistribute it and/or modify : : it under the terms of the GNU General Public License as published by : : the Free Software Foundation, either version 3 of the License, or : : (at your option) any later version. Eg.: : : -.zip : : : : This script will also delete those obsolete zip files, that is : : those which sequence number exceeds the maximum allowed. : : The created zip file will be named with the given preffix and : : a sequence number. : : Creates a zip file from the list file given and from the MySQL dump file. Just copy it in a text file and rename it to zip-backup.cmd. And only the last 10 created zip files will be kept. This will create C:\My Backups\MyBackup-1.zip file containing the files/directories given at C:\Program Files\ListMyBackup.txt. Zip-backup "MyBackup" "C:\My Backups\" "C:\Program Files\ListMyBackup.txt" 10 String connection with the following format Maximum number of backups to keep. This file must followed the 7-zip file list format Eg.: "C:\Program Files\"Ĭomplete path to the filename that contains the files/directories to include in the zip file. It must be quoted, whenever contains spaces. It's recommended not use spaces, if not, it must be quoted. Zip-backup output-prefix output-path list-files string-conn ![]() It is understood by an obsolete file the one which sequence number exceeds the maximum to keep. Create the zip file with the given contents and the MySQL dump file.Therefore, zip-backup will perform the following tasks: Remember the path must be quoted whenever it contains spaces.Īs a result of executing this script (let's name it zip-backup.cmd), a numbered zip file is created. Where MediaWiki-Folder is your Mediawiki installation folder. Also uncomment the lines with AdminSettings.php in the batch file. If you are using a MediaWiki version prior to 1.16, then you might want to add "MediaWiki-Folder\AdminSettings.php". One file/directory per line, following the 7-zip file list format. The text file will contain the complete path to the files/directories to be added in the backup zip file. #Main script, which is responsible to create the XML Dump and invoke the #Helper script.Creating the MySQL Dump file and create a zip file containing the previous dump file and the given list of files/directories included in the #Text file to add.#Helper script, which is responsible of:.A #Text file that contains the files and directories to be added in the zip file.The Wiki-Backup architecture is based on the following files: Tested in Windows XP, Windows 2003 Server R2, Windows 2000 Advanced Server. PHP in order to run Manual:dumpBackup.php.7-zip in order to create a zip file to ease the maintenance of the backup files.The following scripts require to have installed: On top of that, this script will create full XML backups as well. As you will see, the files to be included can be configured easily. Therefore, the script will use the MySQL Dump command line tool. It worths mentioning that MySQL 5.0.x is used as backend. Where is located most of the critical information. Following the example given by the script User:Flominator/Backup MW, I decided to write a new command line script (after doing it, it becomes in two scripts) in order to create backups in Windows, from now on it'll be named Wiki-WinBackup.
0 Comments
Leave a Reply. |