aboutsummaryrefslogtreecommitdiffstats
path: root/tools/hv/hv_vss_daemon.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2013-04-24Tools: hv: Fix a checkpatch warningK. Y. Srinivasan1-1/+1
Fix a checkpatch warning. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24tools: hv: skip iso9660 mounts in hv_vss_daemonOlaf Hering1-0/+2
fsreeze does not work for iso9660 filesystems. A ENOSUPP may be caught in the freeze case, but the subsequent thaw call would fail and leads to a false error. Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24tools: hv: use FIFREEZE/FITHAW in hv_vss_daemonOlaf Hering1-9/+22
As suggested by Paolo Bonzini, use ioctl instead of calling fsfreeze. Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24tools: hv: use getmntent in hv_vss_daemonOlaf Hering1-18/+21
As suggested by Paolo Bonzini, use getmntent instead of parsing output of mount(1). Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24Tools: hv: Fix a checkpatch warningK. Y. Srinivasan1-2/+3
Fix a checkpatch warning. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24tools: hv: fix checks for origin of netlink message in hv_vss_daemonOlaf Hering1-1/+7
Similar to what commit 95a69adab9acfc3981c504737a2b6578e4d846ef ("tools: hv: Netlink source address validation allows DoS") does in hv_kvp_daemon, improve checks for origin of netlink connector message. Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-24Tools: hv: fix warnings in hv_vss_daemonOlaf Hering1-4/+8
This change fixes a few compile errors: hv_vss_daemon.c:64:15: warning: unknown escape sequence '\/' hv_vss_daemon.c:64:15: warning: unknown escape sequence '\/' hv_vss_daemon.c: In function 'vss_operate': hv_vss_daemon.c:66: warning: 'return' with no value, in function returning non-void hv_vss_daemon.c: In function 'main': hv_vss_daemon.c:130: warning: ignoring return value of 'daemon', declared with attribute warn_unused_result hv_vss_daemon.c: In function 'vss_operate': hv_vss_daemon.c:47: warning: 'fs_op' may be used uninitialized in this function Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-03-15Drivers: hv: Add a new driver to support host initiated backupK. Y. Srinivasan1-0/+220
This driver supports host initiated backup of the guest. On Windows guests, the host can generate application consistent backups using the Windows VSS framework. On Linux, we ensure that the backup will be file system consistent. This driver allows the host to initiate a "Freeze" operation on all the mounted file systems in the guest. Once the mounted file systems in the guest are frozen, the host snapshots the guest's file systems. Once this is done, the guest's file systems are "thawed". This driver has a user-level component (daemon) that invokes the appropriate operation on all the mounted file systems in response to the requests from the host. The duration for which the guest is frozen is very short - a few seconds. During this interval, the diff disk is comitted. In this version of the patch I have addressed the feedback from Olaf Herring. Also, some of the connector related issues have been fixed. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com> Cc: Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>