Skip to Main Content

Database Software


For appeals, questions and feedback, please email

CLIENT_IP - support acquiring it from v$session

Quanwen ZhaoMay 7 2023

Now various different oracle version from 10.2 to 19c I remembered there has the column MACHINE on v$session but seems to not have a column such as client_ip (nevertheless client_info) sometimes we expect to known the client ip addr as well apart from MACHINE (Operating system machine name), you know client_info is also able to retrieve ip after we created the related trigger with AFTER LOGON ON database by calling the PL/SQL procedure DBMS_APPLICATION_INFO.SET_CLIENT_INFO(SYS_CONTEXT(‘USERENV’, ‘IP_ADDRESS’)); but we still not able to acquire ip address before creating that trigger.

So I highly recommend oracle adding a similar column client_ip on v$session on the future new version, at least on 23c Free - Developer Release I've not found it, fortunately I've provided the workaround (not the best solution I think, haha) on my blog note. Thank you so much!

Best Regards

Quanwen Zhao

Post Details