LinuxQuestions.org
Review your favorite Linux distribution.
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 11-01-2011, 11:26 PM   #1
Pir Ovais
LQ Newbie
 
Registered: Aug 2011
Posts: 12

Rep: Reputation: Disabled
Thumbs up Executing a script at startup


Hi all,

i am a newbie to linux.
I want to execute a shell script each time when any user logs in to system?

Thanks in advance.
 
Old 11-02-2011, 12:15 AM   #2
fukawi1
Member
 
Registered: Apr 2009
Location: Melbourne
Distribution: Fedora & CentOS
Posts: 854

Rep: Reputation: 193Reputation: 193
Have you tried a google search? or a forum search?

Heres a hint, bashrc...
 
Old 11-02-2011, 12:51 AM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 7.7 (?), Centos 8.1
Posts: 18,166

Rep: Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680
If its customisable by the user, try .bash_profile or .bashrc in their home dir.
If its not allowed to be touched by them, try /etc/profile
 
1 members found this post helpful.
Old 11-02-2011, 03:23 AM   #4
Pir Ovais
LQ Newbie
 
Registered: Aug 2011
Posts: 12

Original Poster
Rep: Reputation: Disabled
Thanks Cris.
It worked perfectly for me.

Stay Blessed.
Thanks
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
executing startup script on shared server (not as root!) agentspanky Linux - Newbie 3 02-11-2008 01:42 AM
Link in rc5.d is not executing -- is there a startup log? dcroxton Linux - General 2 01-28-2007 09:08 PM
Auto-executing soundcard commands at startup VA3OG Ubuntu 1 11-06-2005 12:25 PM
executing on startup moschi Linux - General 7 09-06-2004 12:49 PM
Executing commands on startup viciousfish Linux - General 5 06-28-2002 02:15 PM

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

All times are GMT -5. The time now is 11:12 PM.

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