Linux Format forums Forum Index Linux Format forums
Help, discussion, magazine feedback and more
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

SOLVED how to display sysinfo at login?

 
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help!
View previous topic :: View next topic  
Author Message
purplepenguin
LXF regular


Joined: Wed Oct 05, 2011 3:19 pm
Posts: 121
Location: Blissfully at the Command Line

PostPosted: Sun Apr 21, 2013 6:23 pm    Post subject: SOLVED how to display sysinfo at login? Reply with quote

Hi all

I have a Ubuntu 12.04 server. which I logon to via ssh over my LAN.

I'm pretty sure the server used to display a message upon logon Along the lines of:

Welcome to Ubuntu, Ubuntu comes with absolutely no warranty. Then gave details about system load, Users who were logged on, IP address and any waiting updates amongst others.

Looking around on the web it seems this info is provided by landscape. I have landscape installed and can get the message if I type
Code:
/usr/bin/landscape-sysinfo
Albeit without the Welcome to Ubuntu and warranty bit.

How can I get this info automatically after a ssh login?

Many thanks
PP
_________________
Debian Testing 64bit KDE i5 CPU 8GB RAM

Firefox 29 wont let me move the Reload and Back buttons. It's my computer Mozilla not yours.


Last edited by purplepenguin on Mon Apr 22, 2013 12:41 pm; edited 1 time in total
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8439
Location: Warrington, UK

PostPosted: Sun Apr 21, 2013 7:15 pm    Post subject: Reply with quote

Put the commands you want executed in ~/.bash_profile (not ~/.bashrc).
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Rhakios
Moderator


Joined: Thu Apr 07, 2005 12:18 am
Posts: 7619
Location: Midlands, UK

PostPosted: Sun Apr 21, 2013 9:39 pm    Post subject: Reply with quote

Which raises the question of why it runs automagically normally. I don't have a .bash_profile in my server's user home (there is a .profile, but it just refers to /etc/profile), it's not in the .bashrc either. I've also had a look in /etc/bashrc, /etc/profile and the files in /etc/profile.d, nothing there either. Confused
_________________
Bye, Rhakios
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8439
Location: Warrington, UK

PostPosted: Sun Apr 21, 2013 10:40 pm    Post subject: Reply with quote

I was only answering how to make it appear, not how to stop it Razz
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
purplepenguin
LXF regular


Joined: Wed Oct 05, 2011 3:19 pm
Posts: 121
Location: Blissfully at the Command Line

PostPosted: Mon Apr 22, 2013 12:40 pm    Post subject: Reply with quote

nelz wrote:
Put the commands you want executed in ~/.bash_profile (not ~/.bashrc).


God blimey Nelz. Your knowledge never fails to amaze.

I didn't have a .bash_profile file. Instead I have a .profile file. So I added the command to the end of it, and Woo Hoo it worked.

Thank you to the Godfather of Linux Laughing

Edit*

I added the command to /etc/profile and now it works for all users.
_________________
Debian Testing 64bit KDE i5 CPU 8GB RAM

Firefox 29 wont let me move the Reload and Back buttons. It's my computer Mozilla not yours.
Back to top
View user's profile Send private message
Rhakios
Moderator


Joined: Thu Apr 07, 2005 12:18 am
Posts: 7619
Location: Midlands, UK

PostPosted: Mon Apr 22, 2013 7:01 pm    Post subject: Reply with quote

nelz wrote:
I was only answering how to make it appear, not how to stop it Razz


Aha! So you don't know then. Razz
_________________
Bye, Rhakios
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8439
Location: Warrington, UK

PostPosted: Mon Apr 22, 2013 10:49 pm    Post subject: Reply with quote

I'm saving that reply for... when I know the answer Wink

Life is so much simpler with KDE and Konsole Razz
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help! All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Linux Format forums topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group


Copyright 2011 Future Publishing, all rights reserved.


Web hosting by UKFast