Jump to content

Recommended Posts

Posted

Hi, 

 

tried to find files for motd but /etc/motd is empty.

Can you tell me where to configure motd?

 

Thanks

Posted

MOTD is generated within /etc/initd.d/armhwinfo while information bar below is generated within /etc/bash.bashrc.custom

Posted

MOTD is generated within /etc/initd.d/armhwinfo while information bar below is generated within /etc/bash.bashrc.custom

 

I have associated question: while I login through SSH on OrangePi with Jessie onboard armhwinfo script is executed flawlessly.

 

However, while login localy, directly to the machine, I am gettin "last login" message, then "Linux orangepi 3.4.108-orangepi #16 SMP PREMPT (...)" line and then the loand&temps line.

 

It seems that locally the toilet banner is substituted with kernel info line. I've read that in Jessie ssh and local motds are separated. How can we change the local then?

 

Thanks.

Posted

Realise this is an old thread - but as it was one of the first results in Google for this topic, I thought I'd update it with my (rather blunt) solution.

 

1) The script that produces the hardware info is located in /etc/update-motd.d - and is named "30-sysinfo".  Remove it (and if you like, the other scripts in there).  

 

2) Edit /etc/pam.d/login and /etc/pam.d/ssh - comment out the line that reads "session    optional   pam_motd.so motd=/run/motd.dynamic"

 

Result:  Editing /etc/motd now does the right thing - and my system no longer hangs for 30 seconds upon login simply to produce a colour ASCII art banner that tells me what CPU I'm running and what IP I'm logging in from.  

Posted

Result:  Editing /etc/motd now does the right thing - and my system no longer hangs for 30 seconds upon login simply to produce a colour ASCII art banner that tells me what CPU I'm running and what IP I'm logging in from.  

 

None of mentioned thing eats much time., login takes around 1-2 seconds on an fully booted system. Measured on old A20 board ... (only) when system still loads, this can takes 10s or more.

Posted

Realise this is an old thread - but as it was one of the first results in Google for this topic, I thought I'd update it with my (rather blunt) solution.

 

1) The script that produces the hardware info is located in /etc/update-motd.d - and is named "30-sysinfo".  Remove it (and if you like, the other scripts in there).  

 

2) Edit /etc/pam.d/login and /etc/pam.d/ssh - comment out the line that reads "session    optional   pam_motd.so motd=/run/motd.dynamic"

 

Result:  Editing /etc/motd now does the right thing - and my system no longer hangs for 30 seconds upon login simply to produce a colour ASCII art banner that tells me what CPU I'm running and what IP I'm logging in from.  

Alternatively, you can do chmod -x 30-sysinfo or any other script you want to disable. The effect is the same as removing but you keep the file in case you want it in the future

Posted

And waiting / hanging for 30s awfully smells like waiting for DNS to resolve something

and running into a timeout. This does not happen here, please check.

 

gnasch

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines