]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/dird/restore.c
- Implement using pg_config for finding PostgreSQL files.
[bacula/bacula] / bacula / src / dird / restore.c
index 3e5cc366fa198f9bae9c852aa63cbc46d2a6a5c1..ff7b18c99cdaa3d57da9538ccf448b4ec61af0f3 100644 (file)
@@ -18,7 +18,7 @@
  *   Version $Id$
  */
 /*
-   Copyright (C) 2000-2005 Kern Sibbald
+   Copyright (C) 2000-2006 Kern Sibbald
 
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
@@ -43,6 +43,7 @@ static char storaddr[]     = "storage address=%s port=%d ssl=0\n";
 /* Responses received from File daemon */
 static char OKrestore[]   = "2000 OK restore\n";
 static char OKstore[]     = "2000 OK storage\n";
+static char OKbootstrap[] = "2000 OK bootstrap\n";
 
 /*
  * Do a restore of the specified files
@@ -107,6 +108,10 @@ bool do_restore(JCR *jcr)
    }
    Dmsg0(50, "Storage daemon connection OK\n");
 
+   if (!bnet_fsend(jcr->store_bsock, "run")) {
+      return false;
+   }
+
    /*
     * Start conversation with File daemon
     */
@@ -137,7 +142,8 @@ bool do_restore(JCR *jcr)
    /*
     * Send the bootstrap file -- what Volumes/files to restore
     */
-   if (!send_bootstrap_file(jcr)) {
+   if (!send_bootstrap_file(jcr, fd) ||
+       !response(jcr, fd, OKbootstrap, "Bootstrap", DISPLAY_ERROR)) {
       restore_cleanup(jcr, JS_ErrorTerminated);
       return false;
    }