Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Newbie Question!

Status
Not open for further replies.

mbaranski

Programmer
Nov 3, 2000
421
US
I just installed Oracle 8 EE on Windows NT WS 4.0. I need to create a very simple table with about 20 cols to test a perl program I'm writing. Can someone explain how to set up a listener for a network connection (TCP/IP I think) and then create the database, and set a username and password. This is just to test a script, and nothing fancy at that. All I need is 1 table in a database that is avalible over the network. All of the info that I have seen so far is very convoluted, and the bulk of this project should NOT be me learning oracle. Any and all help is appreciated!

Mike B.
 
Unfortunately doing an Oracle install, creating a database, and configuring the network are the same amount of work even if you plan on only doing simple things. Here are some suggestions for short cuts that may help.

1. Select the option to create a sample database during installation. That will give you an instance named ORCL that you can use for playing around.

2. Make sure that the Oracle services created during the install are running. If not, start them. Do this in START->SETTINGS->CONTROL PANEL->SERVICES.

3. Bypass SQL*Net so you don't have to configure network settings. To do this you will have to log on to Oracle directly from the server. You can't use a client workstation. First open a command prompt window. Enter the command SET ORACLE_SID=ORCL Then start Server Manager. The command for this is SVRMGR30 in Oracle 8.0 and SVRMGRL in Oracle 8i. Within server manager connect to Oracle with the command CONNECT SYSTEM/MANAGER. (You can use any of the ids and passwords that automatically get created when a database is created.)

4. If you connect successfully and Oracle is running you will then be able to create the table and test the script that you want. If you like, you can write the scripts ahead of time, store them to a file and execute the contents of the file. To execute type the command @directory_path\filename from a server manager prompt.

Don't do this with anything you want to preserve, but perhaps this will get you started more easily.
 
That's a big help, I've got the table working now. I *do* need to set up the networking stuff now, though, because I'm trying to connect from a remote perl program to the box to get some data. Can anyone explain how to set up a listener on the correct port (14xx I think...) so my perl program can connect? The database is TEST and the tables is TEST_EMP.

Thanks!
Mike B.
 
How do I tell if it is or not and how do I start it if not? Probably not, because I'm not able to connect with the perl script...

thanks
Mike B.
 
type net start at a command prompt

if you see OracleTNSListener<sid> then it's running

have you tried connecting with SQL*Plus from a remote workstation? not to insult you but have you verified the remote client's tnsnames.ora? you mentioned you're using Perl so are you sure you have a SQL*Net problem instead of DBI? I personally won't help a developer with connectivity until they show me they can get SQL*Plus working on the problem box. Not to be an arse-ho but it's amazing how often &quot;problems with the database&quot; turn out to be &quot;problems with user's code&quot; (or w/network). not trying to flame just saying that's been my experience (after all, I AM the DBAwhosaysNIE ! :)

one last freebie I had happen with NT once: if you've changed the computer name AFTER installing Oracle you will need to go in and modify listener.ora in $ORACLE_HOME/network/admin
 
I'll try the net start thing. The code for the dba in perl is OK, I've been posting to the perl dbi mailing list as well. I think that I've gotten the perl stuff right, and I do have a tnsnames.ora file that is correct as far as I can tell. It does not have the host IP address in it, but the hostname, which should be looked up from the /etc/hosts file, correct? Also, I won't be back at work until tommorow, so I'll try the stuff then. I admittedly don't know anything about oracle, so anything, simple or not, is appreciated.

I can reach the machine over the network, and can view drives through the samba client on the Linux box, so I know it's not a netowork issue. Also, I have an informix program connecting to a remote server, so I think that I have the perl stuff down. I believe that it is a listner problem, but if no you'll hear back...

Thanks for your help.
 
OK, I've run net start, and I see a line that is

oracleNEWT_HOMETNSListener

but what is the SID?

 
Also, when I go to the net8 configuration utility, and modify the listener, it lists one listener in the drop down box for listeners to modify.

After I have gotten done modifying hte listener, it says that there is a conflicting listener, and that the one I've modified won't run until I delete the conflicting one. I don't understand why it lists only one listener in the drop down box, but gives me the conflicting message.

Also, I'm trying to understand what a SID is. Is it the name of the database, the name of the listener, the name of the instance of Oracle that is serving the database/listener, or something else entirely.

Finally, the hostname in the tnsnames.ora file on the client, should it be the NT machine's name on the network, or the Oracle instance name, or the listener name, or something else.

I'm very new to DBA, as you can tell, and have the oracle 8 complete reference. It is obviously not helping much. All I want to do is set up one table to import from with a remote perl script, and setting up the database is taking longer than development and testing!

Thanks for all the help so far.
Mike.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top