[prev in list] [next in list] [prev in thread] [next in thread]
List: ipfire-development
Subject: [PATCH] BUG12445: Fix for Hyper-V stuck 8 minutes at boot
From: Thomas Cekal <admin () cekal ! org>
Date: 2021-03-31 22:42:35
Message-ID: 20210331224236.12971-1-admin () cekal ! org
[Download RAW message or body]
Fix for Bug 12445: There is no proper way to distinguish between MS Azure and a local
Hyper-V installation Procedure: try to get the metadata info from the
internal MS metadata service at IP 169.254.169.254 If this fails the system
is running on an local Hyper-V instance wget takes too long to exit if the IP
is not reachable Added --timeout and --tries param to wget to reduce the
duation from 8 minutes to 10 seconds 10 seconds at one try should be enough
Signed-off-by: Thomas Cekal <admin@cekal.org>
---
src/initscripts/helper/azure-setup | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/initscripts/helper/azure-setup b/src/initscripts/helper/azure-setup
index 5157712fc..a0d547588 100644
--- a/src/initscripts/helper/azure-setup
+++ b/src/initscripts/helper/azure-setup
@@ -9,7 +9,7 @@ export PATH=/usr/local/sbin:/usr/local/bin:${PATH}
get() {
local file="${1}"
- wget -qO - --header="Metadata:true" \
"http://169.254.169.254/metadata/instance/${file}?api-version=2019-06-01&format=text" \
+ wget --timeout=10 --tries=1 -qO - --header="Metadata:true" \
"http://169.254.169.254/metadata/instance/${file}?api-version=2019-06-01&format=text" \
}
format_mac() {
--
2.17.1
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic