PC 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 & 11Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteLinux does not have one universal MOTD file. After a successful login, the PAM pam_motd module may print static files, generated fragments, or both. On Ubuntu and Debian, the usual source is the update-motd framework: executable scripts in /etc/update-motd.d are run at login and their output is assembled into /run/motd.dynamic. On systems using a static configuration, edit /etc/motd instead.
Antihost offers Linux VPS plans with full root access, unlimited traffic on a 1 Gbps port and a 14-day free trial.
The reliable way to customize the message is therefore to identify which PAM files and login service are active, then choose a static file, a generated script, or a local motd.d override. The procedures below also explain why an edit may appear on a console but not through SSH, how to disable one vendor-supplied line, and how to avoid slowing every login or exposing sensitive information.
As an Amazon Associate I earn from qualifying purchases.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →How Linux decides what to display
The MOTD is normally displayed by the PAM session module pam_motd.so after authentication succeeds. PAM can be invoked by a local console login, an SSH session, a display manager, or another service, so the visible message depends on that service’s PAM policy.
In the documented pam_motd arrangement, the module examines message files and directories such as /etc/motd, /run/motd, /usr/lib/motd, and their corresponding motd.d directories. Entries are printed in lexicographic order. A file in /etc takes precedence over a same-named file in /run or /usr/lib, which lets administrators replace or suppress packaged content without editing vendor files.
#1 Best Overall
- BLUE LIGHT BLOCKING GLASSES: Our blue light glasses for women boast UV400 protection, blocking harmful blue rays from computer screens. With these bluelight glasses women, you can enjoy gaming, reading, or watching TV with no worries of eye strain.
- EYE RELIEF: Our blue light glasses are engineered to reduce blurry vision or strain caused by prolonged screen time. These womens blue light glasses aid in better sleep by preventing blue light from disrupting your natural sleep cycle, helping you fall asleep faster and enjoy a more restful night's sleep, making them the perfect christmas present.
- COMFORTABLE: Crafted from durable material, our trendy blue light glasses for woman or blue light glasses men ensure long-lasting comfort. The high-transmittance lenses accessories, gamer gifts for men, help keep your eyes relaxed. Perfect stocking stuffers, gifts for gamers men, christmas gifts for men, halloween costumes.
- LIGHTWEIGHT: These clear blue light glasses feature a lightweight frame, meaning they’ll stay comfy for long-term wear. Perfect as blue blockers glasses for women or mens blue light glasses, these non-prescription fake glasses for men can be worn throughout the day. The blue light blocking glasses women feature polycarbonate HD lenses, which are anti-reflective and restore true color.
- WORRY-FREE PURCHASE: If you experience any issues, our support team is ready to assist you quickly. These are the perfect costume glasses for cosplay dressing up.
Each individual message is limited to 64 KB according to the current Ubuntu Manpages documentation for pam_motd. That limit applies to a message file or fragment, not to an unlimited stream of diagnostic output. Keep generated output short enough to remain useful at a login prompt.
Static, generated, and fragment-based sources
| Approach | Typical location | When it is read | Best use | Main caution |
|---|---|---|---|---|
| Static file | /etc/motd |
When the active PAM setup reads it directly | A fixed notice such as an authorization or maintenance message | On generated Ubuntu systems it may be a symlink or may be bypassed |
| Ubuntu/Debian dynamic scripts | /etc/update-motd.d/ |
Scripts run as root at login | Hostname, kernel, update, storage, or other changing status | Slow or unreliable commands delay every login |
| MOTD fragments | /etc/motd.d/, /run/motd.d/, /usr/lib/motd.d/ |
Fragments are read in sorted order | Local additions and per-message overrides | Names and precedence determine the result |
Identify the active MOTD mechanism first
Do not overwrite a file blindly. A quick inspection shows whether your host uses a generated message and whether the relevant PAM service invokes pam_motd.
- Check the main files and directories:
ls -l /etc/motd /run/motd /usr/lib/motd 2>/dev/null
ls -ld /etc/motd.d /run/motd.d /usr/lib/motd.d /etc/update-motd.d 2>/dev/null
If /etc/motd points to /run/motd.dynamic, the visible text is generated rather than maintained as a hand-edited file.
- Inspect the PAM policies for the login paths you care about:
grep -R --line-number 'pam_motd' /etc/pam.d/login /etc/pam.d/sshd 2>/dev/null
A line such as session optional pam_motd.so indicates that PAM will attempt to print the MOTD for that service. The exact options and included files matter, so read the surrounding lines rather than changing a single match in isolation.
- For SSH, inspect the daemon configuration as well:
sshd -T | grep -i '^printmotd'
If your distribution does not permit that command as an unprivileged user, run it with the required administrative privileges. The effective setting may come from an included configuration file, not only from the top-level sshd_config.
Rank #2
- WINDEX GAMING WIPES: effortlessly clean all your gaming gear and gaming electronics in one easy step with our new Windex Gaming Wipes
- AMMONIA FREE: our ammonia-free formula is safe to use on all of your favorite gaming equipment like consoles, headsets, controllers, screens, keyboards, and more
- PRE-MOISTENED WIPES: each wipe instantly removes dust, dirt, and stubborn smudges and fingerprints leaving a streak-free shine
- ANTI-STATIC: great for cleaning and wiping down your gaming gear and electronics leaving behind no visible residue
- COMPACT RESEALABLE PACKAGE: store your pack of Windex Gaming Wipes anywhere in your home for whenever a quick and easy wipedown is needed
Set a fixed message in /etc/motd
Use a static file when the message should be identical at every login and your PAM configuration reads /etc/motd directly.
- Create or replace the file with administrative privileges. This example writes two lines and ends the file with a newline:
sudo sh -c 'cat > /etc/motd <<"EOF"
Authorized users only.
Maintenance window: Sundays 02:00 UTC.
EOF'
- Log out and start a new session, or invoke the same login path again. A shell that was already open will not normally redraw the MOTD.
- If nothing changes, check whether
/etc/motdis a symlink, whether a generated file is being displayed, and whether the relevant PAM stack containspam_motd.so.
Do not treat a successful write as proof that this is the active source. Ubuntu installations commonly make /etc/motd a link to generated output; a later login can regenerate that target and replace text you typed manually. In that case, move the customization to an update-motd.d script or an appropriate motd.d fragment.
Create a dynamic MOTD on Ubuntu or Debian
Ubuntu introduced the update-motd framework, in which a collection of scripts dynamically assembles the MOTD at login. Executable files in /etc/update-motd.d run as root, and their standard output is concatenated into /run/motd.dynamic. The framework is a Debian/Ubuntu-specific patch and is not guaranteed to exist on other Linux distributions.
Add a custom fragment
Create a file with a numeric prefix, no filename extension, executable permissions, and a final newline. A prefix in the 90 range usually places local information after lower-numbered distribution scripts:
sudo tee /etc/update-motd.d/90-custom >/dev/null <<'EOF'
#!/bin/sh
echo
echo "Welcome to $(hostname)"
echo "Kernel: $(uname -r)"
EOF
sudo chmod 755 /etc/update-motd.d/90-custom
The script must write the intended message to standard output. Avoid writing status text to standard error unless you deliberately want diagnostics to appear elsewhere. Keep the script deterministic and quick; it runs for every login that triggers generation.
Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errorsRank #3
- Ergonomic & Adjustable Design: Fight "text neck" and improve your posture. Designed for comfort, it offers an adjustable height (7.1in-8.5in) (1.4in adjustable range) and angle (5°-85°) Please note: cell phone stand is only 9 inches tall—the length of a standard pencil
- Without blocking subtitles Perfect for office desk Tiktok Face Time Zoom video—this is the ultimate kitchen desk essential for phones! Perfect viewing experience while reducing neck back strain, A must-have for gamers streamers desk, and anyone who values both style and support!
- Sleek & Stable Design fits Otterbox Case: Say goodbye to bent cables, tangles, and tip-overs! LISEN’s stylish adjustable desk phone holder features a built-in charging hole and smart cable management, keeping your phone secure and your workspace clutter-free cool gadgets for men
- ANTI-SLIP DESIGN free hands: The under 10.00 items easy gadgets back and the bottom of this kitchen essentials for women are fully covered by anti-skid silicone, which LISEN stand up desk decor can provide maximum protection device from any scratches and slides
- Your Perfect Viewing Companion:If your product arrives damaged or breaks within 365 days, reach out to LISEN for a quick and hassle-free solution. Struggling with assembly, like tightening the screw? We’ve got your back! Your experience matters to us. (Product including: phone Holder stand*1, screw*1, hexagon screwdriver*1, specification*1)
Preview the generated output
Where the framework is installed, run the same run-parts mode used by the update scripts:
sudo run-parts --lsbsysinit /etc/update-motd.d
This prints the combined output without requiring a new SSH connection. It also exposes filename mistakes, permission problems, and commands that fail when run as root.
Rules that determine whether a script runs
- Use a name such as
90-custom; omit extensions such as.sh. - Make the file executable. A non-executable file is skipped.
- Follow the filename rules used by
run-parts --lsbsysinit; unusual punctuation can cause a file to be ignored. - Write a newline-terminated result so the next fragment does not run into the last line.
- Use absolute paths for commands whose environment may differ from an interactive shell.
Control ordering and override packaged fragments
Dynamic scripts are run in numeric and then alphabetical order under the run-parts --lsbsysinit rules. A file named 10-system therefore appears before 90-custom. Within the fragment-based motd.d mechanism, files are likewise displayed in lexicographic order, with the /etc tree taking precedence over same-named entries in lower-precedence trees.
Use /etc/motd.d for a local fragment when your system reads that directory directly. This avoids modifying files owned by packages and makes the ownership of your message clear.
Silence one specific line
To suppress a packaged fragment without deleting it, create a same-named symbolic link in /etc/motd.d that points to /dev/null. For example:
Rank #4
- Easy Installation: Our gaming lights have been designed to enhance your entertainment experience. Simply position the led light bar next to your TV or game console to create a game room environment with ease. They come with USB power and a 60 inch cord for direct mounting and mobility
- Audio Syncing & Extensive Mode: The built-in high-sensitivity music sensor allows you to sync the TV led lights to your favorite music. Lights react and move to the beat of music, film and game audio, creating an incredible immersive sound and light experience – and all without the need for an additional hub. You can choose from 64+ patterns, including strobe, illusion, jump, energy, gradient, running, chasing, fluttering mode etc. Each mode can be applied to different scenes
- 64+ Chasing IC+RGB & W Effect: The independent control design of IC+RGB and white all-in-one multifunctional rgbw led bar lights monitor backlight allows you to easily switch the led lights for desk between IC+RGB and white to enjoy a variety of lighting effects, you can choose white lighting mode with high brightness for better illumination when working, etc. Choose IC+RGB lighting mode when you need to create an entertaining atmosphere for the light show, 16 million colours of Color changing rgb light bar let you dance to the beat and create a dynamic party atmosphere
- Dynamic and Dimmable Lights: 1%-full brightness free brightness adjustment gives you the flexibility to adjust dimmable led light bar for room decorations or a variety of occasions
- USB Powered: USB light bars for room can be powered by powernank, usb charger, TV, Monitor, laptop PC mainframe, making behind TV led lighting bar easy to install in any location.TV led lights are powered by the TV usb interface / PC mainframe, can be turned on/off synchronously with TV / PC
sudo ln -s /dev/null /etc/motd.d/50-motd-news
The name must exactly match the lower-precedence fragment you want to mask. The /etc entry wins during precedence resolution, while the package’s original file remains available for upgrades or later restoration. Verify the actual filename first with:
find /usr/lib/motd.d /run/motd.d -maxdepth 1 -type f -printf '%fn' 2>/dev/null | sort
If the file is generated by update-motd rather than read from a motd.d directory, this symlink will not disable it; disable or adjust the corresponding numbered script instead.
Make the change appear over SSH
SSH output can be controlled by two separate layers. Debian documentation describes an sshd option named PrintMotd, while the PAM stack determines whether pam_motd.so runs for the session. A console login and an SSH login can therefore show different messages even on the same machine.
Diagnose a console/SSH mismatch
- Compare the effective SSH setting:
sshd -T | grep -i '^printmotd'
- Check
/etc/pam.d/sshdfor apam_motd.sosession line and inspect any included files. - Check
/etc/pam.d/loginseparately for local virtual-console behavior. - Open a fresh SSH session after each change; existing sessions do not replay the banner.
If PrintMotd is disabled, enabling PAM alone may not produce the result you expect, and changing PrintMotd alone cannot help if the SSH PAM stack never invokes pam_motd.so. Change only the layer responsible for the path you intend to affect, then validate the daemon configuration before reloading it.
Understand distribution boundaries
The /etc/update-motd.d convention is not an upstream Linux standard. The Debian MOTD documentation describes it as a Debian- and Ubuntu-specific patch that may be absent from other GNU/Linux distributions. Other systems may use only /etc/motd, the motd.d directories, vendor login tooling, or a different PAM arrangement.
Best Value
- Compatible with Wide Screens - To ensure compatibility with the dual monitor mount, your each monitor must meet three conditions at the same time: First, computer screens size range: 13 to 32 inches. Second, screen weight range: 4.4 to 19.8 lbs. Third, the back of the monitor screen must have VESA mounting holes with a pitch of 75x75mm or 100x100mm.
- Regarding the compatibility with desks - Your desk must meet three conditions at the same time: First, desk material: Only wooden desks are recommended, plastic or glass desks cannot be used. Second, desk thickness range: 0.59" - 3.54". Third, the bottom of the desk should not have any cross beams or panels, as this will interfere with installation. We recommend carefully checking that your desk and monitors meets all above conditions before purchasing.
- Dual C-Clamp Hold - Worried your dual monitors might wobble or slip? Our upgraded base uses a larger platform plus a dual C-clamp structure to lock the dual monitor arm firmly to your desk. Each arm safely keeps your screens steady while you type, click and game—no shaking, no sliding, just a clean and secure setup you can trust every day. It also provides Grommet Mounting installation choice, both options ensure stable and secure fixation for your 0.59" - 3.54" desk.
- Full-Motion Adjustment For Comfortable View - Pull the screen closer when you’re deep in a spreadsheet, push it back to watch videos, or rotate to portrait for coding — moving everything smoothly with just one hand. The monitor stand offers +85°/-50° tilt, ±90° swivel and 360° rotation. Raise your monitor up to 15.75″ to support a healthy sitting posture. Whether you’re working from home, gaming through the night, or switching between video calls and documents, getting the screens to your natural line of sight helps relieve neck, shoulder and back strain so you can stay focused longer with less fatigue.
- Keep Your Desk Organized: By lifting both screens off the desktop, this dual monitor stand opens up valuable space for your keyboard, notebook, docking station or a simple, clutter-free work area. Built-in cable management guides wires along the arms, keeping cords out of sight and out of the way. Enjoy a tidy, modern workstation that looks as good as it feels to use.
On an unfamiliar distribution, start with the PAM files for the actual login service and list the available MOTD paths. Do not create /etc/update-motd.d and assume it will be called automatically. If no PAM rule references pam_motd.so, the login program may be displaying a banner through another mechanism, or no MOTD may be configured at all.
Keep MOTD scripts safe and fast
Protect sensitive information
MOTD text is shown to every account that can log in through the affected service. Avoid putting secrets, access tokens, private hostnames, internal IP ranges, unpatched-service details, or command output that ordinary users should not see. Treat kernel versions, package status, mounted filesystems, and uptime as operational information that may still reveal useful details to an attacker.
Recommended Free Tools
Prevent login delays
Every command in an update-motd.d script runs in the login path. Network probes, package-manager queries, DNS lookups, and large disk scans can make an otherwise healthy server feel hung. The Ubuntu update-motd manual recommends caching long-running or network-dependent work rather than performing it synchronously for each login.
Prefer local, bounded commands such as hostname and uname -r. If you need a health check, have a separate timer or service refresh a small cache file and let the MOTD script read that file with a short timeout and a sensible fallback.
Handle failures quietly
Use shell checks for missing commands and unavailable files. A failed optional check should produce a short fallback or no line, not a stack trace. Test scripts as root with the same interpreter named in the shebang, because permissions, environment variables, and working directories differ from an interactive shell.
Quick Recap
Troubleshooting by symptom
Editing /etc/motd has no effect
- Check whether
/etc/motdis a symlink to/run/motd.dynamic. - Look for
/etc/update-motd.dand preview it withrun-parts --lsbsysinit. - Verify that the login service’s PAM file includes
pam_motd.so. - Confirm that you are testing a new login rather than an existing shell.
The custom Ubuntu script is ignored
- Ensure the file is executable:
sudo chmod 755 /etc/update-motd.d/90-custom. - Remove the extension and unsupported punctuation from its filename.
- Check the shebang and run it directly as root to expose syntax or command errors.
- Run
sudo run-parts --lsbsysinit /etc/update-motd.dand inspect whether its output appears.
Only one vendor line must be removed
- For a
motd.dfragment, create a same-named/etc/motd.dsymlink to/dev/null. - For an
update-motd.dscript, disable or edit that numbered script instead. - Do not delete package-managed files when a precedence override can solve the problem.
The message appears locally but not over SSH
- Check the effective
PrintMotdvalue fromsshd -T. - Inspect
/etc/pam.d/sshdindependently of/etc/pam.d/login. - Check for another SSH banner configured with the
Bannerdirective; it is a separate mechanism from the post-authentication MOTD. - Reconnect after applying a configuration change.
The login is slow after customization
- Run each custom script manually and time commands that contact the network or scan the filesystem.
- Move expensive work to a scheduled job and have the MOTD read cached results.
- Add timeouts and fallbacks so a failed service cannot block authentication feedback.
A repeatable change-and-verify procedure
- Identify the login path: local console, SSH, display manager, or another service.
- Inspect that service’s PAM configuration for
pam_motd.so. - Determine whether the source is static,
motd.d, or Ubuntu/Debianupdate-motd. - Choose a local file or fragment rather than editing package-owned content.
- Use a clear numeric name, executable mode, standard output, and a final newline for dynamic scripts.
- Preview generated output with
run-parts --lsbsysinitwhen available. - Open a fresh session through the intended service and verify ordering, visibility, and timing.
- Record any suppression symlinks or local scripts so future administrators know why a packaged line is absent.
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.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.

