Yesterday’s Thoughts

August 20, 2005

Automated Backups on Windows XP Pro

Windows Backup is very poorly designed and implemented for automated use. I had to jump through hoops backwards to accomplish automated backups. In the interest of preserving your sanity, here is what I did.

My environment:

  • Windows XP Professional
  • Multiple Users
  • Selected Folders
  • Multiple Disks — C backing up to D, and vice-versa
  • Running as a regular user, without a password, the most secure method.

There are several things that cause problems here.

  • A user without a password can’t perform scheduled backups. This isn’t documented and there is no error logged to the events log. When it happens, the error is recorded in the Automated Tasks Status, “The scheduled task did not run because no user account password was entered.” Other tasks with the same user account, and lack of password do not generate this error. The Backup Wizard asks, “No password has been entered for the user name associated with this job. Are you sure you want to use a blank password?” The password question is asked two or three times, but only once does it give this notice, not the first time, and non of them specify that the job will not be run.
  • If you run as different user, which the wizard dialogue gives you the option to do, then the parameters for the back up job itself are stored in the %UserProfile%\Local Settings\Application Data\Microsoft\Windows NT\NTBackup\data directory, of the user that is setting up the job. Whenever I do this I get the error , “The saved selection file ‘NT\NTBackup\data\BackupJobName.bks’ cannot be found.” As far as I can tell, this is a permissions problem, even though the job is running as the Administrator. Maybe it is something else having to do with a poor variable substitution, or I don’t know what. I have tried changing the permissions on the file and the directory, and moving the BackupJobName.bks file to the Administrator’s %UserProfile% directory, and chaning the path in the job, but I still get the same error either way.

That’s the don’t work list. Later, I’ll give you the don’t work right list, but to relieve your suspense, the solution to the problem is to either login as the Administrator to set the job up, or to right click on the Backup icon, and “Run As…” the Administrator, or some other user with a password.

Things that don’t work correctly

  • There are separate text areas for entering the name of the backup file produced and the name of the job. Whichever you enter last will be the name of both. This is obvious the first chance you get, but when you change the job from a one time job to a scheduled recurrent job, the text area is clear, so you have to enter the name without it being in front of you. This is important if you are attempting to incrementally add to an existing backup file.
  • The logging is broken. I mentioned that some errors go to the event log and others go to the Schedule Tasks Status Field. Having the errors in the Status field is nice, but they should be logged. As it is I was doing backups for a week without errors and assuming everything was fine.
  • Backups either add incrementally to a backup file, or replace the backup file. I’d like to be able to keep my previous backup around when doing a full backup. The wizard offers no way to rename the existing back before starting the next.
  • You have to enter the password of the Administrator 5 times to schedule a backup. 1x for Run As, 2x for scheduling, and 2x for backing up. I don’t know the ins and outs of the Windows security system, but I don’t see the need for entering the password 2x for the same dialogue. I have just tested that you have to enter the actual password to proceed, so why enter twice? Also, isn’t it possible to save the credential that the user established when logging in?

1 Comment(s)

  1. Chuck | Feb 22, 2006 | Reply

    Re: Automated NT Backup gripes:

    Created the backup job logged on as Administrator, set to run as Administrator. Logged of Admin, logged in as another user.

    Backup ran as scheduled, but no notification at all – only evidence of job being in process is disk activity, task manager. Bummer.

Sorry, comments for this entry are closed at this time.