You are not logged in.

#1 2018-09-16 16:41:55

carbolymer
Member
Registered: 2012-04-25
Posts: 42

Dynamic MOTD update on login

I've found in Ubuntu manual: http://manpages.ubuntu.com/manpages/bio … otd.5.html that files in

/etc/update-motd.d/

are executed by pam_motd on login. I assume that the same pam_motd is used in Arch, but in my case the files in the update-motd.d are not executed. Any ideas why? How to execute shell scripts to generate MOTD on each login?

Offline

#2 2018-09-16 16:48:49

loqs
Member
Registered: 2014-03-06
Posts: 17,309

Re: Dynamic MOTD update on login

carbolymer wrote:

I assume that the same pam_motd is used in Arch, but in my case the files in the update-motd.d are not executed.

see man 8 pam_motd

Offline

#3 2018-09-16 18:50:41

carbolymer
Member
Registered: 2012-04-25
Posts: 42

Re: Dynamic MOTD update on login

I've seen it. It basically says that pam_motd is only capable of displaying files - not executing scripts. So, is ubuntu using different pam_motd, or what is happening here?

Offline

#4 2018-09-16 18:58:50

loqs
Member
Registered: 2014-03-06
Posts: 17,309

Re: Dynamic MOTD update on login

Offline

#5 2018-10-17 16:23:44

carbolymer
Member
Registered: 2012-04-25
Posts: 42

Re: Dynamic MOTD update on login

Turns out ubuntu uses patched motd: https://wiki.debian.org/motd#How_to_scr … etc.2Fmotd and upstream PAM does not contain the patch with the dynamic motd. I will stick to the motd updated by cron job.

Offline

Board footer

Powered by FluxBB