Difference between revisions of "Zmanda Windows Client"

From The Open Source Backup Wiki (Amanda, MySQL Backup, BackupPC)
Jump to navigationJump to search
 
(42 intermediate revisions by 9 users not shown)
Line 1: Line 1:
Zmanda Windows Client Community Edition is an Amanda client for Windows platform that uses native Win32 API and uses Volume Shadow Services for backup.
+
Zmanda Windows Client Community Edition is an Amanda client for Windows platform that uses native Win32 API and uses Volume Shadow Services (VSS) for backup.
  
 
== Features ==
 
== Features ==
* Backup of open files
+
* Backup of open files (Volume Shadow Services must be enabled)
 
* Backs up NTFS filesystem
 
* Backs up NTFS filesystem
* Backup of extended attributes (ACLs)
 
 
* Uses open format for backup images ([http://en.wikipedia.org/wiki/ZIP_(file_format) ZIP64])
 
* Uses open format for backup images ([http://en.wikipedia.org/wiki/ZIP_(file_format) ZIP64])
 
* Client backup compression using [http://en.wikipedia.org/wiki/DEFLATE deflate algorithm]
 
* Client backup compression using [http://en.wikipedia.org/wiki/DEFLATE deflate algorithm]
 +
* Client configuration tool - ZWCconfig. Allows configuration of ports that are used and amanda server name.
 +
* Support for exclude patterns (wildcard * is supported, full path must be specified)
 +
* Installshield based installer.
  
 
== Downloads ==
 
== Downloads ==
  
* Amanda client for 2.6.0p2 (ZWCInstaller-Community-26.zip) is available for download from [http://www.zmanda.com/download-amanda.php Zmanda downloads] page.
+
Amanda windows client is available for download from [http://www.zmanda.com/download-amanda.php Zmanda downloads] page for
 +
Windows 32bit platforms and 64bit x86 platforms.
 +
 
 +
'''How to find the Amanda client version on Windows machine?'''
 +
: Check the file ''version.txt'' in the windows client installation directory (usually under C:\Program Files\Zmanda\....) under the ''misc'' sub-folder. The file contains version, build date and build revision.
  
 
== Supported versions ==
 
== Supported versions ==
  
* Zmanda Windows Client 2.6.0 works with Amanda server packages (from Zmanda Downloads page) version 2.6.0 and later releases.
+
* Zmanda Windows Client works with corresponding version of Amanda server packages (from Zmanda Downloads page).
* Amanda Windows client has been tested with (all running on x86)
+
* Amanda Windows client has been tested with (all running on x86 and x86_64 platforms)
** Windows XP Pro (Server pack 2)
+
** Windows XP Pro (SP 2)
** Windows 2003 server
+
** Windows 2003 server (SP2)
** Windows Vista
+
** Windows Vista (SP1)
** Windows 2008 server
+
** Windows 2008 server R2
 +
** Windows 7
 +
** Windows 2012 server
 +
** Windows 10
 +
 
 +
== Issues and Limitations ==
 +
 
 +
* Zmanda Windows Client only supports ''bsdtcp'' authentication. So, the dumptype for ZWC should have "auth bsdtcp".
 +
* Zmanda Windows Client does not support ''maxdumps'' parameter. It does not do backups in parallel.
 +
* Zmanda Windows Client uses port 10080 and 10081. No other service on the client should use these ports. ZWC service will fail to start if these ports are used. See [http://forums.zmanda.com/showthread.php?t=1688 this thread] for one possible solution
 +
* Zmanda Windows Client only supports 'estimate server' and 'estimate client', not 'estimate calcsize'.  Do not use 'estimate calcsize' with a ZWC DLE.
 +
* The amanda user on the Amanda server should be "amandabackup". If you want to use a different account, see [[#Running_ZWC_as_some_other_user | this tip]].
 +
* You need to register the server on the windows client (by editing the registry or using the ZWC configuration GUI tool).  It currently appears that name resolution does not work (amcheck says something like: Server validation failed).  Workaround: use IP address instead of the server's name.
  
 
== Installation ==
 
== Installation ==
  
Zmanda Windows Client (ZWC) uses Microsoft installer.
+
Zmanda Windows Client (ZWC) uses Installshield installer
  
 
* Download ZWC zip archive from the downloads page.
 
* Download ZWC zip archive from the downloads page.
 
* Extract the zip archive.
 
* Extract the zip archive.
 
* Double-click on the setup.exe to install the Windows client.
 
* Double-click on the setup.exe to install the Windows client.
 
=== ZWC installer steps ===
 
 
* Welcome Screen
 
[[Image:Welcome01.jpg|center]]
 
 
* License agreement
 
[[Image:License Agmt 02.jpg|center]]
 
 
* Select the installation folder for ZWC
 
[[Image:Select Install 03.jpg|center]]
 
 
 
* Choose password for "amandabackup" user. All backups will be performed as this user. The user account is created on the local machine. If the software is being installed on domain controller, the user created in the domain.
 
* Choose password for "amandabackup" user. All backups will be performed as this user. The user account is created on the local machine. If the software is being installed on domain controller, the user created in the domain.
[[Image:User Settings 04.jpg|center]]
+
* If the ZWC is being installed on a Windows machine that uses non "US English" locale, please provide local equivalents.
 
+
* Amanda server information. Please provide hostname of the server that will back up this windows machine. This can be changed later using ZWCConfig tool. On Windows 7, you will have run the ZWCconfig tool as Administrator, add the Amanda server information and restart the ZWC service.
* If the ZWC is being installed on a Windows machine using non "US English" locale, please provide local equivalents.
 
[[Image:Group Settings 05.jpg|center]]
 
 
 
* Amanda server information. Please provide hostname of the server that will back up this windows machine.
 
[[Image:Amanda Server Info 06.jpg|center]]
 
 
 
* Installation notes: Please read before continuing.
 
[[Image:Install Notes 07.jpg|center]]
 
 
 
* Rest of the installation steps are self-explanatory.
 
  
 
== Adding your new Windows client to the Amanda server ==
 
== Adding your new Windows client to the Amanda server ==
Line 65: Line 61:
 
     global
 
     global
 
     auth "bsdtcp"
 
     auth "bsdtcp"
 +
    maxdumps 1
 
     program "DUMP"
 
     program "DUMP"
 
  }
 
  }
Line 72: Line 69:
 
     global
 
     global
 
     auth "bsdtcp"
 
     auth "bsdtcp"
 +
    maxdumps 1
 
     compress client fast
 
     compress client fast
 
     program "DUMP"
 
     program "DUMP"
 
  }
 
  }
 +
 +
To exclude files:
 +
 +
* Please use \\ (two back slashes) in the exclude pattern. For example:
 +
  exclude "D:\\Documents\\Images"
 +
 +
* To exclude files by extension type, do it like this (Notice: *No* slashes.):
 +
  exclude "*.foo" "*.bar"
  
 
=== Tell the Amanda server what to back up on the Windows client ===
 
=== Tell the Amanda server what to back up on the Windows client ===
Line 86: Line 92:
  
 
  $ amaddclient --config DailySet1 --client windowsdesktop.company.com \
 
  $ amaddclient --config DailySet1 --client windowsdesktop.company.com \
   --diskdev "\"C:/Documents and Settings/Sunil/My Documents\""  --dumptype zwc-compress
+
   --diskdev \"C:/Documents\ and\ Settings/Sunil/My\ Documents\"  --dumptype zwc-compress
  
 
* ''DailySet1'' - the Amanda configuration name
 
* ''DailySet1'' - the Amanda configuration name
Line 111: Line 117:
 
To restore files to the Windows client, the backup image will have to be recovered on the Amanda server and copied to the Windows client. Windows machine to which files being restored to, does not require Amanda software.
 
To restore files to the Windows client, the backup image will have to be recovered on the Amanda server and copied to the Windows client. Windows machine to which files being restored to, does not require Amanda software.
  
* On the Amanda server, use amadmin and amfetchdump to extract the backup image on the Amanda server. You will have to use amfetchdump repeatedly to extract images of multiple backup levels. It has to be performed as "amandabackup" user.
+
* Start by determining which dumps you need in order to obtain the most current version of the client's data. You can do this by using amrecover and doing a history of the dumps performed on the client.
 +
 
 +
Example:
 +
  $ amrecover DailySet1
 +
  AMRECOVER Version 2.6.1p1. Contacting server on localhost ...
 +
  220 backups AMANDA index server (2.6.1p1) ready.
 +
  Setting restore date to today (2010-07-29)
 +
  200 Working date set to 2010-07-29.
 +
  200 Config set to DailySet1.
 +
  200 Dump host set to backups.foobar.com.
 +
  Use the setdisk command to choose dump disk to recover
 +
  amrecover> sethost client1.foobar.com
 +
  200 Dump host set to client1.foobar.com
 +
  amrecover> history
 +
  200- Dump history for config "DailySet1" host "client1.foobar.com" disk "C:/"
 +
  201- 2010-07-28-23-00-04 1 DailySet1-03:6
 +
  201- 2010-07-27-23-00-05 0 DailySet1-02:3
 +
  201- 2010-07-26-23-00-05 1 DailySet1-01:6
 +
  200 Dump history for config "DailySet1" host "client1.foobar.com" disk "C:/"
 +
  amrecover>
 +
 
 +
From this you will need to follow the procedure described under the term [[Level]] to determine which dumps to retrieve. NOTE: The dump level is the third column in on the history list. After determining which dumps you need, the tape names can be seen in the last column and the date/time stamp can be obtained for use with amfetchdump by removing the hyphens from the number in the second column in the history list.
 +
 
 +
* Next load up the earliest tape in the list of tapes containing the needed dumps.
 +
 
 +
* Then use amadmin and amfetchdump to extract the backup image on the Amanda server. You will have to repeat these last two steps in order to extract dumps of multiple backup levels. This has to be performed as "amandabackup" user (or whatever user Amanda runs under on your system).
 +
 
 +
Example:
 +
$ amfetchdump DailySet1 client1.foobar.com C:/ 20100727230005
 +
 
 +
Hint:
 +
  To avoid very long and convoluted filenames, use the -p switch and redirect the output to a filename of your choice.
 +
 
 
Example:
 
Example:
  $ amfetchdump DailySet1 windowsdesktop.company.com C:/ 20080818143408
+
  $ amfetchdump -p DailySet1 client1.foobar.com C:/ 20100727230005 > client1_full.zip
 +
$ amfetchdump -p DailySet1 client1.foobar.com C:/ 20100728230004 > client1_incr_1.zip
  
* Copy the backup images to the Windows client. It will appear as Microsoft compressed folder. You can also use WinZIP or PKZIP to extract the ZIP archive.
+
* Copy the zipped backup images to the Windows client. They will appear as Microsoft compressed folders. You can also use WinZIP or PKZIP to extract the ZIP archive.
 +
 
 +
* You will need to unzip them inside the directory set in your DLE diskdevice parameter. ie. In the case of the above example, the zip file would need to be extracted in the root directory of the C Drive. This will insure proper recursion.
 +
 
 +
* Extract all files starting with the full and working in ascending order to the most recent incremental.
  
 
== Running ZWC as some other user ==
 
== Running ZWC as some other user ==
  
Zmanda Windows Client requires the backup user to be "amandabackup". All packages from [http://www.zmanda.com/download-amanda.php Zmanda downloads] page use "amandabackup" as the Amanda user.
+
Zmanda Windows Client is installed to run with the user "amandabackup" (all packages from [http://www.zmanda.com/download-amanda.php Zmanda downloads] page use "amandabackup" as the Amanda user.)
 +
 
 +
As it uses BSD authentication, ZWC requires that the Amanda server is also running with the user "amandabackup".
 +
 
 +
It may not be feasible to change the Amanda user that is being used by the server, in that case, you need to modify the user being used by ZWC.
  
If you have to change the user to "operator", you can try the following procedure:
+
If you have to change the user to "amanda", you can try the following procedure:
 
* Follow the standard install, remembering to keep the password around for the modification steps.
 
* Follow the standard install, remembering to keep the password around for the modification steps.
* Start the user administration tool and rename amandabackup to operator.
+
* Start the user administration tool and rename amandabackup to amanda.
 
* Start regedit and change the following two values to operator:
 
* Start regedit and change the following two values to operator:
 
  HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\BackupUser
 
  HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\BackupUser
 
  HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\RecoveryUser
 
  HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\RecoveryUser
* Start the service administration tool and open properties on ZWC Service, switch to the Log On tab and change the account to .\operator. Here you have to give the original password.
+
* Start the service administration tool and open properties on ZWC Service, switch to the Log On tab and change the account to .\amanda. Here you have to give the original password.
 
* Restart the ZWC Service.
 
* Restart the ZWC Service.
  
 
== Log Files ==
 
== Log Files ==
  
; Installation logs : C:\ZWC_install.log
+
; Amanda logs : C:\Program Files\Zmanda\Zmanda Client for Windows\Debug\LogFile*.txt
; Amanda logs : C:\Program Files\Zmanda\Zmanda Client for Windows\Debug\LogFile.txt
 

Latest revision as of 00:38, 1 September 2016

Zmanda Windows Client Community Edition is an Amanda client for Windows platform that uses native Win32 API and uses Volume Shadow Services (VSS) for backup.

Features

  • Backup of open files (Volume Shadow Services must be enabled)
  • Backs up NTFS filesystem
  • Uses open format for backup images (ZIP64)
  • Client backup compression using deflate algorithm
  • Client configuration tool - ZWCconfig. Allows configuration of ports that are used and amanda server name.
  • Support for exclude patterns (wildcard * is supported, full path must be specified)
  • Installshield based installer.

Downloads

Amanda windows client is available for download from Zmanda downloads page for Windows 32bit platforms and 64bit x86 platforms.

How to find the Amanda client version on Windows machine?

Check the file version.txt in the windows client installation directory (usually under C:\Program Files\Zmanda\....) under the misc sub-folder. The file contains version, build date and build revision.

Supported versions

  • Zmanda Windows Client works with corresponding version of Amanda server packages (from Zmanda Downloads page).
  • Amanda Windows client has been tested with (all running on x86 and x86_64 platforms)
    • Windows XP Pro (SP 2)
    • Windows 2003 server (SP2)
    • Windows Vista (SP1)
    • Windows 2008 server R2
    • Windows 7
    • Windows 2012 server
    • Windows 10

Issues and Limitations

  • Zmanda Windows Client only supports bsdtcp authentication. So, the dumptype for ZWC should have "auth bsdtcp".
  • Zmanda Windows Client does not support maxdumps parameter. It does not do backups in parallel.
  • Zmanda Windows Client uses port 10080 and 10081. No other service on the client should use these ports. ZWC service will fail to start if these ports are used. See this thread for one possible solution
  • Zmanda Windows Client only supports 'estimate server' and 'estimate client', not 'estimate calcsize'. Do not use 'estimate calcsize' with a ZWC DLE.
  • The amanda user on the Amanda server should be "amandabackup". If you want to use a different account, see this tip.
  • You need to register the server on the windows client (by editing the registry or using the ZWC configuration GUI tool). It currently appears that name resolution does not work (amcheck says something like: Server validation failed). Workaround: use IP address instead of the server's name.

Installation

Zmanda Windows Client (ZWC) uses Installshield installer

  • Download ZWC zip archive from the downloads page.
  • Extract the zip archive.
  • Double-click on the setup.exe to install the Windows client.
  • Choose password for "amandabackup" user. All backups will be performed as this user. The user account is created on the local machine. If the software is being installed on domain controller, the user created in the domain.
  • If the ZWC is being installed on a Windows machine that uses non "US English" locale, please provide local equivalents.
  • Amanda server information. Please provide hostname of the server that will back up this windows machine. This can be changed later using ZWCConfig tool. On Windows 7, you will have run the ZWCconfig tool as Administrator, add the Amanda server information and restart the ZWC service.

Adding your new Windows client to the Amanda server

Adding dumptype definitions on the Amanda server for Windows clients

Add dumptype definitions to the Amanda server's configuration file amanda.conf. If you want to share the definitions across all Amanda configurations, please add it to /etc/amanda/template.d/dumptypes file.

  • Dumptype definition for normal backup
define dumptype zwc-normal {
   global
   auth "bsdtcp"
   maxdumps 1
   program "DUMP"
}
  • Dumptype definition for compressed backup
define dumptype zwc-compress {
   global
   auth "bsdtcp"
   maxdumps 1
   compress client fast
   program "DUMP"
}

To exclude files:

  • Please use \\ (two back slashes) in the exclude pattern. For example:
 exclude "D:\\Documents\\Images"
  • To exclude files by extension type, do it like this (Notice: *No* slashes.):
 exclude "*.foo" "*.bar"

Tell the Amanda server what to back up on the Windows client

On the Amanda server, run amaddclient to add Windows client filesystems to be backed up

$ amaddclient --config <configuration name> --client <Windows host name> \
  --diskdev <filesystem> --dumptype <dumptype definition>

Example:

$ amaddclient --config DailySet1 --client windowsdesktop.company.com \
  --diskdev \"C:/Documents\ and\ Settings/Sunil/My\ Documents\"  --dumptype zwc-compress
  • DailySet1 - the Amanda configuration name
  • \ - back slash escapes special characters such as white space in file names
  • zwc-compress - selects a dumptype that will compress backups of the filesystem

Note: Ignore the WARNING messages from "amaddclient" about failing to copy files to the Windows Client.

Run amcheck on the Amanda server

Fix all configuration problems found by the amcheck(8) command. Run amcheck as the amandabackup user on the Amanda server.

For example:

$ amcheck -c DailySet1

If there are no amcheck errors, you are ready to do backup of Windows client. In case of amcheck errors, take a look at amcheck troubleshooting section.

Note: Zmanda Windows Client only supports "bsdtcp" authentication (auth bsdtcp in 
dumptype configuration) protocol.

Restoring files to the Windows client

To restore files to the Windows client, the backup image will have to be recovered on the Amanda server and copied to the Windows client. Windows machine to which files being restored to, does not require Amanda software.

  • Start by determining which dumps you need in order to obtain the most current version of the client's data. You can do this by using amrecover and doing a history of the dumps performed on the client.

Example:

 $ amrecover DailySet1
 AMRECOVER Version 2.6.1p1. Contacting server on localhost ...
 220 backups AMANDA index server (2.6.1p1) ready.
 Setting restore date to today (2010-07-29)
 200 Working date set to 2010-07-29.
 200 Config set to DailySet1.
 200 Dump host set to backups.foobar.com.
 Use the setdisk command to choose dump disk to recover
 amrecover> sethost client1.foobar.com
 200 Dump host set to client1.foobar.com
 amrecover> history
 200- Dump history for config "DailySet1" host "client1.foobar.com" disk "C:/"
 201- 2010-07-28-23-00-04 1 DailySet1-03:6
 201- 2010-07-27-23-00-05 0 DailySet1-02:3
 201- 2010-07-26-23-00-05 1 DailySet1-01:6
 200 Dump history for config "DailySet1" host "client1.foobar.com" disk "C:/"
 amrecover>

From this you will need to follow the procedure described under the term Level to determine which dumps to retrieve. NOTE: The dump level is the third column in on the history list. After determining which dumps you need, the tape names can be seen in the last column and the date/time stamp can be obtained for use with amfetchdump by removing the hyphens from the number in the second column in the history list.

  • Next load up the earliest tape in the list of tapes containing the needed dumps.
  • Then use amadmin and amfetchdump to extract the backup image on the Amanda server. You will have to repeat these last two steps in order to extract dumps of multiple backup levels. This has to be performed as "amandabackup" user (or whatever user Amanda runs under on your system).

Example:

$ amfetchdump DailySet1 client1.foobar.com C:/ 20100727230005

Hint:

 To avoid very long and convoluted filenames, use the -p switch and redirect the output to a filename of your choice.

Example:

$ amfetchdump -p DailySet1 client1.foobar.com C:/ 20100727230005 > client1_full.zip
$ amfetchdump -p DailySet1 client1.foobar.com C:/ 20100728230004 > client1_incr_1.zip
  • Copy the zipped backup images to the Windows client. They will appear as Microsoft compressed folders. You can also use WinZIP or PKZIP to extract the ZIP archive.
  • You will need to unzip them inside the directory set in your DLE diskdevice parameter. ie. In the case of the above example, the zip file would need to be extracted in the root directory of the C Drive. This will insure proper recursion.
  • Extract all files starting with the full and working in ascending order to the most recent incremental.

Running ZWC as some other user

Zmanda Windows Client is installed to run with the user "amandabackup" (all packages from Zmanda downloads page use "amandabackup" as the Amanda user.)

As it uses BSD authentication, ZWC requires that the Amanda server is also running with the user "amandabackup".

It may not be feasible to change the Amanda user that is being used by the server, in that case, you need to modify the user being used by ZWC.

If you have to change the user to "amanda", you can try the following procedure:

  • Follow the standard install, remembering to keep the password around for the modification steps.
  • Start the user administration tool and rename amandabackup to amanda.
  • Start regedit and change the following two values to operator:
HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\BackupUser
HKEY_LOCAL_MACHINE\SOFTWARE\Zmanda\ZWC\1.0\Install\RecoveryUser
  • Start the service administration tool and open properties on ZWC Service, switch to the Log On tab and change the account to .\amanda. Here you have to give the original password.
  • Restart the ZWC Service.

Log Files

Amanda logs
C:\Program Files\Zmanda\Zmanda Client for Windows\Debug\LogFile*.txt