EN - Backup Work-IT database

EN - Backup Work-IT database

Question

How to backup Work-IT database manually, or schedule daily backup automatically ? 

Answer 

(a) Create Work-IT database backup manually


1- Open Microsoft SQLServer Management Studio, and login with "SQL Server Authentication" and "sa" credentials.




2- Open the folder “Databases” and select the database you want to backup.
    Right mouse click and select “Tasks” and then “Back Up” 





3- Then you will get this window:



Make sure the following choices are selected, in page "General" 
   - Database
   - Backup to "Disk"

4- Add or Remove backup directories, and write the name of backup file with the extension ".Bak" 
    Add for example: C:\Work-IT\Backup\Workit.bak
 Note: make sure you back up the Work-IT database on the local disk, and let the system administrator secure the back-up 

5- Now click on “OK” to execute the back-up

(b) Schedule Work-IT database backup automatically


First 

1. Copy the backup setup files in c:\work-it\backup   (or any other location from which the copying should be started).

 - backupdb.bat  
(see the attached *.7z file, so don't forget to unzip the file first)

2. Fill in the *.bat file.

3. The server name of the SQL server

4. The database name

5. The location where the 1st backup should be.

6. Location where the *.bat and *.sql file are placed

7. Possible location for the 2nd file.  (It's not basically necessary, so this line can be deleted)

8. Add "pause" at the bottom if necessary, so you can see what happened after the execution. Don't forget to remove it after checking, otherwise, the backup will only be executed once.

9. Start the *.bat file and see if the backup files are created in both locations

For example:



And when the backup *.bat file worked properly, you can then add it to Task scheduler in Windows, to run daily at certain time.

Second

1. Open Windows Task Scheduler (via the control panel, system administration, task scheduler)





2. From the right side menu "Actions"  click  Create task...

3. On the "General"  tab, choose "Run whether the user is logged on or not" and also check the option "Run with highest privileges




4. On tab "Triggers" enter the following:

     -Click "New"
     - Choose "Daily"
     - Set the time when the backup should be made, then click "OK"




5. On tab "Actions" follow these steps:
   
  - Click New.
  - Make sure that you choose "Start a program"
  - Choose in "Program" the bat file "backupdb.bat" , with his path.
  - Click "OK"




6. On tab "Settings":
   - Activate the option "Stop the task if it runs longer than:", and set it on "4 hours"
   - Click "OK"




Note: You will be asked to login with windows login credentials. you can then log in with the current windows user, or choose another User





For the advanced Backup system of the Work-IT database, where you have the ability to backup your database for each day in a week and choose the right one to restore from, then please read this article:
EN - Advance backup Work-IT database




    • Related Articles

    • EN - Advance backup Work-IT database

      Question How to back-up the Work-IT database automatically each day weekly or for a couple of days weekly? Answer Sometimes it is more secure for our valuable database to have weekly 7 backups (or less) instead of one backup file that will be ...
    • EN - Work-IT: Setup Course - Basic

      Question How to start quickly with Work-IT?  Answer   If you want to get to know how to setup Work-IT, you can do the free online course in the Hoogendoorn AcadeMe.  But if you want to have a quick look at the videos about Work-IT then click the ...
    • EN - Using the interface of Work-IT

      I am new to Work-IT. Can you give some tips and tricks on how to use the program? We want to make working with Work-IT as easy and fun as possible. Have a look at the video below for some trips and tricks. Want to learn more about how to work with ...
    • EN - Creating a report in Work-IT

      How do I create a new report in Work-IT? You can create a  new report in Work-IT in several ways. Each tab of Work-IT has its report button from which you can start a report. The video below shows an example of how to setup a simple report. This can ...
    • EN - Creating a new task in Work-IT

      How do I create a new task in Work-IT? You create a new task in Work-IT by going to the Work-IT menu > Tasks > Data > New. Have a look at the video below to learn how you can fill in the different fields of a task. Want to learn more about how to ...