Solved

update system wide env

Posted on 2002-05-15
9
211 Views
Last Modified: 2013-12-15
here is my problem.
I need to update system wide Path, and some other enviroment variables.
I added the new enviroment variable to /etc/profile and csh.login
restarted system, and NOthing happend?
now if I add them to /etc/csh.cshrc and /etc/bashrc they work and users can see new application path and applications Are aware of their specific enviroment, but that is NOT where it is suppose to go.
what is wrong with /etc/profile and /etc/csh.login?
0
Comment
Question by:ragaMuffin
  • 4
  • 3
  • 2
9 Comments
 
LVL 2

Accepted Solution

by:
wqclatre earned 100 total points
Comment Utility
Check that you don't set a new path from scratch in your files in your homedir. ($HOME/.bashrc $HOME/.bash_profile $HOME/.login etc....)  
0
 

Author Comment

by:ragaMuffin
Comment Utility
I'm Not.
0
 
LVL 51

Expert Comment

by:ahoffmann
Comment Utility
> .. but that is NOT where it is suppose to go ..
PLease read man-pages, carefully. Then read them again, and again, ..

ash, ksh, pdksh, sh (and many more): /etc/profile
zsh: /etc/zshenv
csh, tcsh: /etc/csh.cshrc
bash: /etc/profile, or read man-page and ask the person who compiled and installed it

anything in $HOME (wherever this is), is useless for your purpose.
/etc/csh.login and /etc/bash_login are for special purpose (login shell only, usually).
/etc/bashrc depends on bash (compilation, version etc.)
0
 
LVL 51

Expert Comment

by:ahoffmann
Comment Utility
BTW, "restarted the system" you don't need that, it's UNIX ;-)
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:ragaMuffin
Comment Utility
wqclatre,
You get the points because what's his face attitude SUCKS
0
 
LVL 51

Expert Comment

by:ahoffmann
Comment Utility
ragaMuffin,
not shure if you mean me, respectively my comment, when you write "SUCKS".
But please explain why you graded a comment which is incorrect according your initial question: "update system wide Path".
Or did I missunderstand your question?
0
 
LVL 2

Expert Comment

by:wqclatre
Comment Utility
Why do you give me the points. I don't desever them so please some administrator take them away.
0
 

Author Comment

by:ragaMuffin
Comment Utility
You were too busy being sarcastic that “he who know passes the knowledge to those who don’t with humbleness “
NOW, I know how to read the man pages, but the problem is, Go take a look at /etc/profile and /etc/bashrc.  At top of BOTH files, you will see “System wide environment and startup programs functions and aliases go in “ and then each one will POINT to the other.
Now on Solaris, still UNIX, /etc/profile will tell you “ the profile that all logins get before using their own .profile”
On IRIX /etc/profile states “default settings for all sh users”
On SGI Indigo /etc/profile states “this script is executed before $HOME/.profile when an sh user logs in or invokes /bin/su/ with the ‘-‘ option.

So you can see my sarcastic Helper that I know what Unix is and Know what /etc/profiles does according to UNIX.  What I needed help with was Linux, because the same thing that works for UNIX did not work for Linux.

I don’t appreciate your sarcasm, and never will.  I gave points to the other individual and made the decision to research this issue on my own rather than depending or getting an answer from some arrogant person such as yourself.
I would really appreciate it if you NEVER try to help me again.  Any time you see me asking a question, just look the way, Mr. Unix.
0
 
LVL 51

Expert Comment

by:ahoffmann
Comment Utility
hmm, wasn't meant as an offence in either comment. Sorry.

So we look at your initial question, and the previous comment, then read my first suggestion, and you'll see that you didn't read the man-page but the files.
You probably didn't read carefully enough. That was my message. And I kindly please you to do, it's exactly as I described in my first comment for sh (AT&T sh, not bash, therfore see below).
This applies to any UNIX I've ever seen, even IRIX. If it doesn't, then they use a proprietary shell (like on HP-UX).
(ANd if it is not, please tell me: I'm interested)

bash is not sh, unfortunatelly.
And its behaviour, particular the behaviour when reading startup files, depends on the configuration at compile time too. That's the main reason why I recommended to read the man-page. bash may be strange here, and you may have to beat other people's dragons.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now