
You can get the hostname and the IP address of an Oracle database by executing below queries.
Oracle Hostname
SQL> SELECT UTL_INADDR.get_host_name FROM dual; GET_HOST_NAME ---------------------------------------------------------------- daem
SQL> SELECT host_name FROM v$instance; HOST_NAME ---------------------------------------------------------------- daem
Oracle IP Address
SQL> SELECT UTL_INADDR.get_host_address from dual; GET_HOST_ADDRESS --------------------------------------------------------------- 192.168.10.10
