Jenkins Email Notification | Connection error sending email, retrying once more in 10 seconds

preview_player
Показать описание
In this video, we will be addressing "Connection error sending email, retrying once more in 10 seconds" error while sending email from Jenkins server and see how to configure SMTP server for Email Notification from Jenkins server and see the Gmail Inbox to confirm if Email from Jenkins is received or not.

Here is the issue-

"Connection error sending email, retrying once more in 10 seconds...
Connection error sending email, retrying once more in 10 seconds...
Failed after second try sending email
Finished: SUCCESS"

Fix/configuration is available in this video along with how to generate App passwords steps.

Moreover, To send email from a Jenkins job, you can use the built-in email notification and extended email notification feature or the Email Extension plugin.

Built-in email notification

Go to Manage Jenkins - Configure System.
Scroll down to the Email Notification section and configure your SMTP settings.
Go to your Jenkins job and click Add post-build action.
Select Email Notification from the list of actions.
Enter the email addresses of the recipients you want to send the email to.
Configure the rest of the email settings, such as the subject line and body of the email.
Click Save.

Email Extension plugin

Install the Email Extension plugin from the Jenkins Plugin Manager.
Go to Manage Jenkins - Configure System - Extended E-mail Notification.
Configure your SMTP settings.
Go to your Jenkins job and click Add post-build action.
Select Extended Email Notification from the list of actions.
Enter the email addresses of the recipients you want to send the email to.
Configure the rest of the email settings, such as the subject line and body of the email.
Click Save.

Once you have configured your email notification settings, you can test them by building your job. If the email is not sent, check your Jenkins console log for any errors.

Here are some additional tips for sending email from Jenkins:

You can use variables in your email subject line and body to customize the email for each build.
You can attach files to your emails, such as build reports or test logs.
You can use different email notification settings for different build statuses (e.g., success, failure, unstable).
You can use the Email Extension plugin to send emails from triggers, such as when a job is rescheduled or cancelled.
Рекомендации по теме
Комментарии
Автор

Finally I resolved this issue. Thank you 😃

akshaysarve
Автор

Faced the same error. Thanks for the video 😇

sivabalu
Автор

Well explained, I understand everything

anamikashukla-pj