Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 273
  • Last Modified:

Find Process ID of Job Created with AT

When I start a command with AT, I wish to know its process ID to kill it, and see if its finished.  How is this done?
I normally use tail -f <logfile> to watch its log progress.
0
snydero
Asked:
snydero
  • 2
  • 2
  • 2
  • +1
1 Solution
 
HalldorGCommented:
pstree will give you some clues
0
 
snyderoAuthor Commented:
Sorry I didn't mention that its Sun Solaris 2.6 - bash shell.
The pstree command is not found.  Could i change shell and use it.  How do I change shell?

0
 
HalldorGCommented:
The pstree is a linux command :( sorry
0
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

 
jceaCommented:
* Write in the AT invocation something like "cat $$ >/path/pid". So, when AT executes your process,. its PID will be saved into "pid" file.

* Run your AT jobs as a special user. You can use "ptree" to see the processes tree per User or per PID.
0
 
snyderoAuthor Commented:
I had to use "echo $$ >/path/pid" in this version (bash)
Thanks for the expertise
0
 
jceaCommented:
Yeah, a typo, you know :-). You're right, of course.
0
 
ssaldhiCommented:
After giving the at command ,just give echo $$ to have its PID
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now