From f18136dc9ec84c0afed4aebeec1b88e737455230 Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Fri, 29 Mar 2019 08:11:51 +0800 Subject: [PATCH 1/6] Install required scripts for Hyper-V KVP daemon Signed-off-by: Zhongcheng Lao --- .../package/hv-kvp-daemon/hv_kvp_daemon.mk | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk index 632bf36fc30c..a2e2f40f1c98 100644 --- a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk +++ b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk @@ -4,7 +4,7 @@ # ################################################################################ -HV_KVP_DAEMON_VERSION = 4.4.27 +HV_KVP_DAEMON_VERSION = 4.15.1 HV_KVP_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_KVP_DAEMON_VERSION%%.*}.x HV_KVP_DAEMON_SOURCE = linux-$(HV_KVP_DAEMON_VERSION).tar.xz @@ -16,6 +16,15 @@ define HV_KVP_DAEMON_INSTALL_TARGET_CMDS $(INSTALL) -D -m 0755 \ $(@D)/tools/hv/hv_kvp_daemon \ $(TARGET_DIR)/usr/sbin/hv_kvp_daemon + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_get_dhcp_info.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dhcp_info + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_get_dns_info.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dns_info + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_set_ifconfig.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_set_ifconfig endef define HV_KVP_DAEMON_INSTALL_INIT_SYSTEMD From 47f4d2ebacaf1b6decc18bf603ce5106973f436f Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Sat, 30 Mar 2019 15:49:21 +0800 Subject: [PATCH 2/6] Install Hyper-V VSS daemon Signed-off-by: Zhongcheng Lao --- deploy/iso/minikube-iso/package/Config.in | 1 + .../package/hv-vss-daemon/Config.in | 4 +++ .../package/hv-vss-daemon/hv_vss_daemon.mk | 30 +++++++++++++++++++ .../hv-vss-daemon/hv_vss_daemon.service | 13 ++++++++ 4 files changed, 48 insertions(+) create mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in create mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk create mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service diff --git a/deploy/iso/minikube-iso/package/Config.in b/deploy/iso/minikube-iso/package/Config.in index 2205935bac97..38f030c9e31f 100644 --- a/deploy/iso/minikube-iso/package/Config.in +++ b/deploy/iso/minikube-iso/package/Config.in @@ -8,6 +8,7 @@ menu "System tools" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-plugins-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-kvp-daemon/Config.in" + source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-vss-daemon/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/gluster/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/vbox-guest/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/containerd-bin/Config.in" diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in b/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in new file mode 100644 index 000000000000..f3d91e5278c0 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in @@ -0,0 +1,4 @@ +config BR2_PACKAGE_HV_VSS_DAEMON + bool "hv-vss-daemon" + default y + depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk new file mode 100644 index 000000000000..d87e48b891b0 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk @@ -0,0 +1,30 @@ +################################################################################ +# +# hv-vss-daemon +# +################################################################################ + +HV_VSS_DAEMON_VERSION = 4.15.1 +HV_VSS_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_VSS_DAEMON_VERSION%%.*}.x +HV_VSS_DAEMON_SOURCE = linux-$(HV_VSS_DAEMON_VERSION).tar.xz + +define HV_VSS_DAEMON_BUILD_CMDS + $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ +endef + +define HV_VSS_DAEMON_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_vss_daemon \ + $(TARGET_DIR)/usr/sbin/hv_vss_daemon +endef + +define HV_VSS_DAEMON_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-vss-daemon/hv_vss_daemon.service \ + $(TARGET_DIR)/usr/lib/systemd/system/hv_vss_daemon.service + + ln -fs /usr/lib/systemd/system/hv_vss_daemon.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_vss_daemon.service +endef + +$(eval $(generic-package)) diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service new file mode 100644 index 000000000000..ada767416924 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service @@ -0,0 +1,13 @@ +[Unit] +Description=Hyper-V VSS Daemon +Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-volume-shadow-copy-requestor +ConditionVirtualization=microsoft + +[Service] +Type=simple +Restart=always +RestartSec=3 +ExecStart=/usr/sbin/hv_vss_daemon -n + +[Install] +WantedBy=multi-user.target From def1a55472c84eb88155f2c373c00e17198617ae Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Sat, 30 Mar 2019 15:53:47 +0800 Subject: [PATCH 3/6] Install Hyper-V FCOPY daemon Signed-off-by: Zhongcheng Lao --- deploy/iso/minikube-iso/package/Config.in | 1 + .../package/hv-fcopy-daemon/Config.in | 4 +++ .../hv-fcopy-daemon/hv_fcopy_daemon.mk | 30 +++++++++++++++++++ .../hv-fcopy-daemon/hv_fcopy_daemon.service | 13 ++++++++ 4 files changed, 48 insertions(+) create mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in create mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk create mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service diff --git a/deploy/iso/minikube-iso/package/Config.in b/deploy/iso/minikube-iso/package/Config.in index 38f030c9e31f..3aa96e443fe9 100644 --- a/deploy/iso/minikube-iso/package/Config.in +++ b/deploy/iso/minikube-iso/package/Config.in @@ -7,6 +7,7 @@ menu "System tools" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/docker-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-plugins-bin/Config.in" + source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-fcopy-daemon/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-kvp-daemon/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-vss-daemon/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/gluster/Config.in" diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in new file mode 100644 index 000000000000..4f5d080baef9 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in @@ -0,0 +1,4 @@ +config BR2_PACKAGE_HV_FCOPY_DAEMON + bool "hv-fcopy-daemon" + default y + depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk new file mode 100644 index 000000000000..5eac706fa84e --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk @@ -0,0 +1,30 @@ +################################################################################ +# +# hv-fcopy-daemon +# +################################################################################ + +HV_FCOPY_DAEMON_VERSION = 4.15.1 +HV_FCOPY_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_FCOPY_DAEMON_VERSION%%.*}.x +HV_FCOPY_DAEMON_SOURCE = linux-$(HV_FCOPY_DAEMON_VERSION).tar.xz + +define HV_FCOPY_DAEMON_BUILD_CMDS + $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ +endef + +define HV_FCOPY_DAEMON_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_fcopy_daemon \ + $(TARGET_DIR)/usr/sbin/hv_fcopy_daemon +endef + +define HV_FCOPY_DAEMON_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-fcopy-daemon/hv_fcopy_daemon.service \ + $(TARGET_DIR)/usr/lib/systemd/system/hv_fcopy_daemon.service + + ln -fs /usr/lib/systemd/system/hv_fcopy_daemon.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_fcopy_daemon.service +endef + +$(eval $(generic-package)) diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service new file mode 100644 index 000000000000..f4544f1841fc --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service @@ -0,0 +1,13 @@ +[Unit] +Description=Hyper-V FCOPY Daemon +Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-guest-service-interface +ConditionVirtualization=microsoft + +[Service] +Type=simple +Restart=always +RestartSec=3 +ExecStart=/usr/sbin/hv_fcopy_daemon -n + +[Install] +WantedBy=multi-user.target From e0d7363fba05a409a1da325fa18c0471a8c3e4f0 Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Sat, 30 Mar 2019 19:55:10 +0800 Subject: [PATCH 4/6] Add udev rules to generate devices for Hyper-V daemons Signed-off-by: Zhongcheng Lao --- .../minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules | 1 + .../minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk | 4 ++++ .../package/hv-fcopy-daemon/hv_fcopy_daemon.service | 2 +- .../iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules | 1 + .../iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk | 4 ++++ .../package/hv-kvp-daemon/hv_kvp_daemon.service | 6 ++---- .../iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules | 1 + .../iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk | 4 ++++ .../package/hv-vss-daemon/hv_vss_daemon.service | 2 +- 9 files changed, 19 insertions(+), 6 deletions(-) create mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules create mode 100644 deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules create mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules new file mode 100644 index 000000000000..a186817c38f6 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules @@ -0,0 +1 @@ +SUBSYSTEM=="misc", KERNEL=="vmbus/hv_fcopy", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_fcopy_daemon.service" diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk index 5eac706fa84e..a246f596ac55 100644 --- a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk @@ -19,6 +19,10 @@ define HV_FCOPY_DAEMON_INSTALL_TARGET_CMDS endef define HV_FCOPY_DAEMON_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-fcopy-daemon/70-hv_fcopy.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_fcopy.rules + $(INSTALL) -D -m 644 \ $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-fcopy-daemon/hv_fcopy_daemon.service \ $(TARGET_DIR)/usr/lib/systemd/system/hv_fcopy_daemon.service diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service index f4544f1841fc..d5e35c609d18 100644 --- a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service +++ b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service @@ -1,7 +1,7 @@ [Unit] Description=Hyper-V FCOPY Daemon Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-guest-service-interface -ConditionVirtualization=microsoft +BindsTo=sys-devices-virtual-misc-vmbus\x21hv_fcopy.device [Service] Type=simple diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules b/deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules new file mode 100644 index 000000000000..7193fdda4593 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules @@ -0,0 +1 @@ +SUBSYSTEM=="misc", KERNEL=="vmbus/hv_kvp", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_kvp_daemon.service" diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk index a2e2f40f1c98..9938b8fde0c7 100644 --- a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk +++ b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk @@ -28,6 +28,10 @@ define HV_KVP_DAEMON_INSTALL_TARGET_CMDS endef define HV_KVP_DAEMON_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-kvp-daemon/70-hv_kvp.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_kvp.rules + $(INSTALL) -D -m 644 \ $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-kvp-daemon/hv_kvp_daemon.service \ $(TARGET_DIR)/usr/lib/systemd/system/hv_kvp_daemon.service diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service index 8dc1336cfdd6..aafc098bf11a 100644 --- a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service +++ b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service @@ -1,14 +1,12 @@ [Unit] Description=Hyper-V Key Value Pair Daemon -Documentation=https://technet.microsoft.com/en-us/library/dn798287(v=ws.11).aspx -ConditionVirtualization=microsoft - +Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-data-exchange-service-kvp +BindsTo=sys-devices-virtual-misc-vmbus\x21hv_kvp.device [Service] Type=simple Restart=always RestartSec=3 - ExecStart=/usr/sbin/hv_kvp_daemon -n [Install] diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules b/deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules new file mode 100644 index 000000000000..1274dec1ebc9 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules @@ -0,0 +1 @@ +SUBSYSTEM=="misc", KERNEL=="vmbus/hv_vss", TAG+="systemd", ENV{SYSTEMD_WANTS}+="hv_vss_daemon.service" diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk index d87e48b891b0..7cecad18b803 100644 --- a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk @@ -19,6 +19,10 @@ define HV_VSS_DAEMON_INSTALL_TARGET_CMDS endef define HV_VSS_DAEMON_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-vss-daemon/70-hv_vss.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_vss.rules + $(INSTALL) -D -m 644 \ $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-vss-daemon/hv_vss_daemon.service \ $(TARGET_DIR)/usr/lib/systemd/system/hv_vss_daemon.service diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service index ada767416924..6c69a7bc2301 100644 --- a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service +++ b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service @@ -1,7 +1,7 @@ [Unit] Description=Hyper-V VSS Daemon Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/reference/integration-services#hyper-v-volume-shadow-copy-requestor -ConditionVirtualization=microsoft +BindsTo=sys-devices-virtual-misc-vmbus\x21hv_vss.device [Service] Type=simple From e8cdc4ba85f4cc944e5af1a5d3fc1aedd184b4dc Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Sun, 31 Mar 2019 02:08:56 +0800 Subject: [PATCH 5/6] Merge Hyper-V deamon packages to hyperv-daemons Signed-off-by: Zhongcheng Lao --- deploy/iso/minikube-iso/package/Config.in | 4 +- .../package/hv-fcopy-daemon/Config.in | 4 -- .../hv-fcopy-daemon/hv_fcopy_daemon.mk | 34 ---------- .../package/hv-kvp-daemon/Config.in | 4 -- .../package/hv-kvp-daemon/hv_kvp_daemon.mk | 43 ------------ .../package/hv-vss-daemon/Config.in | 4 -- .../package/hv-vss-daemon/hv_vss_daemon.mk | 34 ---------- .../70-hv_fcopy.rules | 0 .../70-hv_kvp.rules | 0 .../70-hv_vss.rules | 0 .../package/hyperv-daemons/Config.in | 4 ++ .../hv_fcopy_daemon.service | 0 .../hv_kvp_daemon.service | 0 .../hv_vss_daemon.service | 0 .../package/hyperv-daemons/hyperv-daemons.mk | 67 +++++++++++++++++++ 15 files changed, 72 insertions(+), 126 deletions(-) delete mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in delete mode 100644 deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk delete mode 100644 deploy/iso/minikube-iso/package/hv-kvp-daemon/Config.in delete mode 100644 deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk delete mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in delete mode 100644 deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk rename deploy/iso/minikube-iso/package/{hv-fcopy-daemon => hyperv-daemons}/70-hv_fcopy.rules (100%) rename deploy/iso/minikube-iso/package/{hv-kvp-daemon => hyperv-daemons}/70-hv_kvp.rules (100%) rename deploy/iso/minikube-iso/package/{hv-vss-daemon => hyperv-daemons}/70-hv_vss.rules (100%) create mode 100644 deploy/iso/minikube-iso/package/hyperv-daemons/Config.in rename deploy/iso/minikube-iso/package/{hv-fcopy-daemon => hyperv-daemons}/hv_fcopy_daemon.service (100%) rename deploy/iso/minikube-iso/package/{hv-kvp-daemon => hyperv-daemons}/hv_kvp_daemon.service (100%) rename deploy/iso/minikube-iso/package/{hv-vss-daemon => hyperv-daemons}/hv_vss_daemon.service (100%) create mode 100644 deploy/iso/minikube-iso/package/hyperv-daemons/hyperv-daemons.mk diff --git a/deploy/iso/minikube-iso/package/Config.in b/deploy/iso/minikube-iso/package/Config.in index 3aa96e443fe9..d33f9e33565a 100644 --- a/deploy/iso/minikube-iso/package/Config.in +++ b/deploy/iso/minikube-iso/package/Config.in @@ -7,9 +7,7 @@ menu "System tools" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/docker-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-bin/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni-plugins-bin/Config.in" - source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-fcopy-daemon/Config.in" - source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-kvp-daemon/Config.in" - source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hv-vss-daemon/Config.in" + source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hyperv-daemons/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/gluster/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/vbox-guest/Config.in" source "$BR2_EXTERNAL_MINIKUBE_PATH/package/containerd-bin/Config.in" diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in deleted file mode 100644 index 4f5d080baef9..000000000000 --- a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/Config.in +++ /dev/null @@ -1,4 +0,0 @@ -config BR2_PACKAGE_HV_FCOPY_DAEMON - bool "hv-fcopy-daemon" - default y - depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk b/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk deleted file mode 100644 index a246f596ac55..000000000000 --- a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.mk +++ /dev/null @@ -1,34 +0,0 @@ -################################################################################ -# -# hv-fcopy-daemon -# -################################################################################ - -HV_FCOPY_DAEMON_VERSION = 4.15.1 -HV_FCOPY_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_FCOPY_DAEMON_VERSION%%.*}.x -HV_FCOPY_DAEMON_SOURCE = linux-$(HV_FCOPY_DAEMON_VERSION).tar.xz - -define HV_FCOPY_DAEMON_BUILD_CMDS - $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ -endef - -define HV_FCOPY_DAEMON_INSTALL_TARGET_CMDS - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_fcopy_daemon \ - $(TARGET_DIR)/usr/sbin/hv_fcopy_daemon -endef - -define HV_FCOPY_DAEMON_INSTALL_INIT_SYSTEMD - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-fcopy-daemon/70-hv_fcopy.rules \ - $(TARGET_DIR)/etc/udev/rules.d/70-hv_fcopy.rules - - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-fcopy-daemon/hv_fcopy_daemon.service \ - $(TARGET_DIR)/usr/lib/systemd/system/hv_fcopy_daemon.service - - ln -fs /usr/lib/systemd/system/hv_fcopy_daemon.service \ - $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_fcopy_daemon.service -endef - -$(eval $(generic-package)) diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/Config.in b/deploy/iso/minikube-iso/package/hv-kvp-daemon/Config.in deleted file mode 100644 index b3c164b3b85f..000000000000 --- a/deploy/iso/minikube-iso/package/hv-kvp-daemon/Config.in +++ /dev/null @@ -1,4 +0,0 @@ -config BR2_PACKAGE_HV_KVP_DAEMON - bool "hv-kvp-daemon" - default y - depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk b/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk deleted file mode 100644 index 9938b8fde0c7..000000000000 --- a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.mk +++ /dev/null @@ -1,43 +0,0 @@ -################################################################################ -# -# hv-kvp-daemon -# -################################################################################ - -HV_KVP_DAEMON_VERSION = 4.15.1 -HV_KVP_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_KVP_DAEMON_VERSION%%.*}.x -HV_KVP_DAEMON_SOURCE = linux-$(HV_KVP_DAEMON_VERSION).tar.xz - -define HV_KVP_DAEMON_BUILD_CMDS - $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ -endef - -define HV_KVP_DAEMON_INSTALL_TARGET_CMDS - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_kvp_daemon \ - $(TARGET_DIR)/usr/sbin/hv_kvp_daemon - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_get_dhcp_info.sh \ - $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dhcp_info - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_get_dns_info.sh \ - $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dns_info - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_set_ifconfig.sh \ - $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_set_ifconfig -endef - -define HV_KVP_DAEMON_INSTALL_INIT_SYSTEMD - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-kvp-daemon/70-hv_kvp.rules \ - $(TARGET_DIR)/etc/udev/rules.d/70-hv_kvp.rules - - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-kvp-daemon/hv_kvp_daemon.service \ - $(TARGET_DIR)/usr/lib/systemd/system/hv_kvp_daemon.service - - ln -fs /usr/lib/systemd/system/hv_kvp_daemon.service \ - $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_kvp_daemon.service -endef - -$(eval $(generic-package)) diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in b/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in deleted file mode 100644 index f3d91e5278c0..000000000000 --- a/deploy/iso/minikube-iso/package/hv-vss-daemon/Config.in +++ /dev/null @@ -1,4 +0,0 @@ -config BR2_PACKAGE_HV_VSS_DAEMON - bool "hv-vss-daemon" - default y - depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk b/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk deleted file mode 100644 index 7cecad18b803..000000000000 --- a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.mk +++ /dev/null @@ -1,34 +0,0 @@ -################################################################################ -# -# hv-vss-daemon -# -################################################################################ - -HV_VSS_DAEMON_VERSION = 4.15.1 -HV_VSS_DAEMON_SITE = https://www.kernel.org/pub/linux/kernel/v${HV_VSS_DAEMON_VERSION%%.*}.x -HV_VSS_DAEMON_SOURCE = linux-$(HV_VSS_DAEMON_VERSION).tar.xz - -define HV_VSS_DAEMON_BUILD_CMDS - $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ -endef - -define HV_VSS_DAEMON_INSTALL_TARGET_CMDS - $(INSTALL) -D -m 0755 \ - $(@D)/tools/hv/hv_vss_daemon \ - $(TARGET_DIR)/usr/sbin/hv_vss_daemon -endef - -define HV_VSS_DAEMON_INSTALL_INIT_SYSTEMD - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-vss-daemon/70-hv_vss.rules \ - $(TARGET_DIR)/etc/udev/rules.d/70-hv_vss.rules - - $(INSTALL) -D -m 644 \ - $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hv-vss-daemon/hv_vss_daemon.service \ - $(TARGET_DIR)/usr/lib/systemd/system/hv_vss_daemon.service - - ln -fs /usr/lib/systemd/system/hv_vss_daemon.service \ - $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_vss_daemon.service -endef - -$(eval $(generic-package)) diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules b/deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_fcopy.rules similarity index 100% rename from deploy/iso/minikube-iso/package/hv-fcopy-daemon/70-hv_fcopy.rules rename to deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_fcopy.rules diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules b/deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_kvp.rules similarity index 100% rename from deploy/iso/minikube-iso/package/hv-kvp-daemon/70-hv_kvp.rules rename to deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_kvp.rules diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules b/deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_vss.rules similarity index 100% rename from deploy/iso/minikube-iso/package/hv-vss-daemon/70-hv_vss.rules rename to deploy/iso/minikube-iso/package/hyperv-daemons/70-hv_vss.rules diff --git a/deploy/iso/minikube-iso/package/hyperv-daemons/Config.in b/deploy/iso/minikube-iso/package/hyperv-daemons/Config.in new file mode 100644 index 000000000000..834b31bdcb64 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hyperv-daemons/Config.in @@ -0,0 +1,4 @@ +config BR2_PACKAGE_HYPERV_DAEMONS + bool "hyperv-daemons" + default y + depends on BR2_x86_64 diff --git a/deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service similarity index 100% rename from deploy/iso/minikube-iso/package/hv-fcopy-daemon/hv_fcopy_daemon.service rename to deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service diff --git a/deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service similarity index 100% rename from deploy/iso/minikube-iso/package/hv-kvp-daemon/hv_kvp_daemon.service rename to deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service diff --git a/deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service similarity index 100% rename from deploy/iso/minikube-iso/package/hv-vss-daemon/hv_vss_daemon.service rename to deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service diff --git a/deploy/iso/minikube-iso/package/hyperv-daemons/hyperv-daemons.mk b/deploy/iso/minikube-iso/package/hyperv-daemons/hyperv-daemons.mk new file mode 100644 index 000000000000..d0fadf5b1c72 --- /dev/null +++ b/deploy/iso/minikube-iso/package/hyperv-daemons/hyperv-daemons.mk @@ -0,0 +1,67 @@ +################################################################################ +# +# hyperv-daemons +# +################################################################################ + +HYPERV_DAEMONS_VERSION = 4.15.1 +HYPERV_DAEMONS_SITE = https://www.kernel.org/pub/linux/kernel/v${HYPERV_DAEMONS_VERSION%%.*}.x +HYPERV_DAEMONS_SOURCE = linux-$(HYPERV_DAEMONS_VERSION).tar.xz + +define HYPERV_DAEMONS_BUILD_CMDS + $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/tools/hv/ +endef + +define HYPERV_DAEMONS_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_fcopy_daemon \ + $(TARGET_DIR)/usr/sbin/hv_fcopy_daemon + + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_kvp_daemon \ + $(TARGET_DIR)/usr/sbin/hv_kvp_daemon + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_get_dhcp_info.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dhcp_info + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_get_dns_info.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_get_dns_info + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_set_ifconfig.sh \ + $(TARGET_DIR)/usr/libexec/hypervkvpd/hv_set_ifconfig + + $(INSTALL) -D -m 0755 \ + $(@D)/tools/hv/hv_vss_daemon \ + $(TARGET_DIR)/usr/sbin/hv_vss_daemon +endef + +define HYPERV_DAEMONS_INSTALL_INIT_SYSTEMD + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_fcopy.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_fcopy.rules + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_kvp.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_kvp.rules + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/70-hv_vss.rules \ + $(TARGET_DIR)/etc/udev/rules.d/70-hv_vss.rules + + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_fcopy_daemon.service \ + $(TARGET_DIR)/usr/lib/systemd/system/hv_fcopy_daemon.service + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_kvp_daemon.service \ + $(TARGET_DIR)/usr/lib/systemd/system/hv_kvp_daemon.service + $(INSTALL) -D -m 644 \ + $(BR2_EXTERNAL_MINIKUBE_PATH)/package/hyperv-daemons/hv_vss_daemon.service \ + $(TARGET_DIR)/usr/lib/systemd/system/hv_vss_daemon.service + + ln -fs /usr/lib/systemd/system/hv_fcopy_daemon.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_fcopy_daemon.service + ln -fs /usr/lib/systemd/system/hv_kvp_daemon.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_kvp_daemon.service + ln -fs /usr/lib/systemd/system/hv_vss_daemon.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/hv_vss_daemon.service +endef + +$(eval $(generic-package)) From 9a5f3c267319dafff146894a4704bc5501943047 Mon Sep 17 00:00:00 2001 From: Zhongcheng Lao Date: Sun, 31 Mar 2019 14:06:56 +0800 Subject: [PATCH 6/6] Do not attempt to restart service on failures for Hyper-V daemons Service restart may not work when a specific integration service is disabled in the VM setting. Remove the setting for performance concerns. --- .../package/hyperv-daemons/hv_fcopy_daemon.service | 3 --- .../minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service | 3 --- .../minikube-iso/package/hyperv-daemons/hv_vss_daemon.service | 3 --- 3 files changed, 9 deletions(-) diff --git a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service index d5e35c609d18..88fed6f5ada0 100644 --- a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service +++ b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_fcopy_daemon.service @@ -4,9 +4,6 @@ Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows BindsTo=sys-devices-virtual-misc-vmbus\x21hv_fcopy.device [Service] -Type=simple -Restart=always -RestartSec=3 ExecStart=/usr/sbin/hv_fcopy_daemon -n [Install] diff --git a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service index aafc098bf11a..6cd7e9d6c127 100644 --- a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service +++ b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_kvp_daemon.service @@ -4,9 +4,6 @@ Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows BindsTo=sys-devices-virtual-misc-vmbus\x21hv_kvp.device [Service] -Type=simple -Restart=always -RestartSec=3 ExecStart=/usr/sbin/hv_kvp_daemon -n [Install] diff --git a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service index 6c69a7bc2301..d12aa1dded2c 100644 --- a/deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service +++ b/deploy/iso/minikube-iso/package/hyperv-daemons/hv_vss_daemon.service @@ -4,9 +4,6 @@ Documentation=https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows BindsTo=sys-devices-virtual-misc-vmbus\x21hv_vss.device [Service] -Type=simple -Restart=always -RestartSec=3 ExecStart=/usr/sbin/hv_vss_daemon -n [Install]