Git Product home page Git Product logo

backupessentials's Introduction

Hyper-V Backup Essentials

This repository contains installable binaries for Hyper-V backup components for certain Linux distributions. The Hyper-V backup components allow a system administrator to perform uninterrupted backup of a live Linux virtual machine. Since the Hyper-V backup feature was only completed in late 2013, we could not include it in several distributions that existed prior to that date. For such distributions, we decided to deliver the backup feature through the RPM installables in this repository.

What distributions are supported?

As of now Hyper-V Backup Essentials are available for the following distributions:

  • Red Hat Enterprise Linux (RHEL)/CentOS 5.9
  • RHEL/CentOS 6.4, 6.5

What Windows Server version will this run on?

The Hyper-V backup feature is only present in Windows Server 2012 R2 release and its derivatives.

How is this different from Linux Integration Services (LIS) releases?

The Hyper-V backup essentials have been released for Linux distributions that do not have Hyper-V backup components either prebuilt in to them or through an LIS release such as LIS 3.5.

Newer distributions starting SLES 11 SP3, Ubuntu 13.10 and RHEL 7 come prepackaged with Hyper-V backup components. Furthermore, LIS 3.5 provides backup components for RHEL 5.5-5.8/6.0-6.3. Distributions other than these may require Hyper-V backup essentials for utilizing the Hyper-V backup feature.

Please refer to the feature maps mentioned in the following page to discover Hyper-V backup feature availability for your distribution:

http://technet.microsoft.com/en-us/library/dn531030.aspx

Installation

This section describes how you may install the Hyper-V backup components for different distributions.

  • First of all download the Hyper-V backup components using the following command:
# curl -L -o backupessentials.tar.gz https://github.com/LIS/backupessentials/tarball/master
  • Next untar the downloaded tar file using the following command:
# tar -xvzf backupessentials.tar.gz
  • After untar operation, you should see a folder similar to the following:
# drwxrwxr-x. 3 root root   4096 Jan 15 20:58 LIS-backupessentials-f5f542e
  • For RHEL/CentOS 5.9, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel5.9/rpm/
  • For RHEL/CentOS 6.4, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel6.4/rpm/
  • For RHEL/CentOS 6.5, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel6.5/rpm/
  • After changing your directory appropriately, run install.sh and reboot the virtual machine.
# ./install.sh
# reboot

Uninstallation

To uninstall Hyper-V backup components, switch to the directory corresponding to your distribution and run the uninstall.sh script as outlined in the following steps:

  • For RHEL/CentOS 5.9, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel5.9/rpm/
  • For RHEL/CentOS 6.4, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel6.4/rpm/
  • For RHEL/CentOS 6.5, change directory as follows:
# cd LIS-backupessentials-f5f542e/hv/hv-rhel6.5/rpm/
  • After changing your directory appropriately, run uninstall.sh and reboot the virtual machine.
# ./uninstall.sh
# reboot

Feedback

Customer can provide feedback through Linux Integration Services for Microsoft Hyper-V forum located at http://social.technet.microsoft.com/Forums/windowsserver/en-us/home?forum=linuxintegrationservices

backupessentials's People

Contributors

microsoft-github-policy-service[bot] avatar vyadavmsft avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

backupessentials's Issues

hv_vss_daemon deadlocks on "/" due syslog

VSS may cause complete FS deadlock because it uses syslog() to write diagnostic messages (including freeze and thaw). There is a problem when syslog tries to write on locked FS (note that VSS freezes all filesystems (root as last), snapshots, and thaw all filesystems (root as last!)).

This problem appears at least on CentOS 5.11, ext3 filesystems, with standard sysklogd (it writes INFO synchronously to /var/log/messages by default)

The workaround is to write ioctl() results to console as in this patch:

--- a/hv/hv-rhel5.9/src/tools/hv_vss_daemon.c
+++ b/hv/hv-rhel5.9/src/tools/hv_vss_daemon.c
@@ -52,12 +52,19 @@ static struct sockaddr_nl addr;

 static int vss_do_freeze(char *dir, unsigned int cmd, char *fs_op)
 {
-       int ret, fd = open(dir, O_RDONLY);
+        FILE *c;
+       int saved_errno,ret, fd = open(dir, O_RDONLY);

        if (fd < 0)
                return 1;
        ret = ioctl(fd, cmd, 0);
-       syslog(LOG_INFO, "VSS: %s of %s: %s\n", fs_op, dir, strerror(errno));
+        saved_errno = errno;
+        // DO NOT USE syslog (filesystem) to avoid deadlock!
+        c= fopen("/dev/console","w+");
+        if (c!=NULL){
+          fprintf(c, "VSS: %s of %s: %s\n", fs_op, dir, strerror(saved_errno));
+           fclose(c);
+        }
        close(fd);
        return !!ret;
 }

After applying this patch the VSS works without deadlock, for example using

wbadmin start backup -backupTarget:\\SERVER\BACKUPSHARE -hyperv:VMNAME

Note - as result os this patch, tha VSS ioctl operations are "logged" to current local console only.

Best regards
--Henryk Paluch

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.