Documentation for this project can also be found on CodeProject:
Windows Azure File Backup Service

Introduction

There have been articles about using Windows Azure Blob Service to backup files; notably Windows Azure's sample "Synchronizing Files to Windows Azure Storage".

However, this "no rocket science" article takes it a step further by defining a complete solution:

  1. C# Libraries for syncing the file contents and their metadata of an assigned root directory to a defined Blob container within a Windows Azure Storage account using Blob Service REST API and System.IO.FileSystemWatcher class.
  2. Windows Form application for backup configuration.
  3. Windows Service to automatically perform the file backup operation based upon provided backup configuration.
  4. Windows Service Installer

Background

I am doing this article as a personal interest to review Blob Service REST API and to see it using Windows Azure Storage as resources for file backup as viable choice.

Code Plex

The solution sources are also available within CodePlex: Windows Azure File Backup Service

Solution Components

Using the Code

  1. Install, but do not Start, WindowsAzure_FileBackup_Service using Setup. It should appear within Services named "Windows Azure File Backup".
  2. Create two directories:
    • Backup Directory: e.g., F:\WindowsAzureBackupFolder
    • Recovery Directory: e.g., F:\WindowsAzureRecoveryFolder
  3. Start WindowsAzure_FileBackup_Console
    • Configure
      • Storage Account Name
      • Storage Account Key
      • Backup Blob Container
        • Default "cloudfilebackup"
      • Backup Local Path
      • Recovery Local Path
      • Connection Mode
        • Default "Cloud"
        • "Local" is only available for:
          • Windows 7
          • Windows Vista
          • Windows 2008
    • Select Button "Prepare Backup" to register configuration settings.
  4. Start Service now because configuration settings are available.

 

Note

  1. You need to provide a valid Storage Account Name and Key, or the Windows Service will fail.
  2. Events are logged within:
    • LogName: WindowsAzureFileBackup
    • LogSource: Service or Console
  3. All configuration setting are registered within: HKEY_LOCAL_MACHINE\SOFTWARE\jeff00seattle\WindowsAzureFileBackup

Helpful Tools

While developing the Windows Service, there were times where reinstalling was required; however, uninstalling would fail. There were two freeware tools that helped out tremendiously:

  1. Microsoft Fix-It -- Fix problems with programs that can't be installed or uninstalled.
  2. Uninstall Tool -- Ultra fast and small utility that helps you to uninstall various software.

In addition:

Recognition

Code Plex project Azure Storage Samples was exceptionally useful by providing a well implemented Blob Service REST API. I had implemented my own, but I found this one and liked it better.

History