Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Ip address
Adi,
The following query gets the IP address of a client session connected to the database:
SELECT UPPER(program) program, username,
osuser, terminal,
sys_context('USERENV','IP_ADDRESS') ip_addr
FROM V$SESSION WHERE AUDSID = USERENV('SESSIONID'); Tom
From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Dennis Williams
Sent: Monday, February 12, 2007 11:17 AM
To: adi_at_zetapoint.com
Cc: oracle-l_at_freelists.org
Subject: Re: Ip address
Adi,
Since nobody has responded to your question, I'll provide what I know and it isn't much.
Take a look at the terminal column of v$process and the terminal and machine columns of v$session. I could swear I've seen the ip address pop up for some connections on some servers. It may be related to how the user connects, or to some network configuration. Try that, otherwise your UTL command may be a more consistent way to get this info.
Dennis Williams
-- http://www.freelists.org/webpage/oracle-lReceived on Mon Feb 12 2007 - 10:31:17 CST
![]() |
![]() |