DBD::Oracle with oracle child process with parent ID of 1
DBD::Oracle with oracle child process with parent ID of 1
am 30.05.2006 17:14:38 von KongA
------_=_NextPart_001_01C683FB.C487725E
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi all,
Does anyone know why the oracle child process initiated by my perl
program with parent ID of 1? =20
My system is HPUX 11.11 with PERL5.8.0, DBI1.48, DBD-Oracle-1.16,
Oracle10.2.0.
I have another system with HPUX11.00, PERL5.6.1, DBI1.48,
DBD-Oracle-1.16, Oracle8.1.7 where oracle child process is the pid of
perl program which initiated it.
Any help will be appreciated.
Thans,
Alan
------_=_NextPart_001_01C683FB.C487725E--
Re: DBD::Oracle with oracle child process with parent ID of 1
am 30.05.2006 18:04:27 von mark
Kong, Alan wrote:
> Hi all,
>
> Does anyone know why the oracle child process initiated by my perl
> program with parent ID of 1?
>
> My system is HPUX 11.11 with PERL5.8.0, DBI1.48, DBD-Oracle-1.16,
> Oracle10.2.0.
>
> I have another system with HPUX11.00, PERL5.6.1, DBI1.48,
> DBD-Oracle-1.16, Oracle8.1.7 where oracle child process is the pid of
> perl program which initiated it.
When a process's parent exits, the unix kernel assigns process 1
(the init process) to be the parent. This is normal unix
behavior, and the way all "daemons" run.
The difference between your systems is probably that you are
connecting differently. In the one case, you're connecting
via sqlnet listener, and on the other, via the 'beq' scheme.
When you connect via typical sqlnet setup, your client program
(be is perl, sqlplus, or anything) makes a TCP connection to
the oracle listener, and the listener starts the oracle client
process for your connection. That process then runs as 'daemon'.
When you connect directly by setting ORACLE_SID, your program
itself starts the oracle process, so it's the parent.
Note this has nothing to do with perl or DBI. This is just
oracle behavior and the same with any oracle client application.
Also, this is perfectly normal.
Mark
RE: DBD::Oracle with oracle child process with parent ID of 1
am 30.05.2006 18:15:47 von KongA
Mark,
First of all, thanks for your reply.
The problem that I am having is the parent process is still running, and
the child process shouldn't become a orphan process. The reason why I
posted this problem in DBI user group is because the problem is not
there when I login to Oracle with SQL*PLUS, only when I run PERL DBI
connecting to Oracle shows the child process like an orphan process.
Alan
=20
-----Original Message-----
From: markd [mailto:mark@immermail.com]=20
Sent: Tuesday, May 30, 2006 12:04 PM
To: Kong, Alan
Cc: dbi-users@perl.org
Subject: Re: DBD::Oracle with oracle child process with parent ID of 1
Kong, Alan wrote:
> Hi all,
>=20
> Does anyone know why the oracle child process initiated by my perl=20
> program with parent ID of 1?
>=20
> My system is HPUX 11.11 with PERL5.8.0, DBI1.48, DBD-Oracle-1.16,=20
> Oracle10.2.0.
>=20
> I have another system with HPUX11.00, PERL5.6.1, DBI1.48,=20
> DBD-Oracle-1.16, Oracle8.1.7 where oracle child process is the pid of=20
> perl program which initiated it.
When a process's parent exits, the unix kernel assigns process 1 (the
init process) to be the parent. This is normal unix behavior, and the
way all "daemons" run.
The difference between your systems is probably that you are connecting
differently. In the one case, you're connecting via sqlnet listener,
and on the other, via the 'beq' scheme.
When you connect via typical sqlnet setup, your client program (be is
perl, sqlplus, or anything) makes a TCP connection to the oracle
listener, and the listener starts the oracle client process for your
connection. That process then runs as 'daemon'.
When you connect directly by setting ORACLE_SID, your program itself
starts the oracle process, so it's the parent.
Note this has nothing to do with perl or DBI. This is just oracle
behavior and the same with any oracle client application.
Also, this is perfectly normal.
Mark
Re: DBD::Oracle with oracle child process with parent ID of 1
am 30.05.2006 19:25:06 von mark
Kong, Alan wrote:
> The problem that I am having is the parent process is still running, and
> the child process shouldn't become a orphan process. The reason why I
> posted this problem in DBI user group is because the problem is not
> there when I login to Oracle with SQL*PLUS, only when I run PERL DBI
> connecting to Oracle shows the child process like an orphan process.
So what is the *problem* here? Do you think this is causing
some actual problem, or are you just concerned because you think
it is not "right"?
Anyway, here's a demonstration that this is normal, and depends
on how you connect. I will demo using sqlplus:
#1 baseline - no client processes running on DEMO db
%ps -opid,ppid,command ax | grep oracleDEMO | grep -v grep
[ no results ]
#2 connect via listener and look at processes
% sqlplus -s scott/tiger@DEMO
SQL> !ps -opid,ppid,command ax | grep oracleDEMO | grep -v grep
4619 1 oracleDEMO (LOCAL=NO)
So now there is an oracle process spawned for me. It has parent id 1,
because it was not started by sqlplus, it was started by the
oracle listener ( which leaves it to run as a "daemon" -- you might
want to call it "orphan", but that's just semantics.)
#3 connect via BEQ
% setenv ORACLE_SID DEMO
% sqlplus -s scott/tiger
SQL> !ps -opid,ppid,command ax | grep oracleDEMO | grep -v grep
4660 4659 oracleDMEO (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
SQL> !ps -opid,ppid,command -p 4659
4659 4586 sqlplus
In this case, sqlplus itself started the oracle process, so it
is the parent.
So if you have an actual problem, and/or your system behaves differently,
feel free to reply, but I suggest off-list at this point, since it's
not perl/dbi related.
Mark
> -----Original Message-----
> From: markd [mailto:mark@immermail.com]
> Sent: Tuesday, May 30, 2006 12:04 PM
> To: Kong, Alan
> Cc: dbi-users@perl.org
> Subject: Re: DBD::Oracle with oracle child process with parent ID of 1
>
> Kong, Alan wrote:
>
>
>>Hi all,
>>
>>Does anyone know why the oracle child process initiated by my perl
>>program with parent ID of 1?
>>
>>My system is HPUX 11.11 with PERL5.8.0, DBI1.48, DBD-Oracle-1.16,
>>Oracle10.2.0.
>>
>>I have another system with HPUX11.00, PERL5.6.1, DBI1.48,
>>DBD-Oracle-1.16, Oracle8.1.7 where oracle child process is the pid of
>>perl program which initiated it.
>
>
> When a process's parent exits, the unix kernel assigns process 1 (the
> init process) to be the parent. This is normal unix behavior, and the
> way all "daemons" run.
>
> The difference between your systems is probably that you are connecting
> differently. In the one case, you're connecting via sqlnet listener,
> and on the other, via the 'beq' scheme.
>
> When you connect via typical sqlnet setup, your client program (be is
> perl, sqlplus, or anything) makes a TCP connection to the oracle
> listener, and the listener starts the oracle client process for your
> connection. That process then runs as 'daemon'.
>
> When you connect directly by setting ORACLE_SID, your program itself
> starts the oracle process, so it's the parent.
>
> Note this has nothing to do with perl or DBI. This is just oracle
> behavior and the same with any oracle client application.
> Also, this is perfectly normal.
>
> Mark
>
>