/*
Bacula® - The Network Backup Solution
- Copyright (C) 2000-2007 Free Software Foundation Europe e.V.
+ Copyright (C) 2000-2008 Free Software Foundation Europe e.V.
The main author of Bacula is Kern Sibbald, with contributions from
many others, a complete list can be found in the file AUTHORS.
init_reload();
daemon_start_time = time(NULL);
+ console_command = run_console_command;
+
while ((ch = getopt(argc, argv, "c:d:fg:r:stu:v?")) != -1) {
switch (ch) {
case 'c': /* specify config file */
read_state_file(director->working_directory, "bacula-dir", get_first_port_host_order(director->DIRaddrs));
}
+ load_dir_plugins(director->plugin_directory);
+
drop(uid, gid); /* reduce privileges if requested */
if (!check_catalog()) {
already_here = true;
stop_watchdog();
generate_daemon_event(NULL, "Exit");
+ unload_plugins();
write_state_file(director->working_directory, "bacula-dir", get_first_port_host_order(director->DIRaddrs));
delete_pid_file(director->pid_directory, "bacula-dir", get_first_port_host_order(director->DIRaddrs));
term_scheduler();