Network Topology   «Prev 

Testing your connection to the Database

The following instructions outline the procedure for testing a connection to the database.
  1. The first step in establishing connectivity is to test the connectivity to the remote host. To the right of the DOS prompt type ping 222.34.55.67. Then press Enter.
  2. This is what DOS should return. If it doesn't, you have a problem with your network, which may have to do with the domain-name server (DNS). The next step is to test the connectivity to the host name. Again, to the right of the DOS prompt type ping dilbert. Then press Enter on your keyboard.
  3. This is what DOS should return. At this point, you know that your services file is translating the host name dilbert into its corresponding IP address. The services file is located on each PC in c:\Program Files\Common Files\services. If this command fails, see your systems administrator to repair your services file.
    Now you're ready to test connectivity to the Oracle listener. In our example, you would connect to the tom database on the dilbert server. To the right of the DOS prompt type tnsping tom. Then press Enter on your keyboard.
  4. This is what DOS should return. Here you see that tnsping successfully touched the tom database in 250 milliseconds. If this command fails, first check to ensure that the remote listener is running. If the listener is running, check your tnsnames.ora file.
  5. The next step is to use SQL*Plus to connect to the database as a user. Click the Next button to advance to the next screen and we'll load the GUI for you.
  6. Here you use SQL*Plus to connect to the database as a user. Click in the User Name field and we'll enter in the user name for you.
  7. Click in the Host String field and we'll enter it in for you.
  8. Click in the Password field and we'll enter the password for you.
  9. Then click OK to initiate the connection.
  10. If the connection is successful, you will see the SQL prompt from SQL*Plus. If it fails, you need to get a valid user ID and password for the remote database. We will revisit connectivity testing in the second course in this series when we learn how to troubleshoot an Oracle network. This is the end of the simulation.