diff --git a/share/words.xml b/share/words.xml
index bf5365a3..3673aa94 100644
--- a/share/words.xml
+++ b/share/words.xml
@@ -2120,6 +2120,8 @@ Are you sure that you want to delete the server: [#!variable!server_name!#]? [Ty
Purging the Anvil!: [#!variable!anvil_name!#] (UUID: [#!variable!anvil_uuid!#]:
'. Available servers on this Anvil! system;]]>
Created the journald directory: [#!variable!directory!#].
+ Checking that the daemon: [#!variable!daemon!#] is running.
+ The daemon: [#!variable!daemon!#] was not running, starting it now.
Saved the mail server information successfully!
diff --git a/tools/anvil-daemon b/tools/anvil-daemon
index 17168b09..16d2b488 100755
--- a/tools/anvil-daemon
+++ b/tools/anvil-daemon
@@ -579,9 +579,12 @@ sub run_once
# Check to see if we need to do boot-time tasks. We only run these if we've just booted
boot_time_tasks($anvil);
+ # Check that the daemons we need are running.
+ check_daemons($anvil);
+
# Check the ssh stuff.
# NOTE: This actually runs again in the minutes tasks, but needs to run on boot as well.
- $anvil->System->check_ssh_keys({debug => 3});
+ $anvil->System->check_ssh_keys();
# Check setuid wrappers
check_setuid_wrappers($anvil);
@@ -597,6 +600,28 @@ sub run_once
return(0);
}
+sub check_daemons
+{
+ my ($anvil) = @_;
+
+ foreach my $daemon ("NetworkManager")
+ {
+ $anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, key => "message_0249", variables => { daemon => $daemon }});
+
+ my $running = $anvil->System->check_daemon({daemon => $daemon});
+ $anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { running => $running }});
+
+ if (not $running)
+ {
+ $anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, key => "message_0250", variables => { daemon => $daemon }});
+ my $return_code = $anvil->System->start_daemon({daemon => $daemon});
+ $anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { return_code => $return_code }});
+ }
+ }
+
+ return(0);
+}
+
sub check_journald
{
my ($anvil) = @_;