]> xenbits.xensource.com Git - libvirt.git/commitdiff
rpc: wait longer for session daemon to start up
authorCole Robinson <crobinso@redhat.com>
Tue, 15 Mar 2016 21:04:32 +0000 (17:04 -0400)
committerCole Robinson <crobinso@redhat.com>
Wed, 16 Mar 2016 23:21:44 +0000 (19:21 -0400)
https://bugzilla.redhat.com/show_bug.cgi?id=1271183

We only wait 0.5 seconds for the session daemon to start up and present
its socket, which isn't sufficient for many users. Bump up the sleep
interval and retry amount so we wait for a total of 5.0 seconds.

src/rpc/virnetsocket.c

index b0d5b1cce83d29024469a58d5be9e393c665941d..d909b94d0fb5e437c15a0082245fbd13115adf28 100644 (file)
@@ -614,7 +614,7 @@ int virNetSocketNewConnectUNIX(const char *path,
     char *lockpath = NULL;
     int lockfd = -1;
     int fd = -1;
-    int retries = 100;
+    int retries = 500;
     virSocketAddr localAddr;
     virSocketAddr remoteAddr;
     char *rundir = NULL;
@@ -707,7 +707,7 @@ int virNetSocketNewConnectUNIX(const char *path,
             daemonLaunched = true;
         }
 
-        usleep(5000);
+        usleep(10000);
     }
 
     localAddr.len = sizeof(localAddr.data);