Skip to content

Commit 14414d1

Browse files
authored
Merge pull request #4030 from laozc/fix-hv-daemon
Update Hyper-V daemons
2 parents 903e9c2 + 9a5f3c2 commit 14414d1

12 files changed

+105
-50
lines changed

deploy/iso/minikube-iso/package/Config.in

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ menu "System tools"
77
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/docker-bin/Config.in"
88
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-bin/Config.in"
99
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-plugins-bin/Config.in"
10-
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-kvp-daemon/Config.in"
10+
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hyperv-daemons/Config.in"
1111
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/gluster/Config.in"
1212
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/vbox-guest/Config.in"
1313
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/containerd-bin/Config.in"

deploy/iso/minikube-iso/package/hv-kvp-daemon/Config.in

-4
This file was deleted.

deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk

-30
This file was deleted.

deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service

-15
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
SUBSYSTEM=="misc", KERNEL=="vmbus/hv_fcopy", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_fcopy_daemon.service"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
SUBSYSTEM=="misc", KERNEL=="vmbus/hv_kvp", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_kvp_daemon.service"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
SUBSYSTEM=="misc", KERNEL=="vmbus/hv_vss", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_vss_daemon.service"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
config BR2_PACKAGE_HYPERV_DAEMONS
2+
bool "hyperv-daemons"
3+
default y
4+
depends on BR2_x86_64
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[Unit]
2+
Description=Hyper-V FCOPY Daemon
3+
Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-guest-service-interface
4+
BindsTo=sys-devices-virtual-misc-vmbus\x21hv_fcopy.device
5+
6+
[Service]
7+
ExecStart=/usr/sbin/hv_fcopy_daemon -n
8+
9+
[Install]
10+
WantedBy=multi-user.target
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[Unit]
2+
Description=Hyper-V Key Value Pair Daemon
3+
Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-data-exchange-service-kvp
4+
BindsTo=sys-devices-virtual-misc-vmbus\x21hv_kvp.device
5+
6+
[Service]
7+
ExecStart=/usr/sbin/hv_kvp_daemon -n
8+
9+
[Install]
10+
WantedBy=multi-user.target
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[Unit]
2+
Description=Hyper-V VSS Daemon
3+
Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-volume-shadow-copy-requestor
4+
BindsTo=sys-devices-virtual-misc-vmbus\x21hv_vss.device
5+
6+
[Service]
7+
ExecStart=/usr/sbin/hv_vss_daemon -n
8+
9+
[Install]
10+
WantedBy=multi-user.target
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
################################################################################
2+
#
3+
# hyperv-daemons
4+
#
5+
################################################################################
6+
7+
HYPERV_DAEMONS_VERSION = 4.15.1
8+
HYPERV_DAEMONS_SITE = https://www.kernel.org/pub/linux/kernel/v${HYPERV_DAEMONS_VERSION%%.*}.x
9+
HYPERV_DAEMONS_SOURCE = linux-$(HYPERV_DAEMONS_VERSION).tar.xz
10+
11+
define HYPERV_DAEMONS_BUILD_CMDS
12+
$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/
13+
endef
14+
15+
define HYPERV_DAEMONS_INSTALL_TARGET_CMDS
16+
$(INSTALL) -D -m 0755 \
17+
$(@D)/tools/hv/hv_fcopy_daemon \
18+
$(TARGET_DIR)/usr/sbin/hv_fcopy_daemon
19+
20+
$(INSTALL) -D -m 0755 \
21+
$(@D)/tools/hv/hv_kvp_daemon \
22+
$(TARGET_DIR)/usr/sbin/hv_kvp_daemon
23+
$(INSTALL) -D -m 0755 \
24+
$(@D)/tools/hv/hv_get_dhcp_info.sh \
25+
$(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dhcp_info
26+
$(INSTALL) -D -m 0755 \
27+
$(@D)/tools/hv/hv_get_dns_info.sh \
28+
$(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dns_info
29+
$(INSTALL) -D -m 0755 \
30+
$(@D)/tools/hv/hv_set_ifconfig.sh \
31+
$(TARGET_DIR)/usr/libexec/hypervkvpd/hv_set_ifconfig
32+
33+
$(INSTALL) -D -m 0755 \
34+
$(@D)/tools/hv/hv_vss_daemon \
35+
$(TARGET_DIR)/usr/sbin/hv_vss_daemon
36+
endef
37+
38+
define HYPERV_DAEMONS_INSTALL_INIT_SYSTEMD
39+
$(INSTALL) -D -m 644 \
40+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_fcopy.rules \
41+
$(TARGET_DIR)/etc/udev/rules.d/70-hv_fcopy.rules
42+
$(INSTALL) -D -m 644 \
43+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_kvp.rules \
44+
$(TARGET_DIR)/etc/udev/rules.d/70-hv_kvp.rules
45+
$(INSTALL) -D -m 644 \
46+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_vss.rules \
47+
$(TARGET_DIR)/etc/udev/rules.d/70-hv_vss.rules
48+
49+
$(INSTALL) -D -m 644 \
50+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_fcopy_daemon.service \
51+
$(TARGET_DIR)/usr/lib/systemd/system/hv_fcopy_daemon.service
52+
$(INSTALL) -D -m 644 \
53+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_kvp_daemon.service \
54+
$(TARGET_DIR)/usr/lib/systemd/system/hv_kvp_daemon.service
55+
$(INSTALL) -D -m 644 \
56+
$(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_vss_daemon.service \
57+
$(TARGET_DIR)/usr/lib/systemd/system/hv_vss_daemon.service
58+
59+
ln -fs /usr/lib/systemd/system/hv_fcopy_daemon.service \
60+
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_fcopy_daemon.service
61+
ln -fs /usr/lib/systemd/system/hv_kvp_daemon.service \
62+
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_kvp_daemon.service
63+
ln -fs /usr/lib/systemd/system/hv_vss_daemon.service \
64+
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_vss_daemon.service
65+
endef
66+
67+
$(eval $(generic-package))

0 commit comments

Comments
 (0)