Sponsored Content
Top Forums Shell Programming and Scripting Adding command line env in cron env Post 92488 by abhijeetkul on Monday 12th of December 2005 04:58:05 AM
Old 12-12-2005
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
 

10 More Discussions You Might Find Interesting

1. Solaris

Env

hey guys!!!! i have a few question .. how to modify the user ENV in Sun Solaris 10 ... Thanks!!!! (1 Reply)
Discussion started by: giancarlodjabon
1 Replies

2. Shell Programming and Scripting

env

Hi, I want to check the path set for a particular variable.Like when i use "env" command ,so many variables are there.I have to search for that variable which i need.Instead can i have any cmd which i can directly check the path set for that variable except "echo $path_name" Thanks, ... (3 Replies)
Discussion started by: rrs
3 Replies

3. AIX

CDE Env.

Hi I installed aix 5.2-09 on js21 but am unable to get cde environment through X manager soft. when i run ./rc.dt am able to get the same but this remains till next reboot. What should i do can anybody help me???? (4 Replies)
Discussion started by: vjm
4 Replies

4. HP-UX

How to use own account env variables to cron user

hi all, i have one account for unix Tru64. i can login this account and i do execute special shell script(login sqlplus, execute another shell, etc... ) on this account on my server. but i can't run this shell from cron tab. i think that become cron user envirnoment variables. (3 Replies)
Discussion started by: Tlg13team
3 Replies

5. Shell Programming and Scripting

HOME env

Do you know shell in Linux without HOME env ? Best regards, Iliyan Varshilov Edit/Delete Message (1 Reply)
Discussion started by: ilko_partizan
1 Replies

6. HP-UX

I want a HP-UX ENV,how could I?

just for practice,:) (1 Reply)
Discussion started by: freebsdjlu
1 Replies

7. Shell Programming and Scripting

env command

All, what is env command used for in Unix? Regards Oracle User (2 Replies)
Discussion started by: Oracle_User
2 Replies

8. Solaris

env variables again

What is the difference between ${variable} and $variable when used in a script? (2 Replies)
Discussion started by: orange47
2 Replies

9. 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

10. UNIX for Beginners Questions & Answers

How to use env command to change GREP_OPTIONS variable?

How could I use the env command to change the enviroment variable GREP_OPTIONS so that grep is not case sensitive by setting it to "-i'? So that the command: grep a <<< A Will produce the same output as grep -i a <<< A (8 Replies)
Discussion started by: steezuschrist96
8 Replies
env(1)								   User Commands							    env(1)

NAME
env - set environment for command invocation SYNOPSIS
/usr/bin/env [-i | -] [name=value]... [utility [arg... ]] /usr/xpg4/bin/env [-i | -] [name=value]... [utility [arg... ]] DESCRIPTION
The env utility obtains the current environment, modifies it according to its arguments, then invokes the utility named by the utility op- erand with the modified environment. Optional arguments are passed to utility. If no utility operand is specified, the resulting environment is written to the standard output, with one name=value pair per line. /usr/bin If env executes commands with arguments, it uses the default shell /usr/bin/sh (see sh(1)). /usr/xpg4/bin If env executes commands with arguments, it uses /usr/xpg4/bin/sh (see ksh(1)). OPTIONS
The following options are supported: -i | - Ignores the environment that would otherwise be inherited from the current shell. Restricts the environment for utility to that specified by the arguments. OPERANDS
The following operands are supported: name=value Arguments of the form name=value modify the execution environment, and are placed into the inherited environment before utility is invoked. utility The name of the utility to be invoked. If utility names any of the special shell built-in utilities, the results are unde- fined. arg A string to pass as an argument for the invoked utility. EXAMPLES
Example 1 Invoking utilities with new PATH values The following utility: example% env -i PATH=/mybin mygrep xyz myfile invokes the utility mygrep with a new PATH value as the only entry in its environment. In this case, PATH is used to locate mygrep, which then must reside in /mybin. ENVIRONMENT VARIABLES
See environ(5) for descriptions of the following environment variables that affect the execution of env: LANG, LC_ALL, LC_CTYPE, LC_MES- SAGES, and NLSPATH. PATH Determine the location of the utility. If PATH is specified as a name=value operand to env, the value given shall be used in the search for utility. EXIT STATUS
If utility is invoked, the exit status of env is the exit status of utility. Otherwise, the env utility returns one of the following exit values: 0 Successful completion. 1-125 An error occurred. 126 utility was found but could not be invoked. 127 utility could not be found. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: /usr/bin +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ |CSI |enabled | +-----------------------------+-----------------------------+ /usr/xpg4/bin +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWxcu4 | +-----------------------------+-----------------------------+ |CSI |enabled | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ SEE ALSO
ksh(1), sh(1), exec(2), profile(4), attributes(5), environ(5), standards(5) SunOS 5.11 2 Jan 2002 env(1)
All times are GMT -4. The time now is 08:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy