/*
* Amanda, The Advanced Maryland Automatic Network Disk Archiver
* Copyright (c) 1991-1999 University of Maryland at College Park
+ * Copyright (c) 2007-2012 Zmanda, Inc. All Rights Reserved.
* All Rights Reserved.
*
* Permission to use, copy, modify, distribute, and sell this software and its
int exit_status = EXIT_SUCCESS;
gboolean no_taper = FALSE;
gboolean from_client = FALSE;
+ gboolean exact_match = FALSE;
if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) {
printf("planner-%s\n", VERSION);
from_client = TRUE;
diskarg_offset += 1;
}
+ if (argc - diskarg_offset > 0 && g_str_equal(argv[diskarg_offset],
+ "--exact_match")) {
+ exact_match = TRUE;
+ diskarg_offset += 1;
+ }
run_server_global_scripts(EXECUTE_ON_PRE_ESTIMATE, get_config_name());
g_fprintf(stderr, _("%s: timestamp %s\n"),
get_pname(), planner_timestamp);
- errstr = match_disklist(&origq, argc-diskarg_offset,
+ errstr = match_disklist(&origq, exact_match, argc-diskarg_offset,
argv+diskarg_offset);
if (errstr) {
g_fprintf(stderr,"%s",errstr);
/* see if this matches the command-line arguments */
if (conf_autoflush == 1 &&
- !match_dumpfile(&file, argc-diskarg_offset,
+ !match_dumpfile(&file, exact_match, argc-diskarg_offset,
argv+diskarg_offset)) {
continue;
}
* reported.
*/
log_add(L_ERROR, "%s", errbuf);
+ for(dp = hostp->disks; dp != NULL; dp = dp->hostnext) {
+ if (dp->todo) {
+ qname = quote_string(dp->name);
+ est(dp)->state = DISK_DONE;
+ remove_disk(&waitq, dp);
+ enqueue_disk(&failq, dp);
+
+ est(dp)->errstr = g_strdup(errbuf);
+ g_fprintf(stderr, _("error result for host %s disk %s: %s\n"),
+ dp->host->hostname, qname, errbuf);
+ amfree(qname);
+ }
+ }
}
hostp->up = HOST_DONE;
amfree(errbuf);