Operating System - Linux
1826657 Members
2408 Online
109695 Solutions
New Discussion

/etc/motd appears twice during ssh login

 
Mickey Wilson
Advisor

/etc/motd appears twice during ssh login

This is a debian 2.4 kernel box that my friends and I use for ftping school projects around. When anyone logs into the machine via SSH, the motd appears like so:

[Message of the day]
You have mail.
Last login: Mon Jan 6 20:34:06 2003 from 10.0.0.50
[Message of the day]

I checked /etc/ssh/sshd_config and PrintMotd is set to no and commented out. Also, I check /etc/profile, and there's nothing in there that would cause it to print twice. I'm not sure where to go from here.

I appreciate any help you can offer.
4 REPLIES 4
Mark Fenton
Esteemed Contributor

Re: /etc/motd appears twice during ssh login

uncomment the entry and restart sshd.

By default, sshd will display the motd, unless told not to.
Mickey Wilson
Advisor

Re: /etc/motd appears twice during ssh login

I uncommented the entry, with no result. Good to know, though.
Robert Thorneycroft
Valued Contributor

Re: /etc/motd appears twice during ssh login

Did you restart after following above advice. You need to restart sshd after you make any change for the change to take effect.

Kind regards,

Robert Thorneycroft
Mickey Wilson
Advisor

Re: /etc/motd appears twice during ssh login

Worked. Thank you much.