Back Up Suggestions

cheftim

Registered User.
Local time
Today, 08:39
Joined
Jan 22, 2007
Messages
33
Hello folks,

I am searching for a good method of creating automated backups of my DB. Is there a good method within Access for this or is it best to look for a seperate backup program?

I am working with a small non-profit company and they do not wish to have the on-going expense (albeit small and reasonable cost - in my humble opinion) for one of the on-line back-up services. They are willing to foot the one-time bill for a back up program. I want to make sure that if we go that route, that I choose a good program.

Any recommendations, suggestions or thoughts on this subject?

Many thanks,

t
 
Depends on many factors including what backup medium you had in mind.

Quick and dirty backup:

1. Search this forum for "Forcing Database to Close" and similar word combinations to that effect. You don't want the database to be open when you do the backup.

I recommend the method that uses a startup form that never goes away (but just minimizes and hides itself). Once per minute, 5-minutes, whatever, have it wake up and see if it is within a couple of time increments of the backup start time. If so, have it QUIT the application. But you might see another way that appeals to you more when you do the recommended search of this forum. Pick the way that makes sense to YOU.

2. Put something in your Windows Task Scheduler that runs at a time when no one should be in your database. If all you are doing is making a disk to disk copy of the file, you can write a little .BAT file to do a couple of things.

2.1 Find the intended backup directory. Delete the oldest copy of the file in question. (See 2.2 below.)

2.2 Rename the next oldest copy to become the oldest copy. Ripple through as many copies as you are keeping. The last step is to rename the youngest copy to be the name set aside for the second-youngest copy.

For instance, db.bak, db.bk2, db.bk3, ... db.bk9 - gives you 9 copies of the original, each with identifiable names that tell you the order in which they were copied. The .BAK is youngest, the .BK9 is oldest.

2.3 Copy the "live" database to the name/place selected as the youngest copy. That's it, you are done - if this is the simplest case.

Now, if you have a tape drive or some other medium - say, CD-WORM or DVD in some flavor or another - you need to have an operator present to load the proper media at the right time and to later file it away. In this case, if you are going to have an operator on board anyway, look into either the Legato or ARCServe packages. We've used both on our systems with a reasonable level of success.

Even though you have an operator present, the backup job can be predefined so that all you do is load media, click on a button, and wait until it tells you it is done. Single-user licenses for either package probably cost no more than a small body part. Maybe not even as much as your firstborn child.

A couple of last thoughts.

1. It matters less the exact package and method that you use than that you use any method regularly. I.e. buy the nicest car in the world. If you don't drive it, why did you bother? A cheap rust-bucket can sit in the garage as well as a spiffy new roadster. In the realty industry, the slogan is Location, Location, Location. In the data recovery business, it is Backup, Backup, Backup. There is NO SUBSTITUTE for regular repetition of backups.

2. Once you have a quite moment, TEST the ability to recover the data from your chosen backup medium. Obviously, if you are using the disk-to-disk method you will have less trouble than if you are using tape or CD media. If you cannot recover, you weren't doing a backup, were you? Test BEFORE you need it. You won't get the chance to fix it after-the-fact.

3. If media isn't local-disk to local-disk on the same site: Some folks have friends at other sites with whom they can make arrangements for off-site media storage. I.e. you buy a storage cabinet big enough to hold 100 of your media. But you only planned to keep 50 copies. See if you have a friend who just did the same thing. Then make extra copies of your media and put them in your friend's cabinet. Let him/her make extra copies of his/her media and store them in your cabinet. Then each of you has an on-site and an off-site copy in case of disaster. You can retire the oldest media when you bring over the next bunch of newly recorded media. And you can even take turns being the "designated driver" who brings media to the other site.

Trust me... all it takes is one good fire or storm to make that off-site media become worth its weight in platinum. I'm from New Orleans. We had tapes in a sister site in Texas. Hurricane Katrina killed our building and our local tape copies. But we never lost a transaction - because we had an alternate storage site for our copies of the primary backup tapes.
 
Thanks, Doc Man

Thanks Doc,

Your replies seem to always be well tought out and well written - that makes so much difference - esspecially to a newbie like me.

Good information. I have never created any batch files, but seems like this may be the next step in my studies. :)

Thank you,

t
 
You don't want the database to be open when you do the backup.

At our site we have the FE and BE split and we just make a direct copy of the BE to 2 different hard drives, one on site one offsite. It is almost always open but not always in use. Is this bad? Could this be a source for record corruption? It copies the .mdb and the .ldb if it is open.

Greg
 
I would not copy the .LDB file. I would also make one copy of the FE available from the same place as the BE, just for backup purposes if for no other reason. If your network speed in doing it that way is adequate, you should be OK. Federal guidelines for "offsite" storage usually specify another city, but some organizations suggest that a distance of 50 km is enough. In the final analysis, you have to decide the balance between the ideal and the practical. "Next door" is probably too close. "Across the continent" might not be practical. Finding the happy medium is always the trick.

HOWEVER, there is an inference to be drawn that says you have one little problem. That .LDB file exists ONLY if you are making your backup copy with the .MDB file still open. In general, this is decidedly NOT GOOD. If the .LDB file exists, you really shouldn't copy ANYTHING - yet.

See, there is a common misunderstanding about where the database actually exists. ("What?", you say... "Isn't it the .MDB file?")

The real database is the combination of the .MDB file and ALL WORKSPACES REFERENCING THAT FILE in ALL WORKSTATIONS that have the DB open. Any changes still in-progress inside the .MDB exist only in the workspaces until the DB is closed. Buffers must still be flushed. Indexes might still need updating. Things just aren't totally self-consistent when the DB is open. And that WILL lead to corruption. Not might. WILL.

Because the .MDB is a complete representation of the database only when there is no open workspace, the only time the .MDB file is a good candidate for safe backup is when nobody has it open.

Hope that clarifies the issues.
 
Wow. That is just what I needed to know. I am going to have to rethink the backup scheme and maybe force the app to close before I make a copy. Good to know.
I do have a copy of the FE in the same folder as the BE for backup purposes so at least that is going well. Our offsite storage is 20 miles from the office. When the big earthquake hits it might not be adequate, but if the office burns down it will be a lifesaver. Thanks for the reply.

Greg
 
One question. Would the corruption occur in the .mdb and .ldb that is being copied onto the external media, or would the corruption occur in the file that users are currently connected to. It seems like it shouldn't make a difference if the system is just reading the file (it is on a unix fileserver) as it makes a copy.

Greg
 
The backup copy would potentially be corrupted if the original is open at the time. However, depending on exactly how you are doing the backup, I can imagine a p|ssing match between Windows and Access regarding file locks, where Access has the internal locks on the .LDB but Windows, while running the backup, takes out file-level locks on the same file, different program. Then you get what is called a deadly embrace or deadlock situation and suddenly you're the one who's dead. Because whatever you do, you cannot kill either process and you can't force either one to finish its operation. And that would corrupt the LIVE copy of the database.

Which is why I would ALWAYS close the DB before making a backup of it.

UNIX also takes out locks. Same difference as if Windows did it, so the same argument applies. The names were changed to protect the innocent - if you can find anyone who's innocent when UNIX and Windows are collaborating on any project whatsoever.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom