LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-13-2010, 03:24 PM   #1
twandungen
LQ Newbie
 
Registered: Feb 2010
Posts: 3

Rep: Reputation: 0
/etc/motd


Hi everyone,

Can anyone tell me how i can put an scipt into the motd file? For example if i want to know how many users are logged on while i log in.

Any ideas? Or is it just not possible?
 
Old 02-13-2010, 04:09 PM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
The motd file is a plain text file that the profile script cats to the user.

To have a script run when you log in, put it in a script named .bash_profile (assuming that you use bash as a shell) in your home directory, or for all users, add it to /etc/profile

Hope that helps,

—Robert J Lee
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
/etc/motd skate Linux - Software 5 05-03-2006 08:44 AM
motd toothe Linux - Newbie 2 11-08-2005 04:02 PM
motd iomari Linux - Software 5 04-03-2005 04:43 AM
motd Master Fox Linux - Software 2 08-25-2004 07:40 AM
Is there any MOTD software available besides /etc/motd? csif Linux - Software 1 04-24-2004 06:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:39 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration