Re: off-topic ->UNIX question
hello hey - this is a great and really comprehensive explanation. >>> [EMAIL PROTECTED] 09/03/02 14:36 PM >>> Hello Processes can test the validity of PID's by signalling the PID with a ZERO signal number. To signal the process you use the kill() system call. When a zero signal number is used error checking is done but no signal is sent so that you don't have to worry about what the process is going to do with a untrapped or ill-defined interrupt handler eg. #include #include main(int argc, char *argv[]) { int pidno = atoi(argv[1]); if(kill(pidno,0) == 0) printf("pid number %d exists\n",pidno); else printf("pid number %d does not exist (or does not belong to you)\n",pidno); exit(0); } The above code will check the pid passed as the first command line argument to the program. Note that you can't signal arbitrary processes unless you are the superuser or the process is owned by your userid. HTH Jeff Herrick On Tue, 3 Sep 2002, Santosh Varma wrote: > Hello all, > > I get a process id by calling getProcessId()..I want to know from > program whether that processId exists. > Any way to find out how ? > > Thanks and regards, > Santosh > -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Jeff Herrick INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Markus Reger INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Re: off-topic ->UNIX question
-- Santosh Varma <[EMAIL PROTECTED]> > Hello all, > > I get a process id by calling getProcessId()..I want to know from > program whether that processId exists. > Any way to find out how ? Depends on the O/s. Simplest way is to grep the output of ps. On systems with a /proc file system (e.g., linux, Solaris) you can look for /proc/$id. -- Steven Lembark 2930 W. Palmer Workhorse Computing Chicago, IL 60647 +1 800 762 1582 -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Steven Lembark INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Re: off-topic ->UNIX question
in the shell enter "echo $$". didn't indicate in what application. kr mr >>> [EMAIL PROTECTED] 09/03/02 13:29 PM >>> Hello all, I get a process id by calling getProcessId()..I want to know from program whether that processId exists. Any way to find out how ? Thanks and regards, Santosh -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Markus Reger INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Re: off-topic ->UNIX question
Hello Processes can test the validity of PID's by signalling the PID with a ZERO signal number. To signal the process you use the kill() system call. When a zero signal number is used error checking is done but no signal is sent so that you don't have to worry about what the process is going to do with a untrapped or ill-defined interrupt handler eg. #include #include main(int argc, char *argv[]) { int pidno = atoi(argv[1]); if(kill(pidno,0) == 0) printf("pid number %d exists\n",pidno); else printf("pid number %d does not exist (or does not belong to you)\n",pidno); exit(0); } The above code will check the pid passed as the first command line argument to the program. Note that you can't signal arbitrary processes unless you are the superuser or the process is owned by your userid. HTH Jeff Herrick On Tue, 3 Sep 2002, Santosh Varma wrote: > Hello all, > > I get a process id by calling getProcessId()..I want to know from > program whether that processId exists. > Any way to find out how ? > > Thanks and regards, > Santosh > -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Jeff Herrick INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
off-topic ->UNIX question
Hello all, I get a process id by calling getProcessId()..I want to know from program whether that processId exists. Any way to find out how ? Thanks and regards, Santosh
Re: Off Topic Unix question
Hi Rick, x86 refers to the Solaris for Intel version. There are slightly different patches for this version. Assuming you are running on SPARC, you want the non-x86 version. Dave Miller Sun Microsystems, Inc. >Date: Tue, 27 Mar 2001 10:05:26 -0800 >To: Multiple recipients of list ORACLE-L <[EMAIL PROTECTED]> >X-Comment: Oracle RDBMS Community Forum >X-Sender: "Cale, Rick T (Richard)" <[EMAIL PROTECTED]> >From: "Cale, Rick T (Richard)" <[EMAIL PROTECTED]> >Subject: Off Topic Unix question >X-ListServer: v1.0g, build 70; ListGuru (c) 1996-2001 Bruce A. Bergman >Mime-Version: 1.0 >Content-Transfer-Encoding: 7bit > >One of co-workers is going to upgrade from Solaris 2.6 to 2.7(version 7). >The question they had is what >patch cluster to apply the below web site has >7 x86(21.7m) and 7 (39.8m). Which one to apply? > > >"Rick >I was looking at >http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/patch-access >and wondering what the x86 is referring to. I am interested in the patches >for Solaris 7 and wanted to be sure that I am looking at the correct patch >cluster. >Steve" > >Thanks >Rick Cale, Science Applications International Corp. >Phone:865-481-2198, fax:865-481-8555 >e-mail: [EMAIL PROTECTED] > >-- >Please see the official ORACLE-L FAQ: http://www.orafaq.com >-- >Author: Cale, Rick T (Richard) > INET: [EMAIL PROTECTED] > >Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 >San Diego, California-- Public Internet access / Mailing Lists > >To REMOVE yourself from this mailing list, send an E-Mail message >to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in >the message BODY, include a line containing: UNSUB ORACLE-L >(or the name of mailing list you want to be removed from). You may >also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: David Miller INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Re: Off Topic Unix question
x87 is the version of Solaris that runs on an Intel based (PC) machine. For sun hardware, you don't want x86 >>> [EMAIL PROTECTED] 03/27/01 01:05PM >>> One of co-workers is going to upgrade from Solaris 2.6 to 2.7(version 7). The question they had is what patch cluster to apply the below web site has 7 x86(21.7m) and 7 (39.8m). Which one to apply? "Rick I was looking at http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/patch-access and wondering what the x86 is referring to. I am interested in the patches for Solaris 7 and wanted to be sure that I am looking at the correct patch cluster. Steve" Thanks Rick Cale, Science Applications International Corp. Phone:865-481-2198, fax:865-481-8555 e-mail: [EMAIL PROTECTED] -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Cale, Rick T (Richard) INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: William Beilstein INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
RE: Off Topic Unix question
Rick, x86 stands for the Intel (processor) version of Solaris...as opposed to the Spark (processor) version of Solaris. Ed Haskins Oracle DBA Verizon Wireless -Original Message- Sent: Tuesday, March 27, 2001 1:05 PM To: Multiple recipients of list ORACLE-L One of co-workers is going to upgrade from Solaris 2.6 to 2.7(version 7). The question they had is what patch cluster to apply the below web site has 7 x86(21.7m) and 7 (39.8m). Which one to apply? "Rick I was looking at http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/patch-access and wondering what the x86 is referring to. I am interested in the patches for Solaris 7 and wanted to be sure that I am looking at the correct patch cluster. Steve" Thanks Rick Cale, Science Applications International Corp. Phone:865-481-2198, fax:865-481-8555 e-mail: [EMAIL PROTECTED] -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Cale, Rick T (Richard) INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Off Topic Unix question
One of co-workers is going to upgrade from Solaris 2.6 to 2.7(version 7). The question they had is what patch cluster to apply the below web site has 7 x86(21.7m) and 7 (39.8m). Which one to apply? "Rick I was looking at http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/patch-access and wondering what the x86 is referring to. I am interested in the patches for Solaris 7 and wanted to be sure that I am looking at the correct patch cluster. Steve" Thanks Rick Cale, Science Applications International Corp. Phone:865-481-2198, fax:865-481-8555 e-mail: [EMAIL PROTECTED] -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Cale, Rick T (Richard) INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).