summaryrefslogtreecommitdiffstats
path: root/loader/loader.c
diff options
context:
space:
mode:
Diffstat (limited to 'loader/loader.c')
-rw-r--r--loader/loader.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/loader/loader.c b/loader/loader.c
index b24b4670e..7b5333158 100644
--- a/loader/loader.c
+++ b/loader/loader.c
@@ -1778,13 +1778,21 @@ static char * setupKickstart(char * location, struct knownDevices * kd,
#ifdef INCLUDE_NETWORK
if (ksType == KS_CMD_NFS) {
+ int count = 0;
mlLoadModule("nfs", NULL, modLoaded, *modDepsPtr, NULL, modInfo, flags);
fullPath = alloca(strlen(host) + strlen(dir) + 2);
sprintf(fullPath, "%s:%s", host, dir);
logMessage("mounting nfs path %s", fullPath);
- if (doPwMount(fullPath, "/mnt/source", "nfs", 1, 0, NULL, NULL))
+ while (count < 3
+ && doPwMount(fullPath, "/mnt/source", "nfs", 1, 0, NULL, NULL)) {
+ logMessage("mount failed, retrying after 3 second sleep");
+ sleep(3);
+ count++;
+ }
+
+ if (count == 3)
return NULL;
if (mountLoopback("/mnt/source/RedHat/base/stage2.img",