News and backup: Difference between revisions

From CCMDB Wiki
Jump to navigation Jump to search
Line 38: Line 38:
#* '''Don't double-click''' because that would run the file
#* '''Don't double-click''' because that would run the file
# go to the line that starts with "set ml=", should be around line 12
# go to the line that starts with "set ml=", should be around line 12
# change the "somewhere" to your directory on the regional server, e.g. HSC_H4
# change the "somewhere" to the [[Laptop location]], i.e. your directory on the regional server, e.g. HSC_H4
#* don't add spaces
#* don't add spaces
#* make sure it's the directory used for the location, for legacy reasons this might not be the main ward now collected on
#* make sure it's the directory used for the [[Laptop location]], for legacy reasons this might not be the main ward now collected on
# menu file save, menu file close
# menu file save, menu file close



Revision as of 16:52, 2018 September 19

This article is about the "News and Backup" process collectors use to back up data from their laptop.

Backing up

To back up, double-click on the "News and Backup" shortcut on your desktop.

When to run Required minimally- IMPORTANT

Run while connected to the network at at the following times (REQUIRED - this goes to Regional Server):

  1. at beginning of collection with a laptop before data entry (to ensure you have the newest version of the program)
  2. at end of collection with a laptop (to ensure your data is backed up to the server)
  3. after sending but before DELETING any files from laptop - IMPORTANT!!!!!!
  4. you can additionally back up mid day if you have done a lot of work.

Importance of backup to REGIONAL SERVER

The Main office has the opportunity to get data from these backups if there is a problem.

  • Example of this is June 7.13 when new program was rolled out, postal code and color for overstay in TMP was being sent to TMPV2.mdb as "chinese type" letters. Main office was able to retrieve from regional server for site that backed up their data.Trish Ostryzniuk 17:00, 2013 June 10 (EDT)
  • another example of this: Nov.13 - discovered that ICU Pharmacy items YES NO not going into pharmacy.mdb or centralized.mdb from first week of June to Aug 13.13. Because of backups to Regional Server, the Main office had the opportunity to pull together copies of these backups and retrieve the "lost pharm data". This has saved the data collector from having to recollect pharmacy data from the chart.Trish Ostryzniuk 15:49, 2013 December 3 (CST)

Process

For the most up-to-date workings of this file see the file itself and the change logs at Batstart.bat#Log and Backup.bat#Log

The "News and Backup" batch file is a batch file on each laptop which does the following:

Setting up the file on a laptop

If the laptop is set up according to Laptop Setup then the batch files and shortcuts will be copied down as part of the process.

Edit parameters for location

  1. right-click the news-and-backup shortcut and click "edit"
    • Don't double-click because that would run the file
  2. go to the line that starts with "set ml=", should be around line 12
  3. change the "somewhere" to the Laptop location, i.e. your directory on the regional server, e.g. HSC_H4
    • don't add spaces
    • make sure it's the directory used for the Laptop location, for legacy reasons this might not be the main ward now collected on
  4. menu file save, menu file close

if the shortcut is missing...

see Desktop install.bat

Testing News and Backup

After initial setup test that the backup works:

  • open and close ccmdb.mdb to update date stamp of file on the client laptop
  • execute the News and Backup batch file to perform the process
  • check that ccmdb.mdb file with new stamp is on c:\ccmdb_data\ccmdb_backups
  • check that ccmdb.mdb file with new stamp is on Regional Server/data/<hsp>_<ward>

Information about the batch files

A two-file system is used to allow batstart.bat to actually look for a new backup.bat before each run, allowing a central update of that file if necessary. This allows for centralized updating/tweaking/etc of the laptops.

Batstart.bat uses Robocopy, sort of an improved version of xcopy, which is available from Microsoft as part of one of their Server SDKs.

Updating the file

BatStart.bat looks for an update to backup.bat in regional server\programs\<location>; that file will replace the local one.

Make sure Batstart.bat#Log/Backup.bat#Log is updated with any changes.

Error checking

Just do your backups and assume they work, there is no need for collectors to routinely check that the backups to the regional server are working. Data Processor in Main office checks regularly that backups are being done, so if backups are not making it to the regional server we will let you know.

Main office uses Backup_Checker.vbs to make sure the backups are working.