Monday, April 09, 2007

OCA Oracle 10g Ch4 - Oracle Net Service

 

Ch4 - Oracle Net Service

Review Questions

 

1. All of the following are examples of networking architectures except:

A. Client/server

B. N-tier

C. Single-tier

D. Two-tier

E. All the above are examples of network architectures.

---

Ans: E.

All these are examples of network connectivity configurations. Networking can be as simple as

a dumb terminal connected directly to a server via a serial connection. It can also be as complex

as an n-tier architecture that involves clients, middleware, the Internet, and database servers.

 

 

2. You manage one non-Oracle database and several Oracle databases. An application needs to

access the non-Oracle database as if it were part of the Oracle databases. What tool allows you

to do this? (Choose the best answer.)

A. Oracle Advanced Security

B. Oracle Connection Manager

C. Heterogeneous Services

D. Oracle Net

E. None of the above

---

Ans: C.

Heterogeneous Services is the correct answer because these services provide cross-platform

connectivity to non-Oracle databases. Oracle Advanced Security would not solve this application

problem because it addresses security and not accessibility to non-Oracle databases. Oracle

Net would be part of the solution, but another Oracle Network component is necessary. Connection

Manager would also not be able to accommodate this requirement on its own.

 

 

3. Which of the following is true about Oracle Net?

A. It is not an option included in the Oracle Enterprise installation.

B. It works only on TCP/IP platforms.

C. It has the ability to communicate with non-Oracle data sources.

D. It is never installed directly on a client workstation.

----

Ans: C.

When you are using the Heterogeneous Services capabilities of Oracle Net, you do have the

ability to communicate with non-Oracle data sources.

 

4. You want to centrally administer all the Oracle network services in a large Oracle 10g installation

that runs many network services. Which of the following facilities would best provide this

functionality at minimal cost?

A. Advanced Security

B. Heterogeneous Services

C. Oracle Shared Server

D. Oracle Internet Directory

---

Ans: D.

The best solution to the problem is the Oracle Internet Directory because it facilitates centralized

naming. Advanced Security, Heterogeneous Services, and Oracle Shared Server would

not provide a solution to this business need because none of these address the issue of centrally

managing network services.

 

 

5. Which of the following files must be present on the Oracle server to start a non-default

Oracle listener?

A. listener.ora

B. lsnrctl.ora

C. sqlnet.ora

D. tnsnames.ora

---

Ans: A.

The listener is the process that manages incoming connection requests. The listener.ora

file is used to configure the listener and must be configured to start a non-default listener. The

sqlnet.ora file is an optional client- and server-side file. The tnsnames.ora file is used for

doing local naming resolution. There is no such file as lsnrctl.ora.

 

6. Which of the following is the correct way to start the default listener?

A. lsnrctl startup listener

B. lsnrctl start

C. listener start

D. listener start listener

---

Ans: B.

Because the default listener name is LISTENER, simply enter lsnrctl start. The name

LISTENER is assumed to be the listener to start in this case.

 

7. Which of the following parameters sets the number of seconds a server process waits to get a

valid client request?

A. connect_waittime_listener_name

B. connect_wait_listener_name

C. timeout_listener_name

D. inbound_connect_timeout_listener_name

---

Ans: D. When a user makes a connection request, the listener passes control to some server process

or dispatcher. Once the user is attached to this process, all negotiations and interaction with the

database pass through this process. If the user supplies an invalid user ID or password, the process

waits for a period of time for a valid response. If the user does not contact the server process

with a valid response in the allotted time, the server process terminates, and the user must contact

the listener so that the listener can again spawn a process or redirect the client to an existing

dispatcher. This period of time that the process waits is specified by the connect_timeout_

listener_name parameter. This parameter is specified in seconds.

 

 

8. When dynamic service registration is used, you will not see the service listed in which of the

following files where it would normally be located?

A. sqlnet.ora

B. tnsnames.ora

C. listener.ora

D. None of the above

--

Ans: C.

When services are dynamically registered with the listener, their information is not present in

the listener.ora file.

 

9. You have just made changes to the listener.ora file for the listener called listener1 using

Oracle Net Manager. Which of the following commands or combinations of commands would

you use to put the changes into effect with the least amount of client disruption?

A. lsnrctl stop listener1 followed by lsnrctl start listener1

B. lsrnctl restart listener1

C. lsnrctl reload listener1

D. lsnrctl reload

---

Ans: C. Although you can use choice A to stop and start the listener, doing so temporarily disrupts clients

attempting to connect to the database. Choice D is fine if you are starting and stopping the

default listener called LISTENER, but we are using a non-default listener. Choice B is not valid

because RESTART is not a valid command-line argument for lsnrctl. Therefore, the best method is

C, to use the lsnrctl reload listener1 command to load the new set of values in for the listener

without disrupting connection service to the databases that the listener is servicing.

 

 

10. What is the default name of the process that makes external calls via Oracle Net?

A. lsnrctl

B. external

C. extproc

D. procext

----

Ans: C.

The default name of the external procedure process is extproc. lsnrctl is a utility used to

manage the listener service. External and procext are not valid responses.

 

11. What are the ways in which a client can resolve a net service name? (Choose all that apply.)

A. Localnaming

B. Hostnaming

C. Easy Connect Naming

D. Oracle Global Naming

E. All the above

---

Ans: A, B, C.

Oracle uses service names in networks in much the same way it uses synonyms in the

database. Service names provide location transparency and hide the complexity of connect

string information. You can configure Oracle Net to connect in several ways, including hostnaming,

localnaming, OID, and Oracle Easy Connect Naming. Oracle Global Naming is not

a valid Oracle option.

 

 

12. Connection Manager provides which of the following?

A. Multiplexing

B. Cross-protocol connectivity

C. Network access control

D. All the above

--

Ans: D.

Connection Manager is a middleware solution that provides for multiplexing of connections,

cross-protocol connectivity, and network access control. All the answers describe Connection

Manager.

 

13. Which is a requirement for using hostnaming?

A. You must use tnsnames.ora on the client.

B. You must be using TCP/IP.

C. You must have an OID present.

D. You must have a sqlnet.ora file present on the client.

E. None of the above.

----

Ans: B.

Hostnaming is typically used in small installations that have few Oracle databases. This is an

attractive option when you want to minimize client-side configuration. TCP/IP is a requirement

when you use hostnaming.

 

14. To which of the choices below does the following statement apply? 'Prevents direct communication

between a client outside the corporate network and applications inside the corporate

network.'

A. Proxy-based firewalls

B. Filter-based firewalls

C. Both types of firewalls

D. Neither type of firewall

---

Ans: A.

Proxy-based firewalls prevent any direct contact between a client outside the corporate firewall

and applications inside a corporate firewall. Filter-based firewalls inspect the packet headers but

pass the packet on without modification to the destination application. Proxy-based firewalls act

more as a relay between external clients and internal applications.

 

15. Which of the following statements about tnsnames.ora is false?

A. It is used to resolve an Oracle service name.

B. It can exist on the client.

C. It is used for localnaming.

D. It does not support the TCP/IP protocol

----

Ans: D.

A tnsnames.ora file is configured when you want to use localnaming, and it typically exists

on the client workstation. It is also used to resolve a service name. The tnsnames.ora file used in

localnaming does indeed support the TCP/IP protocol.

 

16. You manage a large network of servers with many Oracle10g instances configured on each

server. The company would like to centralize the Oracle services into a common location for

ease of maintenance. Which of the following would be the best choice for centralized naming

services?

A. Oracle Easy Connect Naming

B. Localnaming

C. Oracle Names Server

D. Oracle Internet Directory

--

Ans: D.

OID is Oracle’s preferred centralized naming service. Oracle Names Server is no longer supported

in Oracle 10g.

 

17. A client receives the following error message:

'ORA-12154 TNS:could not resolve the connect identifier

specified'

Which of the following could be possible causes of the error? (Choose all that apply.)

A. The listener is not running on the Oracle server.

B. The user entered an invalid net service name.

C. The user supplied the correct net service name, but the net service name is misspelled in the

tnsnames.ora file.

D. The listener is not configured to listen for this service.

--

Ans: B, C.

Supplying a net service name that is not contained in the tnsnames.ora file can cause this

error. Problems with the tnsnames.ora file can cause this error too. Listener problems would

not cause this error.

 

18. What portion of the tnsnames.ora file specifies the name or IP address of the server where the

listener process is listening?

A. CONNECT_DATA

B. PORT

C. SERVICE_NAME

D. HOST

---

Ans: D.

The HOST portion specifies the name of the server to contact. CONNECT_DATA specifies the

database service to connect to. The PORT portion specifies the location where the listener is

listening on the HOST. SERVICE_NAME is the name of the actual database service.

 

19. Which of the following is the utility that you can use to test the network connections across TCP/IP?

A. trcasst

B. lsnrctl

C. namesctl

D. ping

E. None of the above

---

Ans: D. Protocols come with tools that allow you to test network connectivity. One such utility for

TCP/IP is ping. The user supplies either an IP address or a hostname to the ping utility. It then

searches the network for this address. If it finds one, it displays information on data that is sent and

received and how quickly it found this address. The other choices are Oracle-supplied utilities.

 

20. A client wants to connect to the database dbprod.com located on the dbprod.com server to a

non-default port using Oracle Easy Connect. Which of the following connect strings is the best

choice for the client use?

A. CONNECT scott/tiger@dbprod.com:1522

B. CONNECT scott/tiger@1521:dbprod.com/dbprod.com

C. CONNECT scott/tiger@dbprod.com/1522:dbprod.com

D. CONNECT scott/tiger@dbprod.com:1521/dbprod.com

E. CONNECT scott/tiger@dbprod.com:1522/dbprod.com

---

Ans: A.

The correct syntax to use with the Oracle Easy Connect Naming method when you are

connecting to a non-URL location is as follows: connect username/password@host:port/

service_name. If the service name and the host are identical, you do not have to include the service

name. If the port is any port other than the default port of 1521, it must be specified. Because

we want to connect to a non-default port where the database name and the hostname are the same,

the best answer is A.

 

No comments: