Add Plugins Settings
Configure Email Notification Settings.
1. Download a plugin like follows. Make sure latest one and get it on the site below. http://docs.cacti.net/plugins
[root@localhost plugins]#cd /var/www/html/cacti/plugins
[root@localhost plugins]#wget http://docs.cacti.net/_media/plugin:settings-v0.71-1.tgz
[root@localhost plugins]#tar zxvf /var/www/html/cacti/plugins/plugin\:settings-v0.71-1.tgz
|
2. Login to Cacti admin site and click "Plugin Management" on the left menu and click cursor on the Settings field icon in the right pane.
3. Click cursor button to enable the plugin.
4. After enabling, the stauts turns to Active.
5. Click "Settings" on the left menu and move to "Mail/DNS" tab on the right pane and input items like follows and click "Save" button.
Test Mail ⇒ recipient's address for test mail
Mail Services ⇒ the service for using sending email
From Email Address ⇒ the address for "From"
From Name ⇒ the name for "From"
After saving settings, click "Send a Test Email" to make sure email is sent normally.
6. Before you test whether Cacti can send notification emails, you must enable the less secure apps feature in your Gmail account via the URL:
https://myaccount.google.com/lesssecureapps
|
7. After successing sending emails, it is displayed "Success".
Troubleshooting.
Let's get to the answer first of all! Try with the following command:
# getsebool httpd_can_sendmail
|
if it shows: httpd_can_sendmail --> off
switch it on with this:
# sudo setsebool -P httpd_can_sendmail 1
|
then try sending the email again.
This solution comes from this great page.
As it was pointed out from this article, you may also need to try sudo setsebool -P httpd_can_network_connect 1. While for my CentOS 7 vm hosted by DigitalOcean, it's not necessary.
The problem I met was failing to send out emails from a Drupal website, with the SMTP Authentication Support module, which relies on PHPMailer underneath. And the SMTP server used was Google.
BTW, I had suspected it was OpenSSL certificate problem and did some test but no luck. So by setting the $SMTPDebug level to 2 from the PHPMailer source code, I was able to capture the "Permission denied (13)" error message.
0 Post a Comment:
Post a Comment