Sponsored Content
Top Forums UNIX for Advanced & Expert Users Problem to track process IDs in HP-UX machine Post 302162958 by abhishek0071 on Wednesday 30th of January 2008 09:21:54 PM
Old 01-30-2008
Problem to track process IDs in HP-UX machine

Hello All,

I need to track the exact process ID related to a particular application running on HP-UX machine. i.e. the exact functionality of fuser unix command.
fuser application.log // It gives the exact process ID for application.log
Since there is no provision for 'fuser' in HP-UX machine, please help me how I can achieve the same functionality.

Thanks & Regards
Abhishek
 

10 More Discussions You Might Find Interesting

1. Programming

List of Thread IDs of a process

Hello, Can some one tell how to read the thread IDs of the current process in Sun Solaris. Any help will be appreciated. regards, Murali (0 Replies)
Discussion started by: hmurali
0 Replies

2. Shell Programming and Scripting

Track Sftp process

Hi, I am using sftp in my bash script. I wanted to know whether if there is any way that we can track whether sftp has been successful or not.. Does sftp return any codes? Thanks in adv (9 Replies)
Discussion started by: borncrazy
9 Replies

3. Shell Programming and Scripting

script to loop all process ids and take pmap

Hi all, I need a script that will loop around all the current processes and take a pmap -x <process id> and output each pmap to a separate file. Would anyone have a quick command to do this? (2 Replies)
Discussion started by: borderblaster
2 Replies

4. Shell Programming and Scripting

How to track and later kill a process in a script

Hello, I am trying to write a script that turns off the screensaver for a certain period of time, then come back on. I have had it up and running for a while, but then I decided to refactor it a bit for my family members that are less computer savvy. I am starting a subshell for the "meat" of... (4 Replies)
Discussion started by: Narnie
4 Replies

5. UNIX for Dummies Questions & Answers

Scripting - process and user ids...Help please

Hello all: Working on a job I was asked get a simple script to perform the following task and would like to ask for some help. I'm looking forward to learning more and diving deeper into the World of Open Source servers. I need a script for a Unix server, using as few lines as possible, that... (4 Replies)
Discussion started by: moahten
4 Replies

6. Shell Programming and Scripting

Track Child process exit

hi, I have a job that spawns multiple child processes in background.. Catch is i want to wait for some jobs to finish before i spawn more background processes. (each job creates a file and deletes at the end of it . so i don't want start new jobs after x amount of disk size is used up) now,... (2 Replies)
Discussion started by: ak_saravanan
2 Replies

7. Shell Programming and Scripting

ps returning more process ids

Please help me with this question I have a tantan.sh under /home/mydir which is a caller to another script "tantan.sh" under /home/anotherdir ----------------------------------------------------------- /home/mydir/tantan.sh ------------------------------------------------------------... (6 Replies)
Discussion started by: guruincredible
6 Replies

8. Shell Programming and Scripting

Search process ids

Hi, I have four tomcat instances named PNK, PNK1, PNK2, PNK3. All are running on the same server. To kill tomcat instance I usually do below for PNK1,PNK2,PNK3 kill -9 `ps -ef|grep tomcat|grep PNK1|grep -v grep|awk '{print $2}'` But the above command does not work for PNK. Can some... (7 Replies)
Discussion started by: lpprasad321
7 Replies

9. Shell Programming and Scripting

List out Process ids restarted today

Hi, I need to list out the processes which are started/restarted today in my Solaris box. If not possible need to convert the process uptime in minutes or seconds and compare it with a configurable value to list out those process ids for further processing in my scripting. Can any one guide... (7 Replies)
Discussion started by: ananan
7 Replies

10. UNIX for Beginners Questions & Answers

Some trace file to track timings of a process

I will initiate a process from Server1 and the flow is as follow Server1 --> Web server --> Application server --> DB Server Note all seperate unix servers. Now I need to put a trace for that process to track the timings from each server. Like the below trace should be there: ... (5 Replies)
Discussion started by: saraperu
5 Replies
FUSER(1P)						     POSIX Programmer's Manual							 FUSER(1P)

PROLOG
This manual page is part of the POSIX Programmer's Manual. The Linux implementation of this interface may differ (consult the correspond- ing Linux manual page for details of Linux behavior), or the interface may not be implemented on Linux. NAME
fuser - list process IDs of all processes that have one or more files open SYNOPSIS
fuser [ -cfu ] file ... DESCRIPTION
The fuser utility shall write to standard output the process IDs of processes running on the local system that have one or more named files open. For block special devices, all processes using any file on that device are listed. The fuser utility shall write to standard error additional information about the named files indicating how the file is being used. Any output for processes running on remote systems that have a named file open is unspecified. A user may need appropriate privilege to invoke the fuser utility. OPTIONS
The fuser utility shall conform to the Base Definitions volume of IEEE Std 1003.1-2001, Section 12.2, Utility Syntax Guidelines. The following options shall be supported: -c The file is treated as a mount point and the utility shall report on any files open in the file system. -f The report shall be only for the named files. -u The user name, in parentheses, associated with each process ID written to standard output shall be written to standard error. OPERANDS
The following operand shall be supported: file A pathname on which the file or file system is to be reported. STDIN
Not used. INPUT FILES
The user database. ENVIRONMENT VARIABLES
The following environment variables shall affect the execution of fuser: LANG Provide a default value for the internationalization variables that are unset or null. (See the Base Definitions volume of IEEE Std 1003.1-2001, Section 8.2, Internationalization Variables for the precedence of internationalization variables used to determine the values of locale categories.) LC_ALL If set to a non-empty string value, override the values of all the other internationalization variables. LC_CTYPE Determine the locale for the interpretation of sequences of bytes of text data as characters (for example, single-byte as opposed to multi-byte characters in arguments). LC_MESSAGES Determine the locale that should be used to affect the format and contents of diagnostic messages written to standard error. NLSPATH Determine the location of message catalogs for the processing of LC_MESSAGES . ASYNCHRONOUS EVENTS
Default. STDOUT
The fuser utility shall write the process ID for each process using each file given as an operand to standard output in the following for- mat: "%d", <process_id> STDERR
The fuser utility shall write diagnostic messages to standard error. The fuser utility also shall write the following to standard error: * The pathname of each named file is written followed immediately by a colon. * For each process ID written to standard output, the character 'c' shall be written to standard error if the process is using the file as its current directory and the character 'r' shall be written to standard error if the process is using the file as its root directory. Implementations may write other alphabetic characters to indicate other uses of files. * When the -u option is specified, characters indicating the use of the file shall be followed immediately by the user name, in parenthe- ses, corresponding to the process' real user ID. If the user name cannot be resolved from the process' real user ID, the process' real user ID shall be written instead of the user name. When standard output and standard error are directed to the same file, the output shall be interleaved so that the filename appears at the start of each line, followed by the process ID and characters indicating the use of the file. Then, if the -u option is specified, the user name or user ID for each process using that file shall be written. A <newline> shall be written to standard error after the last output described above for each file operand. OUTPUT FILES
None. EXTENDED DESCRIPTION
None. EXIT STATUS
The following exit values shall be returned: 0 Successful completion. >0 An error occurred. CONSEQUENCES OF ERRORS
Default. The following sections are informative. APPLICATION USAGE
None. EXAMPLES
The command: fuser -fu . writes to standard output the process IDs of processes that are using the current directory and writes to standard error an indication of how those processes are using the directory and the user names associated with the processes that are using the current directory. RATIONALE
The definition of the fuser utility follows existing practice. FUTURE DIRECTIONS
None. SEE ALSO
None. COPYRIGHT
Portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1, 2003 Edition, Standard for Information Technol- ogy -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 6, Copyright (C) 2001-2003 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html . IEEE
/The Open Group 2003 FUSER(1P)
All times are GMT -4. The time now is 08:23 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy