R-K
R-K

Reputation: 149

host_name in v$instance view

What does Oracle use to populate the host_name field in v$instance view OR machine in v$session. Is it hostname shell command or /etc/hosts file or something else?

I need to get the fully qualified hostname for two standbys I use. Each is opened in different mode (one ADG). Using "select * from v$session where username='PUBLIC'", I can pick machine name. But in some primary servers, it is FDQHN and in some shortname.

If I know what Oracle uses to get the host name, I can ask Infra team to set it to FDQHN.

Upvotes: 0

Views: 534

Answers (1)

Mark D Powell
Mark D Powell

Reputation: 184

Several of the columns in V$SESSION such as machine, program are populated by the Oracle client when making a connection. In the past one version of the client failed to populate program. So some sessions in V$SESSION had information in the program and some did not since we had multiple versions of the client software in use. If you have access to Oracle support you can find this in Non US7ASCII characters may not be seen correctly in V$Session OSUSER, MACHINE and PROGRAM fields. (Doc ID 759325.1)

Upvotes: 0

Related Questions