I have a compute instance on OCI with a source and a target database on it. The external subnet is being used by GoldenGate for connections. I use Network security groups for Access control. The creation of the database link is using the IP address that GoldenGate uses but this should be configurable in my opinion.
This is the resulting command:
CREATE DATABASE LINK DBLINK7 CONNECT TO GGADMIN IDENTIFIED BY "<password>" USING '1xx.2xx.7x.1xx:1521/upgr12c_to_19c.livelabs.oraclevcn.com'
I would have liked to be able to specify the internal IP address of the source database or even localhost here.
The result of the above command is ORA-39001: invalid argument value ORA-39200: Link name "DBLINK7" is invalid. ORA-12170: TNS:Connect timeout occurred