Sponsored Content
Full Discussion: What user runs cron?
Top Forums UNIX for Dummies Questions & Answers What user runs cron? Post 21999 by michieka on Sunday 26th of May 2002 01:29:04 AM
Old 05-26-2002
Does .forward send all...

Does .forward send all the mail if you put it in /etc/sendmail. I thought there was something I could put in the script itself (that is to be run by cron) that would send only THAT particular output, not all of it. Maybe I was wrong.
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Old cron entry still runs, but shouldnt

Hello, I'm running OSF1 V4.0 alpha. We used to have a job running from the cron at 6am everyday. We have removed the job from the crontab file, but the job still runs at 6am everyday. The job was in the root's crontab file. I cant figure out why this job is still running after we removed it... (3 Replies)
Discussion started by: xadamz23
3 Replies

2. Solaris

SFTP errorcode 1 when run on cron but runs manually

I am trying to run a sript on cron to SFTP data to a company. Private and public keys are set up. When I run this manully it works fine, however it was failing when run on cron. I have narrowed down the problem - it fails at the code that says if the error code is 0 then continue . . . I... (2 Replies)
Discussion started by: Heidi.Ebbs
2 Replies

3. Shell Programming and Scripting

Script runs fine, but not in a cron

Okay, I have the following script that runs fine from a command line as well as an executable .sh file. It just moves any file/folder with movie* in the name to a folder called _Movies. The issue I'm running into is when it's call from a cron. find /mnt/HD_a2/BT/complete -iname "movie.*" -exec... (4 Replies)
Discussion started by: sammyk
4 Replies

4. Shell Programming and Scripting

CRON shell script only runs correctly on command line

Hi, I'm new to these forums, and I'm hoping that someone can solve this problem... To make things short: I have DD-wrt set up on a router. I'm trying to run a script in CRON that fetches the daily password from my database using SSH. CRON is set like so(in web interface): * * * *... (4 Replies)
Discussion started by: louieaw
4 Replies

5. Shell Programming and Scripting

Shell Script runs good manually but not through Cron tab

Hello Every one, I have a shell script which is running fine manually, but its giving me hard time when running tru cron job. :wall:. Am using #!/usr/bin/ksh >echo $SHELL /usr/bin/ksh Cron Job is as below, it execues but dosent do what i want it to do. 47 15 * * *... (1 Reply)
Discussion started by: naren.chowdhary
1 Replies

6. UNIX for Dummies Questions & Answers

Script only runs as a particular user

Hi guys So I've got this PERL script that for one reason or another I need to run as a user other than the user that created the script. When I su - to another user the script won't run and doesn't give me any output as to why. No permission denied or anything like that. I've chmod 777'd the... (5 Replies)
Discussion started by: Jaymoney
5 Replies

7. AIX

Script runs in shell but not cron

We run some menu driven software that has the ability to batch menu paths and generate reports quickly. Normally you run a batch like: $ BATCH BATCHNAME The batch program then prompts you for the date you want the report run for. I got some help from some folks on IRC to do the following: BATCH... (2 Replies)
Discussion started by: herot
2 Replies

8. Shell Programming and Scripting

Odd results when my script runs from cron..

Hi folks, So I wrote a script to run "top", "awk" out values fro the "top" and send the results to a data file. I then set it to run in cron every 15 minutes. Now I'm noticing that the script, and it's sub-commands are not always cleanly finishing and, in my investigations, I am also... (11 Replies)
Discussion started by: Marc G
11 Replies

9. Shell Programming and Scripting

Script runs in command-line fine but times out in CRON?

Hi, I have a script that seems to run to completion when in the command-line, but when it is run using the cron, it seems to time out. They both start and run fine, but on the CRON it stops prematurely. The script hits an API every few seconds and grabs data. Does anyone have any idea on... (4 Replies)
Discussion started by: phpchick
4 Replies

10. Shell Programming and Scripting

Script runs manually, but not from cron

Hi, I "borrowed" a script I found online, to start a SAP router application on a Solaris 11 (SPARC) server. The script runs fine when calling it manually, but when I schedule it to run from cron, it doesn't. I don't see any warning or failure messages anywhere, just nothing happens. ... (11 Replies)
Discussion started by: bredman
11 Replies
who(1)								   User Commands							    who(1)

NAME
who - who is on the system SYNOPSIS
/usr/bin/who [-abdHlmpqrstTu] [file] /usr/bin/who -q [-n x] [file] /usr/bin/who am i /usr/bin/who am I /usr/xpg4/bin/who [-abdHlmpqrtTu] [file] /usr/xpg4/bin/who -q [-n x] [file] /usr/xpg4/bin/who -s [-bdHlmpqrtu] [file] /usr/xpg4/bin/who am i /usr/xpg4/bin/who am I DESCRIPTION
The who utility can list the user's name, terminal line, login time, elapsed time since activity occurred on the line, and the process-ID of the command interpreter (shell) for each current UNIX system user. It examines the /var/adm/utmpx file to obtain its information. If file is given, that file (which must be in utmpx(4) format) is examined. Usually, file will be /var/adm/wtmpx, which contains a history of all the logins since the file was last created. The general format for output is: name [state] line time [idle] [pid] [comment] [exit] where: name User's login name state Capability of writing to the terminal line Name of the line found in /dev time Time since user's login idle Time elapsed since the user's last activity pid User's process id comment Comment line in inittab(4) exit Exit status for dead processes OPTIONS
The following options are supported: -a Processes /var/adm/utmpx or the named file with -b, -d, -l, -p, -r, -t, -T, and -u options turned on. -b Indicates the time and date of the last reboot. -d Displays all processes that have expired and not been respawned by init. The exit field appears for dead processes and contains the termination and exit values (as returned by wait(3UCB)), of the dead process. This can be useful in determining why a process terminated. -H Outputs column headings above the regular output. -l Lists only those lines on which the system is waiting for someone to login. The name field is LOGIN in such cases. Other fields are the same as for user entries except that the state field does not exist. -m Outputs only information about the current terminal. -n x Takes a numeric argument, x, which specifies the number of users to display per line. x must be at least 1. The -n option can only be used with -q. -p Lists any other process that is currently active and has been previously spawned by init. The name field is the name of the pro- gram executed by init as found in /sbin/inittab. The state, line, and idle fields have no meaning. The comment field shows the id field of the line from /sbin/inittab that spawned this process. See inittab(4). -q (Quick who) Displays only the names and the number of users currently logged on. When this option is used, all other options are ignored. -r Indicates the current run-level of the init process. -s (Default) Lists only the name, line, and time fields. /usr/bin/who -T Same as the -s option, except that the state idle, pid, and comment, fields are also written. state is one of the following charac- ters: + The terminal allows write access to other users. - The terminal denies write access to other users. ? The terminal write-access state cannot be determined. /usr/xpg4/bin/who -T Same as the -s option, except that the state field is also written. state is one of the characters listed under the /usr/bin/who version of this option. If the -u option is used with -T, the idle time is added to the end of the previous format. -t Indicates the last change to the system clock (using the date utility) by root. See su(1M) and date(1). -u Lists only those users who are currently logged in. The name is the user's login name. The line is the name of the line as found in the directory /dev. The time is the time that the user logged in. The idle column contains the number of hours and minutes since activity last occurred on that particular line. A dot (.) indicates that the terminal has seen activity in the last minute and is therefore ``current.'' If more than twenty-four hours have elapsed or the line has not been used since boot time, the entry is marked old. This field is useful when trying to determine whether a person is working at the terminal or not. The pid is the process-ID of the user's shell. The comment is the comment field associated with this line as found in /sbin/inittab (see init- tab(4)). This can contain information about where the terminal is located, the telephone number of the dataset, type of terminal if hard-wired, and so forth. OPERANDS
The following operands are supported: am i In the "C" locale, limits the output to describing the invoking user, equivalent to the -m option. The am and i or I must be sepa- am I rate arguments. file Specifies a path name of a file to substitute for the database of logged-on users that who uses by default. ENVIRONMENT VARIABLES
See environ(5) for descriptions of the following environment variables that affect the execution of who: LANG, LC_ALL, LC_CTYPE, LC_MES- SAGES, LC_TIME, and NLSPATH. EXIT STATUS
The following exit values are returned: 0 Successful completion. >0 An error occurred. FILES
/sbin/inittab Script for init /var/adm/utmpx Current user and accounting information /var/adm/wtmpx Historic user and accounting information ATTRIBUTES
See attributes(5) for descriptions of the following attributes: /usr/bin/who +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ /usr/xpg4/bin/who +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWxcu4 | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ SEE ALSO
date(1), login(1), mesg(1), init(1M), su(1M), wait(3UCB), inittab(4), utmpx(4), attributes(5), environ(5), standards(5) NOTES
Superuser: After a shutdown to the single-user state, who returns a prompt. Since /var/adm/utmpx is updated at login time and there is no login in single-user state, who cannot report accurately on this state. The command, who am i, however, returns the correct information. SunOS 5.11 3 Nov 2000 who(1)
All times are GMT -4. The time now is 11:33 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy