Identify env file called


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Identify env file called
# 1  
Old 07-10-2010
Identify env file called

Hi,

please help me.. in how to find out which env file is being called upon when an os user logs.

when i su - oracle , i would like to know which env is called, because i see many env files under the home dir..

thanks,
# 2  
Old 07-10-2010
Hi jjoy,

It's not clear what you are asking.

What does env mean? I'm sure you don't mean /bin/env.

Do you mean a script file? If so, the name of the current script is in $0 (that's a zero).
# 3  
Old 07-11-2010
when you su - oracle, it will call ".profile" or ".cshrc", ".kshrc", ".bashrc" etc depending on which shell you are using.

so do a 'ls -a' and then open the startup script and find out which env.sh script is being run

probably something like ". ./oracleenv.sh"
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Env file path

Hi, when I run "env" there are few variable prinitng related to application $env SRV=test NVV=test2 from where this file is invoking, I checked in ./bash_profile and ./profile didn't find the variable. So what is the file I need to edit this variable. (8 Replies)
Discussion started by: stew
8 Replies

2. Web Development

Deny from env=env-variable Does not work

(Above from Apache docs). On my system, using: SetEnvIf User-Agent Mozilla IsBad=1 Order allow,deny Allow from all Deny from env=IsBad ...I see that environment variable is set (using phpinfo()) but the page is still served. No errors in the Apache logs. (1 Reply)
Discussion started by: gnurob
1 Replies

3. Shell Programming and Scripting

Add env variable in a file

Hi, I have a small requirement set -x `grep IMPACT_HOME=/opt/impact /opt/NETCOOLINST/r.txt | cut -d'=' -f2` if ; then sed 's#IMPACT_HOME=*#d' /opt/NETCOOLINST/r.txt echo "IMPACT_HOME=" >> /opt/NETCOOLINST/r.txt sed 's#IMPACT_HOME=*#IMPACT_HOME=/opt/impact#g' /opt/NETCOOLINST/r.txt... (2 Replies)
Discussion started by: dbashyam
2 Replies

4. UNIX for Dummies Questions & Answers

create a file called -a

Can I create a file called '-a' in unix.Or can i open it with vi ? vi \-a will give u an error that -a is invalid option for vi. (2 Replies)
Discussion started by: Swayam
2 Replies

5. UNIX for Dummies Questions & Answers

Get file from window env

Hi, I can use rcp to copy a file from unix to window. How can I get a file from window env in unix. Ivan (1 Reply)
Discussion started by: egckhad
1 Replies

6. Shell Programming and Scripting

Remove a file called -r using rm

Is there any way to remove a file named "-r" using "rm", because "rm" assumes that file is one of it's options if I type "rm -r" and then throws an error message? I also tried "rm -r -r" and that didn't work either. (3 Replies)
Discussion started by: dkieran
3 Replies

7. UNIX for Advanced & Expert Users

How to edit env file

A coworker of mine wants to add some environment variables to env file. Please advise how to do it. He couldn't use: more or vi on the file. Thanks. (3 Replies)
Discussion started by: duke0001
3 Replies

8. Shell Programming and Scripting

Adding command line env in cron env

Hello friends, i run two scripts manually & they work. i run them in cron & they don work. how to match the two env's 1.command line env 2.cron env i would like cron to use command line env. Thanks & Regards Abhijeet (1 Reply)
Discussion started by: abhijeetkul
1 Replies

9. Programming

File Opening in C++ in Unix Env

Pls someone help me. This piece of code is giving me weird results. ofstream outfile; ofstream out; char filename1; char filename2; memset(filename1,'\0',sizeof(filename1)); memset(filename2,'\0',sizeof(filename2)); strcpy(filename1,"Testing1.out");... (0 Replies)
Discussion started by: skannan
0 Replies

10. UNIX for Dummies Questions & Answers

env file

hi all, My newbie question is: where is the "env" file? I can define some settings via .profile (with Korn Shell). However, where is the env file that specifies the default PATH, LANG, DISPLAY, TZ... etc? I am using SPARC/ Solaris 8. Thanks in advance. (4 Replies)
Discussion started by: andrec
4 Replies
Login or Register to Ask a Question