Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
November 24, 2024, 04:13:08 AM
News
: LinuxSolved.com Linux Help Community Forum..
Home
Search
Login
Register
Linux Forums - Linux Help,Advice & support community:LinuxSolved.com
»
Linux in General
»
Linux Development & Programming
»
LINUX SCRIPT FOR GETING THE NEWSET PID
« previous
next »
Print
Pages: [
1
]
Author
Topic: LINUX SCRIPT FOR GETING THE NEWSET PID (Read 10436 times)
santosh
New Member
Posts: 2
LINUX SCRIPT FOR GETING THE NEWSET PID
«
on:
May 07, 2004, 11:56:08 AM »
hi the follwing script will display all the PID's
ps -ef | grep "$1" | grep -v grep | awk '{print $1}'
but i want a script which displays only the newest PID generated.
Logged
santosh
New Member
Posts: 2
LINUX SCRIPT FOR GETING THE NEWSET PID
«
Reply #1 on:
May 08, 2004, 03:41:07 AM »
and does some one know to run the same script using php
Logged
dragoncity99
LST CareTaker
Experienced
Posts: 551
LINUX SCRIPT FOR GETING THE NEWSET PID
«
Reply #2 on:
May 08, 2004, 05:31:06 PM »
U can try to use program execution functions in php such as
exec(); to make it run on ur webserver.
Prototype for exec()
exec(string
command
[ array result[, int return value]])
For example:
exec("ls -la");
Logged
Print
Pages: [
1
]
« previous
next »
Linux Forums - Linux Help,Advice & support community:LinuxSolved.com
»
Linux in General
»
Linux Development & Programming
»
LINUX SCRIPT FOR GETING THE NEWSET PID