
Hi I use the following script [bat] file. It makes a mysql backup and copy/backup the otrs directory Steps 1. Create a text file and change the extension to .bat 2. Change the contents to do your backup :: ##### Begin ##### For /f "tokens=1-4 delims=/ " %%a in ('date /t') do (set dt=%%c%%a%%b) SET date=%dt% ::Step 1 :: create a new directory to make the backup in :: the directory wil have today's date Mkdir C:\Backup\OTRS\%date% :: Step 2 :: Copy OTRS Data to created directory :: NOTE I use robocopy but u can use xcopy, copy, rsync etc - please change accordingly Robocopy C:\OTRS\otrs C:\Backup\OTRS\%date% /E /R:0 /W:0 :: Step 3 :: Do MYSQL backup :: Make sure you supply the correct username and password below For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set dt=%%c-%%a-%%b) For /f "tokens=1-4 delims=:." %%a in ('echo %time%') do (set tm=%%a%%b%%c%%d) set bkupfilename=mysql%1%dt%%tm%.bak echo Backing up to file: %bkupfilename% C:\OTRS\mysql\bin\mysqldump --databases otrs --user=root --password=password
C:\Backup\OTRS\%date%\"%bkupfilename%"
::Step 4 :: You can get this from http://www.7zip.org - you need the command line one :: 7-Zip The data to save lots of space "C:\Program Files\7-Zip\7z" a -r C:\Backup\OTRS\%date% C:\Backup\OTRS\%date% :: Step 5 :: Delete the directory - keep the zip file, you do not need the directory any more, tomorrow a new one will be created RMDIR C:\Backup\OTRS\%date% /S /Q :: ##### End ##### 3. Now create a schedule for the file you created On XP go to START | CONTROL PANEL - Look for Scheduled Tasks -Follow the steps on screen to create the Scheduled Task -Tip: You must supply a password [with the user] or it will not run 4. Please, please check the stuff to ensure that you have made a complete, correct backup of your data. You will need to clean up the backups now and then. I hope this helps Theuns Smuts theuns@itblue.co.za Tel: +27 21 fax: 021-8868276 www.itblue.co.za Your preferred IT partner Confidentiality Notice: The information in this document and attachments is confidential and may be legally privileged. It is intended only for the use of the named recipient. Internet communications are not secure and therefore ITBlue does not accept legal responsibility for the contents of this message. If you are not the intended recipient, please notify us immediately by return email and then delete this document. Do not disclose the contents of this document to any other person, nor take any copies. Violation of this notice may be unlawful. -----Original Message----- From: otrs-bounces@otrs.org [mailto:otrs-bounces@otrs.org] On Behalf Of Nils Breunese (Lemonbit) Sent: 17 October 2006 10:35 To: User questions and discussions about OTRS.org Subject: [SPAM] LOW * Re: [otrs] Upgrade from 2.0.4 to 2.1 on Windows platform Eugene Colesnicov wrote:
Ok, but how I can backup mysql database on a windows platform?
I'm guessing the Windows version of MySQL also has mysqldump (http:// dev.mysql.com/doc/refman/4.1/en/mysqldump.html), which would take of this. You can always install something like phpMyAdmin (http:// www.phpmyadmin.net/) if you're not too comfortable with MySQL commands. Nils Breunese. _______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support orr consulting for your OTRS system? => http://www.otrs.com/