Install the exim4 package, run Ubuntu’s Exim configuration wizard, and select mail sent by smarthost; no local mail. Enter your relay host (and port when required), configure authentication and TLS if the relay requires them, then regenerate the configuration and restart Exim:
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
sudo apt update
sudo apt install exim4
sudo dpkg-reconfigure exim4-config
sudo update-exim4.conf
sudo systemctl restart exim4
This setup makes the Ubuntu machine submit locally generated messages to a remote SMTP relay instead of delivering directly to recipient mail servers or accepting mail for an external domain.
As an Amazon Associate I earn from qualifying purchases.
Free tools Windows power users keep installed
One-click scans. No signup required.
What a send-only Exim server does
A send-only host generates messages locally—for example, monitoring alerts, cron output, application notifications, and password-reset mail—but hands those messages to a configured SMTP smarthost. The smarthost performs onward delivery.
The important wizard choice is mail sent by smarthost; no local mail. Debian describes this mode as suitable for a client system that is not responsible for a local email domain. It prevents the Ubuntu machine from being configured as the destination for normal inbound mail while preserving local submission for system and application messages.
#1 Best Overall
- [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
- [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
- [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
- [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
- [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.
Using a relay is also the usual choice for a server with a dynamic or otherwise unsuitable public IP address. Debian’s Exim configuration template notes that many receiving systems block direct connections from dynamic addresses as spam protection. A remote smarthost centralizes delivery reputation, authentication, retry handling, and recipient-server communication.
Compare Exim’s main configuration modes
| Wizard choice | Use it when | What it means | Main trade-off |
|---|---|---|---|
| Mail sent by smarthost; no local mail | The Ubuntu host only needs outbound notifications or application mail. | Messages created locally are submitted to the relay; the host is not responsible for a local email domain. | Delivery depends on the relay’s availability, credentials, sender policy, and TLS requirements. |
| Internet site | The host has a stable, properly configured public mail identity and is intended to deliver directly. | Exim connects to recipient mail servers itself. | Requires stronger DNS, reputation, TLS, queue, abuse, and inbound-mail controls. It is not the normal send-only choice. |
| Local delivery only | Mail must remain on the Ubuntu host. | Exim delivers to local mailboxes and does not provide remote delivery. | It does not satisfy a requirement to send notifications to external recipients. |
Prepare the relay details before installing
Have the following information from your SMTP relay service before opening the wizard:
- The relay’s fully qualified hostname or IP address.
- The SMTP port. If the relay uses a non-standard port, Debian’s Exim syntax appends it with two colons, such as
smarthost.example::587. - Whether the relay requires SMTP authentication, and which authentication mechanism it supports.
- The username, password, and permitted sender addresses or domains, if authentication is required.
- The relay’s TLS requirement, including whether password-based authentication is refused unless the connection is encrypted.
Also confirm that the Ubuntu host can resolve the relay hostname and make outbound connections to the selected port. A local firewall, cloud egress policy, or provider restriction can prevent delivery even when Exim is configured correctly.
You need administrative access because package installation, Exim’s generated configuration, and the service restart all require root privileges. Do not put real SMTP credentials in a public article, an issue report, or a shell command that could remain in command history.
Install the Exim4 package
Refresh Ubuntu’s package metadata and install Exim4:
sudo apt update
sudo apt install exim4
The package installation provides Exim and Debian’s configuration framework. Ubuntu’s documented installation command is sudo apt install exim4. On a new installation, package setup may open configuration questions; you can complete them there or rerun the full wizard explicitly in the next step.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Do not assume that installing the package alone created the send-only configuration you want. The routing mode is selected in Debian’s Exim configuration wizard.
Run the Debian configuration wizard
Open the wizard at any time with:
sudo dpkg-reconfigure exim4-config
The wizard can maintain one generated configuration file or a split configuration under /etc/exim4/conf.d. Both layouts are supported by Ubuntu and Debian. This file-layout decision does not change the mail-routing goal; choose the layout that fits how your system is managed, and make future changes through the Debian configuration interface and source settings rather than editing generated output.
Select the send-only mode
- When the wizard asks for the general type of mail configuration, select mail sent by smarthost; no local mail.
- When prompted for the outgoing smarthost, enter the relay’s hostname or IP address.
- If the relay requires a specific port, append it with two colons. For example, enter
smarthost.example::587when the relay documentation specifies port 587. - Continue through the remaining prompts, supplying values required by your relay’s instructions. Avoid selecting Internet site unless this machine is intentionally configured for direct Internet delivery.
The phrase no local mail does not mean that applications on the Ubuntu host cannot create messages. It means the host is not configured as the delivery destination for a local email domain. A locally submitted alert is routed outward to the smarthost.
Rank #2
- 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
- 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
- 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
- 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
- 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.
Enter the relay address precisely
Use the exact hostname supplied by the relay. A typo can look like an authentication failure when the real problem is DNS resolution or a connection to the wrong server. If the relay gives separate hostnames for submission and direct delivery, use the submission endpoint intended for authenticated clients.
Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchPC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Use the port format supported by the wizard rather than adding a colon in an ad-hoc way. The documented Exim form is host::port. Follow the relay’s instructions for whether that port expects TLS from connection start or an SMTP upgrade before authentication.
Configure SMTP authentication and TLS
Some relays accept mail only after SMTP authentication. When the relay requires it, configure Exim’s authentication mechanism and credentials according to that relay’s instructions. The exact mechanism and credential format are relay-specific, so copying settings intended for a different service can cause authentication or TLS errors.
Ubuntu’s Exim documentation warns that password-based authentication must be protected with TLS. Treat these as one configuration decision: do not enable a password-authenticated submission path without the encryption required by the relay.
- Record the relay username and password in the protected Exim credential configuration requested by the relay’s instructions.
- Do not place secrets directly in a command line, a public shell transcript, or a world-readable file.
- Use the relay’s required TLS mode and port. A successful TCP connection alone does not prove that SMTP authentication can be negotiated.
- Check the relay’s allowed sender addresses. A relay can authenticate the account successfully and still reject a sender address that the account is not permitted to use.
If the relay does not require authentication, do not invent credentials. Configure the smarthost address and the relay’s stated transport requirements only.
Generate and activate Exim’s configuration
After completing the wizard or changing its source settings, build the active Exim configuration:
sudo update-exim4.conf
This command combines Debian-managed answers and templates into the configuration Exim reads. Generated files should not be hand-edited because a later regeneration can overwrite those changes. Make changes through dpkg-reconfigure exim4-config or the documented source settings, then run update-exim4.conf again.
Restart Exim so the running service uses the regenerated configuration:
sudo systemctl restart exim4
A restart applies the new smarthost, authentication, and transport settings. If the restart reports an error, resolve the configuration problem before testing mail; a service that did not reload the intended configuration cannot provide a meaningful delivery test.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Rank #3
- [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
- [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
- [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
- [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
- [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
Send a test message and inspect the queue
Submit a message from the Ubuntu host using a local mail client such as mail, or use an application that submits through /usr/sbin/sendmail. For a direct command-line check, an application can provide a message to the sendmail-compatible interface, for example:
printf 'Subject: Exim testnnThis is a test message.n' | /usr/sbin/sendmail [email protected]
Replace the recipient with an address you control or are authorized to test. The command submits the message locally; it does not by itself prove that the relay accepted or delivered it.
Check whether Exim has queued mail
Display the queue with:
exim -bp
A message may remain queued while Exim retries a temporary failure. An empty queue after successful relay acceptance is expected, but do not treat a non-empty queue as proof of permanent failure without reading the associated log entry.
When appropriate, request an immediate queue run with:
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →exim -qff
This asks Exim to attempt delivery of queued messages, including messages that would otherwise wait for their retry interval. Use it after correcting a transient DNS, network, credential, or TLS problem; repeatedly forcing a queue run will not fix a persistent rejection.
Read Exim’s delivery logs
Inspect the Exim logs at:
/var/log/exim4/mainlogfor connection, routing, queue, and delivery activity./var/log/exim4/rejectlogfor messages rejected during SMTP processing.
Look for the relay hostname, the SMTP response code and text, whether authentication completed, and whether Exim marked the message as delivered, deferred, or rejected. The exact SMTP response is more useful than a generic application error.
Confirm send-only behavior
Verify that the test message is handed to the configured smarthost rather than sent directly to the recipient’s mail server. The log should show the relay connection and its response. Also confirm that the host is not accepting normal inbound mail for external domains; selecting the smarthost/no-local-mail mode is intended to avoid making this Ubuntu machine responsible for inbound Internet mail.
Understand local submission versus local delivery
Applications normally hand a message to Exim through the local sendmail-compatible interface. That local handoff is still available in smarthost mode, so cron jobs and monitoring software can continue to submit mail without knowing the relay’s credentials. Exim then routes the message to the configured remote host.
Recommended Free Tools
Local submission should not be confused with hosting mailboxes. The no-local-mail choice tells Exim not to treat the Ubuntu machine as the authoritative destination for an external domain. If a message is addressed to a remote recipient, the expected path is local submission, queueing if necessary, connection to the smarthost, and onward delivery by that smarthost.
Rank #4
- Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
- Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
- All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
- Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
- Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.
Choose the right port and encryption combination
A relay may publish more than one endpoint, such as a submission service for authenticated clients and a separate service for other traffic. Use the hostname and port combination supplied for your account. Enter a non-standard port in the wizard as host::port, for example smarthost.example::587.
Port selection and TLS mode must agree. Some services expect encryption immediately, while others expect an SMTP connection that is upgraded before authentication. Exim can reach the server and still fail if the transport settings do not match that sequence. Confirm the expected mode in the relay documentation before changing credentials or repeatedly retrying.
Operational checklist before declaring success
- Confirm the wizard shows mail sent by smarthost; no local mail.
- Verify the smarthost name and optional
::portsyntax in the source configuration. - Confirm DNS resolution and outbound firewall access from this Ubuntu host.
- Ensure authentication is configured only when the relay requires it, with credentials protected from other users.
- Ensure password authentication is protected by the relay’s required TLS mode.
- Regenerate the configuration and restart Exim after every source change.
- Submit a test message through
/usr/sbin/sendmailor a mail client. - Check
exim -bp, then correlate the message ID and SMTP response in/var/log/exim4/mainlog. - Verify the recipient received the message and that the relay, not the Ubuntu host, performed onward delivery.
Troubleshoot common failures
The wrong wizard mode was selected
Run the wizard again:
sudo dpkg-reconfigure exim4-config
Select mail sent by smarthost; no local mail, review the relay address, regenerate the configuration, and restart Exim. Do not try to turn an Internet-site configuration into a smarthost by editing generated router or transport files manually.
The smarthost value is missing or incorrect
Check /etc/exim4/update-exim4.conf.conf for the smarthost setting and compare it with the relay’s exact hostname and port. This is a source configuration file; generated output should still be changed through the supported configuration process. After correcting it, run:
sudo update-exim4.conf
sudo systemctl restart exim4
DNS or network access fails
If the log shows that the relay hostname cannot be resolved, verify the host’s DNS configuration and the spelling of the relay name. If resolution succeeds but the connection times out or is refused, check outbound firewall and cloud egress rules for the relay’s SMTP port. A relay cannot accept mail from a host that cannot reach it.
Authentication is rejected
Check the username, password, authentication mechanism, and sender permissions against the relay’s current instructions. Make sure the selected port and TLS mode match what the relay expects. Password authentication without the required TLS protection can be refused even when the credentials are correct.
TLS negotiation fails
Read the SMTP response in /var/log/exim4/mainlog and compare the configured transport requirements with the relay’s instructions. Confirm that the relay hostname, port, and encryption mode belong together; changing only one of them can produce a handshake or protocol error.
Messages remain deferred
A deferred message means Exim has not completed delivery and will retry according to its queue policy. Read the log entry for the reason, then check DNS, egress filtering, credentials, TLS negotiation, and the relay’s sender policy. After fixing the cause, run sudo exim -qff and inspect the queue and log again.
The relay accepts the connection but rejects the sender
Some relays restrict the envelope sender or require a verified domain. Compare the sender used by the application with the addresses authorized for the SMTP account. This is a relay policy issue, not evidence that Exim’s smarthost routing is bypassing the relay.
Best Value
Keep the configuration maintainable
- Document the relay hostname, port, TLS requirement, and the account or sender policy used by the host, without recording the password in an exposed location.
- Make source changes through Debian’s Exim configuration tools, then always run
sudo update-exim4.confand restart Exim. - Retain a simple test procedure: submit one message, check
exim -bp, inspect/var/log/exim4/mainlog, and verify the recipient received it. - When changing relay credentials or ports, test from the Ubuntu host and check the SMTP response rather than relying only on an application’s success message.
- Keep the host in smarthost/no-local-mail mode unless its role has deliberately changed to direct delivery or local mailbox hosting.
When direct delivery is appropriate
The Internet site option is a different operating model, not a shortcut for send-only mail. It assumes a stable public identity and requires the operator to handle DNS, reputation, TLS, queue management, abuse controls, and inbound SMTP exposure. Receiving systems may reject a directly connected host with a dynamic address, and a misconfigured direct sender can damage delivery reputation. Unless the Ubuntu machine is intentionally becoming a complete mail server, the smarthost option has fewer moving parts.
Final decision
For an Ubuntu machine that only sends alerts and application mail, choose mail sent by smarthost; no local mail in dpkg-reconfigure exim4-config. Supply the relay endpoint and any required authentication and TLS settings, regenerate with update-exim4.conf, restart Exim, and validate the handoff through the queue and logs. This gives the host an outbound mail path without turning it into an Internet-facing inbound mail server.
Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problemsFrequently Asked Questions
How do I install Exim on Ubuntu for outgoing mail only?
Run sudo apt update and sudo apt install exim4, then open sudo dpkg-reconfigure exim4-config and choose mail sent by smarthost; no local mail. Enter the relay endpoint, regenerate with sudo update-exim4.conf, and restart Exim.
Which Exim option disables local mail?
Select mail sent by smarthost; no local mail. It allows local applications to submit messages while Exim sends them to a remote relay instead of hosting a local email domain.
How do I configure an SMTP smarthost port?
Enter the relay hostname in the wizard and append a non-standard port with two colons, such as smarthost.example::587. Use the exact port and TLS mode specified by the relay.
Do I need SMTP credentials?
Only when the relay requires authentication. Configure the required mechanism and username/password according to the relay’s instructions, protect the credentials, and use TLS for password-based authentication.
Recommended Free Tools
How can I verify that Exim handed mail to the relay?
Submit a test through /usr/sbin/sendmail, inspect exim -bp, and read /var/log/exim4/mainlog. The log should show the smarthost connection and its SMTP response.
What should I do if a message stays in the queue?
Read the associated main-log entry for the SMTP status, then check DNS, outbound firewall rules, credentials, TLS negotiation, and sender permissions. After correcting a temporary problem, run sudo exim -qff.
Where are Exim’s important configuration files?
Debian can use one generated configuration file or split files under /etc/exim4/conf.d. The smarthost source setting is recorded in /etc/exim4/update-exim4.conf.conf; regenerate rather than editing generated output.
Why is a smarthost preferable for a dynamic-IP Ubuntu server?
Many recipient systems block direct SMTP connections from dynamic addresses as spam protection. A remote smarthost provides the onward delivery path and handles its own delivery reputation and recipient-server communication.
The Tool Desk
Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →The Bottom Line
Install exim4, choose mail sent by smarthost; no local mail, enter the relay host and required ::port, configure authenticated TLS when needed, then run update-exim4.conf and restart Exim. Confirm delivery with the queue and Exim logs.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




