Because navigating the RedHat site is laborious, here is a direct link to the documentation for RedHat Enterprise Linux:
https://www.redhat.com/docs/manuals/enterprise/
Also, here is the link to the older, RHEL3 documentation:
https://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual
enjoy.
Showing posts with label rhel3. Show all posts
Showing posts with label rhel3. Show all posts
Tuesday, July 24, 2007
Thursday, July 12, 2007
warning, got bogus tcp line in RHEL AS3
I have been plagued with this error while I use netstat on my RedHat Enterprise Linux, Advanced Server 3.0 box for a couple years now and never had the time to track it down. So I finally decided to investigate. It looks to be a bug on some RedHat systems: http://kbase.redhat.com/faq/FAQ_45_6180.shtm
The messages mean that "there are two identical recorded TCP connections. This can happen if a connection is rapidly closing and re-connecting on the same address/port tuple."
This seems to fit the behaviour of my webserver, as it is typically serving hundreds of connections at a time. But RedHat points to two specific parameters in /etc/sysctl.conf that are set to 1 instead of zero:
sysctl net.ipv4.tcp_tw_recycle
sysctl net.ipv4.tcp_tw_reuse
Of course, this was not true in my case. I believe however, that RedHat's general statement above about connections rapidly closing and reconnecting seems to be the cause.
To help you identify you particular problem, here are some other useful discussions of the same problem:
http://www.morgan-systems.com/tools/Dev_Netstat.asp
http://track.sipfoundry.org/browse/XPB-371
The messages mean that "there are two identical recorded TCP connections. This can happen if a connection is rapidly closing and re-connecting on the same address/port tuple."
This seems to fit the behaviour of my webserver, as it is typically serving hundreds of connections at a time. But RedHat points to two specific parameters in /etc/sysctl.conf that are set to 1 instead of zero:
sysctl net.ipv4.tcp_tw_recycle
sysctl net.ipv4.tcp_tw_reuse
Of course, this was not true in my case. I believe however, that RedHat's general statement above about connections rapidly closing and reconnecting seems to be the cause.
To help you identify you particular problem, here are some other useful discussions of the same problem:
http://www.morgan-systems.com/tools/Dev_Netstat.asp
http://track.sipfoundry.org/browse/XPB-371
Labels:
bogus tcp line,
error,
redhat enterprise linux,
rhel3
Wednesday, June 06, 2007
testing the Sun X4600M2 and ESX Server 3.0, part I
Outside of a few obstacles, we had a useful and interesting session testing a Sun X4600M2. The plan was to use three virtual machines on ESX Server 3.0 to simulate our eCommerce infrastructure:
- one Win2K3, IIS 6.0 web server running our website application
- one RHEL 3.0 AS running Oracle 10G
- one Win2K server running MS Web Stress Application Tool (MS WSAT) to generate HTTP traffic load against the Win2K3 web server
The X4600M2 we tested was an eight, dual-core 2.4Ghz Opteron RevE cpus connected to a Sun 5310 fiber storage array. The 4600 ran VMware ESX 3.0 server on top of a customized version of Linux built for VMware. I provided the vendor with the three preconfigured virtual machines. The vms were zipped on dual layer DVDs and took a while to copy and unzip, roughly an hour each. Also, the virtual machines were built on an Intel box and as such, needed to be converted specifically to the AMD Opteron architecture of the ESX server (the 4600). This was news to us and took about twenty minutes to convert the 8GB Windows vms and about an hour to convert the 33GB database file.
We started all three vms, did some Windows configuration and verified connectivity between the servers. TNSnames and an ODBC driver needed setup on the web server. The first large hurdle we encountered was that unlike our test system, the RHEL3 vm was not able to find its IP address via DHCP. After trying a few things, we assigned the address statically and the server then became available on the network. Once all three boxes were talking, we then verified that the website could pull data from the database. We did this; however, we saw that the database sequences were not created when we added an item to our cart. I got on the phone with our programmers and after about 45 minutes, resolved the problem using a public synonym. After this problem was solved, we spent a half an hour using the WSAT's recorder function to navigate the website and create the test cases. We were then able to start testing.
As our vendor did not have an Enterprise license for the ESX Server installation, we were limited to assigning up to four cpus per vm. So we assigned each vm the maximum available:
- Oracle vm: four cpus
- IIS vm: four cpus
- MS WSAT vm: four cpus
Since one CPU on the 4600 is dedicated to VMware overhead, this left three CPUs unused in the 4600.
We used MS WSAT to apply load to the Web server instance, slowly increasing load from one session to ten to one hundred virtual users in order to verify that:
1) the stress tool was working correctly,
2) the website was responding appropriately, and
3) we could see data via the VMware Virtual Infrastructure Client management app
We verified that these conditions were met.
It was interesting to view the VMware instrumentation. The VMware Infrastructure management app is a lot like Performance Monitor in Windows. You can view CPU/disk/memory and network stats. We toggled between the three vms and checked out performance stats for each. The most stressed vm was the IIS webserver, as it was serving data to the testing client (the Win2K server running MS WSAT), as well as pulling content from the database.
One interesting metric we saw in the management interface was called Megahertz Used, which is basically the percent of the total megahertz available to a vm. For example, if a vm has one 2.4Ghz cpu dedicated to it and that cpu is 10% busy, you're using 240Mhz of the available CPU power. On our Win2K3 web server vm, we had four cpus available at 2.4Ghz each. This gave us a total of about 10,000 megahertz available to the vm. When we increased the load to the Win2K3 web server, we saw that the webserver was using about 80-90% total CPU available or about 8,800Mhz of CPU. This load was more or less equally divided by the four CPUs assigned to the VM:
cpu0: 2300 mhz used
cpu1: 2200 mhz used
cpu2: 2200 mhz used
cpu3: 2100 mhz used
Utilizing the megahertz available to a vm, VMware is able to balances load to cpus within a vm as well as balance load between vms. ESX server 3.0 can dynamically provision new vms by analyzing this statistic.
Another interesting thing we did was to clone our testing server, the Win2K server with MS WSAT installed on it. As the clone is essentially a file copy, the process is i/o intensive and took about 10 minutes for the 8GB vm. With a configuration tweak and a quick start of the server, the cloned testing server was up and applying load against the website in 15 minutes total from start of clone to finish. Nice!
While testing, we found that the MS stress tool applies load, but has a nagging inability to capture enough information about a users' session so that an order can be completed through the test website. Also, the stress tool seems to quiesce after about 7-10 minutes. This may have been due to some caching on the database and web server layers, but is more likely due to a limitation with MS WSAT. So we are looking to replace this testing tool with one that doesn't have these limitations and can do interesting things like parameterize order and sku numbers in the requested URL. Compuware QALoad is a top candidate and one we're already licensed to have. We are currently researching tools for round 2 and hopefully, we'll have a substitute in the next couple of weeks.
In order to get a more full day of testing on the 4600, we will schedule a second visit to our vendor, with the caveat that I will bring a fully configured database, unzipped on an external USB drive in order to expedite the setup. Also, I hope to persuade the vendor to get an Enterprise license for ESX Server, so that we can assign more than four CPUs to an individual vm. Finally, at the end of the day, I will try to provide some screen shots or scripts of the evaluation session for the blog.
More to come..keep you posted!
- one Win2K3, IIS 6.0 web server running our website application
- one RHEL 3.0 AS running Oracle 10G
- one Win2K server running MS Web Stress Application Tool (MS WSAT) to generate HTTP traffic load against the Win2K3 web server
The X4600M2 we tested was an eight, dual-core 2.4Ghz Opteron RevE cpus connected to a Sun 5310 fiber storage array. The 4600 ran VMware ESX 3.0 server on top of a customized version of Linux built for VMware. I provided the vendor with the three preconfigured virtual machines. The vms were zipped on dual layer DVDs and took a while to copy and unzip, roughly an hour each. Also, the virtual machines were built on an Intel box and as such, needed to be converted specifically to the AMD Opteron architecture of the ESX server (the 4600). This was news to us and took about twenty minutes to convert the 8GB Windows vms and about an hour to convert the 33GB database file.
We started all three vms, did some Windows configuration and verified connectivity between the servers. TNSnames and an ODBC driver needed setup on the web server. The first large hurdle we encountered was that unlike our test system, the RHEL3 vm was not able to find its IP address via DHCP. After trying a few things, we assigned the address statically and the server then became available on the network. Once all three boxes were talking, we then verified that the website could pull data from the database. We did this; however, we saw that the database sequences were not created when we added an item to our cart. I got on the phone with our programmers and after about 45 minutes, resolved the problem using a public synonym. After this problem was solved, we spent a half an hour using the WSAT's recorder function to navigate the website and create the test cases. We were then able to start testing.
As our vendor did not have an Enterprise license for the ESX Server installation, we were limited to assigning up to four cpus per vm. So we assigned each vm the maximum available:
- Oracle vm: four cpus
- IIS vm: four cpus
- MS WSAT vm: four cpus
Since one CPU on the 4600 is dedicated to VMware overhead, this left three CPUs unused in the 4600.
We used MS WSAT to apply load to the Web server instance, slowly increasing load from one session to ten to one hundred virtual users in order to verify that:
1) the stress tool was working correctly,
2) the website was responding appropriately, and
3) we could see data via the VMware Virtual Infrastructure Client management app
We verified that these conditions were met.
It was interesting to view the VMware instrumentation. The VMware Infrastructure management app is a lot like Performance Monitor in Windows. You can view CPU/disk/memory and network stats. We toggled between the three vms and checked out performance stats for each. The most stressed vm was the IIS webserver, as it was serving data to the testing client (the Win2K server running MS WSAT), as well as pulling content from the database.
One interesting metric we saw in the management interface was called Megahertz Used, which is basically the percent of the total megahertz available to a vm. For example, if a vm has one 2.4Ghz cpu dedicated to it and that cpu is 10% busy, you're using 240Mhz of the available CPU power. On our Win2K3 web server vm, we had four cpus available at 2.4Ghz each. This gave us a total of about 10,000 megahertz available to the vm. When we increased the load to the Win2K3 web server, we saw that the webserver was using about 80-90% total CPU available or about 8,800Mhz of CPU. This load was more or less equally divided by the four CPUs assigned to the VM:
cpu0: 2300 mhz used
cpu1: 2200 mhz used
cpu2: 2200 mhz used
cpu3: 2100 mhz used
Utilizing the megahertz available to a vm, VMware is able to balances load to cpus within a vm as well as balance load between vms. ESX server 3.0 can dynamically provision new vms by analyzing this statistic.
Another interesting thing we did was to clone our testing server, the Win2K server with MS WSAT installed on it. As the clone is essentially a file copy, the process is i/o intensive and took about 10 minutes for the 8GB vm. With a configuration tweak and a quick start of the server, the cloned testing server was up and applying load against the website in 15 minutes total from start of clone to finish. Nice!
While testing, we found that the MS stress tool applies load, but has a nagging inability to capture enough information about a users' session so that an order can be completed through the test website. Also, the stress tool seems to quiesce after about 7-10 minutes. This may have been due to some caching on the database and web server layers, but is more likely due to a limitation with MS WSAT. So we are looking to replace this testing tool with one that doesn't have these limitations and can do interesting things like parameterize order and sku numbers in the requested URL. Compuware QALoad is a top candidate and one we're already licensed to have. We are currently researching tools for round 2 and hopefully, we'll have a substitute in the next couple of weeks.
In order to get a more full day of testing on the 4600, we will schedule a second visit to our vendor, with the caveat that I will bring a fully configured database, unzipped on an external USB drive in order to expedite the setup. Also, I hope to persuade the vendor to get an Enterprise license for ESX Server, so that we can assign more than four CPUs to an individual vm. Finally, at the end of the day, I will try to provide some screen shots or scripts of the evaluation session for the blog.
More to come..keep you posted!
Labels:
iis,
ms wsat,
oracle 10g,
rhel3,
stress tool,
sun 5310,
sun X4600M2,
vmware esx server
Thursday, April 26, 2007
Oracle 10G on RHEL3 quick install instructions
One of the more interesting things I've done lately is install Oracle 10G on RHEL3 Advanced Server. Actually, a virtual instance of RHEL3 running under VMware Server. Granted, it's an older version of RHEL, but since this was a development/test platform, our company had some install disks laying around and I decided to take the path of least resistance. The install guide for 10G on RHEL3 is here:
Oracle® Database Installation Guide, 10g Release 2 (10.2) for Linux x86
http://download-east.oracle.com/docs/cd/B19306_01/install.102/b15660/install_overview.htm
OK. So nothing is ever "quick" about an Oracle installation. Maybe I should have said "install synopsis" or something similar. But the point is that the instructions below are not a substitute for the full documentation above, but serve to remind me of what I did to get Oracle up and running. So here is the list of high-level steps and quick diagnostics for folks doing the same:
1) Prepping the operating system
- install RHEL3
- include compatibility libraries and GCC
- create oracle user
- create oinstall and dba groups
2) The oracle installation
- during the install, SYS/SYSTEM/DMSNMP/SYSMAN will get the same password by default
- to configure Enterprise Manager, execute dbca at the command line
3) OS tweaks
- as root, set ORACLE_HOME and ORACLE_SID environment variables
- as oracle, set ORACLE_BASE, ORACLE_HOME, ORACLE_SID environment variables
- as oracle, add ORACLE_HOME/bin to PATH
- set NLS_LANG environment variable
4) configure Oracle net svcs
- Modify the listener.ora file. Here is a sample:
LISTENER =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)
(HOST = oracletest.test.com)
(PORT = 1521) (QUEUESIZE =32)
)
)
- Modify the tnsnames.ora file. Here is a sample:
TEST.WORLD =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = oracletest)(PORT = 1521))
)
(CONNECT_DATA =
(SID = test)
(SERVER = DEDICATED)
)
)
5) Start the db
In SQL*Plus, as follows:
[oracle@oracletest oracle]$ sqlplus "/ AS SYSDBA"
Start the database:
SQL> STARTUP
Command to shutdown the database:
SQL> SHUTDOWN IMMEDIATE
6) start the listener
[oracle@oracletest oracle]$ lsnrctl start
LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 26-APR-2007 15:43:39
Copyright (c) 1991, 2005, Oracle. All rights reserved.
Starting /oracle/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 10.2.0.1.0 - Production
System parameter file is /oracle/network/admin/listener.ora
Log messages written to /oracle/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracletest.test.com)(PORT=1521)))
Connecting to (ADDRESS=(PROTOCOL=TCP)(HOST=oracletest.test.com)(PORT=1521)(QUEUESIZE=32))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 26-APR-2007 15:43:39
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle/network/admin/listener.ora
Listener Log File /oracle/network/log/listener.log
Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracletest.test.com)(PORT=1521)))
The listener supports no services
The command completed successfully
You can also use "status" or "stop" as arguments to the lsnrctl command:
lsnrctl [stop,start,status]
7) Starting the web based 10G Enterprise Manager database control
If you want to use the web based 10G Enterprise Manager database control, start it up:
[oracle@oracletest oracle]$ emctl start dbconsole
TZ set to US/Eastern
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.
http://oracletest.test.com:1158/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control .............. started.
------------------------------------------------------------------
Logs are generated in directory /oracle/oracletest.test.com_test/sysman/log
Login to the web based console: http://host:port/em
You may get a timezone mismatch. If so, check this out:
http://cacasodo.blogspot.com/2007/04/timezone-mismatch-agenttzregion-does.html
Verifying the database from a client
1) Verify the database listener is up and running
C:\WINDOWS>tnsping test
TNS Ping Utility for 32-bit Windows: Version 9.2.0.7.0 - Production on 23-APR-2007 11:54:19
Copyright (c) 1997 Oracle Corporation. All rights reserved.
Used parameter files:
C:\oracle9i\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = oracletest)(PORT = 1521))) (CONNECT_DATA = (SID = test) (SERVER = DEDICATED)))
OK (30 msec)
2) connection errors
a. You may get this error if you do not have a proper tnsnames entry for your database:
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:53:43 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:ORA-12505: TNS:listener could not resolve SID given in connect descriptor
Enter user-name: ^C
b. You may get this error if you are using the wrong user or password to connect to the database:
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:54:32 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:ORA-01017: invalid username/password; logon denied
Enter user-name: ^C
3) Successful connection.
If all is well, select SYSDATE from the DUAL table just to verify you can get data
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:55:12 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Connected to:Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining options
SQL> select sysdate from dual;
SYSDATE
---------------
26-APR-07
SQL> quit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining options
Other helpful commands
Finding your SID
First, check your environment settings..
[oracle@test]$ set grep SID
ORACLE_SID=test
Then login to oracle:
sqlplus sys as sysdba
SELECT instance_name
FROM v$instance;
Make sure your listener is up!
[oracle@test oracle]$ lsnrctl status
LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 26-OCT-2010 23:25:17
Copyright (c) 1991, 2005, Oracle. All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=TCP)(HOST=test.test.com)(PORT=1521)(QUEUESIZE=32))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 26-OCT-2010 23:15:19
Uptime 0 days 0 hr. 9 min. 58 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle/network/admin/listener.ora
Listener Log File /oracle/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=test.test.com)(PORT=1521)))
Services Summary...
Service "test" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
Service "testXDB" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
Service "test_XPT" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
The command completed successfully
Good luck!
TAG
References
http://forums.oracle.com/forums/thread.jspa?threadID=260359&tstart=60 http://forums.oracle.com/forums/thread.jspa?threadID=917370
Changing Oracle Enterprise Manager port numbers
Oracle Insert statements
Get list of constraints
Oracle® Database Installation Guide, 10g Release 2 (10.2) for Linux x86
http://download-east.oracle.com/docs/cd/B19306_01/install.102/b15660/install_overview.htm
OK. So nothing is ever "quick" about an Oracle installation. Maybe I should have said "install synopsis" or something similar. But the point is that the instructions below are not a substitute for the full documentation above, but serve to remind me of what I did to get Oracle up and running. So here is the list of high-level steps and quick diagnostics for folks doing the same:
1) Prepping the operating system
- install RHEL3
- include compatibility libraries and GCC
- create oracle user
- create oinstall and dba groups
2) The oracle installation
- during the install, SYS/SYSTEM/DMSNMP/SYSMAN will get the same password by default
- to configure Enterprise Manager, execute dbca at the command line
3) OS tweaks
- as root, set ORACLE_HOME and ORACLE_SID environment variables
- as oracle, set ORACLE_BASE, ORACLE_HOME, ORACLE_SID environment variables
- as oracle, add ORACLE_HOME/bin to PATH
- set NLS_LANG environment variable
4) configure Oracle net svcs
- Modify the listener.ora file. Here is a sample:
LISTENER =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)
(HOST = oracletest.test.com)
(PORT = 1521) (QUEUESIZE =32)
)
)
- Modify the tnsnames.ora file. Here is a sample:
TEST.WORLD =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = oracletest)(PORT = 1521))
)
(CONNECT_DATA =
(SID = test)
(SERVER = DEDICATED)
)
)
5) Start the db
In SQL*Plus, as follows:
[oracle@oracletest oracle]$ sqlplus "/ AS SYSDBA"
Start the database:
SQL> STARTUP
Command to shutdown the database:
SQL> SHUTDOWN IMMEDIATE
6) start the listener
[oracle@oracletest oracle]$ lsnrctl start
LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 26-APR-2007 15:43:39
Copyright (c) 1991, 2005, Oracle. All rights reserved.
Starting /oracle/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 10.2.0.1.0 - Production
System parameter file is /oracle/network/admin/listener.ora
Log messages written to /oracle/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracletest.test.com)(PORT=1521)))
Connecting to (ADDRESS=(PROTOCOL=TCP)(HOST=oracletest.test.com)(PORT=1521)(QUEUESIZE=32))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 26-APR-2007 15:43:39
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle/network/admin/listener.ora
Listener Log File /oracle/network/log/listener.log
Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracletest.test.com)(PORT=1521)))
The listener supports no services
The command completed successfully
You can also use "status" or "stop" as arguments to the lsnrctl command:
lsnrctl [stop,start,status]
7) Starting the web based 10G Enterprise Manager database control
If you want to use the web based 10G Enterprise Manager database control, start it up:
[oracle@oracletest oracle]$ emctl start dbconsole
TZ set to US/Eastern
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.
http://oracletest.test.com:1158/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control .............. started.
------------------------------------------------------------------
Logs are generated in directory /oracle/oracletest.test.com_test/sysman/log
Login to the web based console: http://host:port/em
You may get a timezone mismatch. If so, check this out:
http://cacasodo.blogspot.com/2007/04/timezone-mismatch-agenttzregion-does.html
Verifying the database from a client
1) Verify the database listener is up and running
C:\WINDOWS>tnsping test
TNS Ping Utility for 32-bit Windows: Version 9.2.0.7.0 - Production on 23-APR-2007 11:54:19
Copyright (c) 1997 Oracle Corporation. All rights reserved.
Used parameter files:
C:\oracle9i\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = oracletest)(PORT = 1521))) (CONNECT_DATA = (SID = test) (SERVER = DEDICATED)))
OK (30 msec)
2) connection errors
a. You may get this error if you do not have a proper tnsnames entry for your database:
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:53:43 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:ORA-12505: TNS:listener could not resolve SID given in connect descriptor
Enter user-name: ^C
b. You may get this error if you are using the wrong user or password to connect to the database:
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:54:32 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:ORA-01017: invalid username/password; logon denied
Enter user-name: ^C
3) Successful connection.
If all is well, select SYSDATE from the DUAL table just to verify you can get data
C:\WINDOWS>sqlplus web/web@test
SQL*Plus: Release 9.2.0.7.0 - Production on Mon Apr 23 11:55:12 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Connected to:Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining options
SQL> select sysdate from dual;
SYSDATE
---------------
26-APR-07
SQL> quit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining options
Other helpful commands
Finding your SID
First, check your environment settings..
[oracle@test]$ set grep SID
ORACLE_SID=test
Then login to oracle:
sqlplus sys as sysdba
SELECT instance_name
FROM v$instance;
Make sure your listener is up!
[oracle@test oracle]$ lsnrctl status
LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 26-OCT-2010 23:25:17
Copyright (c) 1991, 2005, Oracle. All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=TCP)(HOST=test.test.com)(PORT=1521)(QUEUESIZE=32))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 26-OCT-2010 23:15:19
Uptime 0 days 0 hr. 9 min. 58 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle/network/admin/listener.ora
Listener Log File /oracle/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=test.test.com)(PORT=1521)))
Services Summary...
Service "test" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
Service "testXDB" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
Service "test_XPT" has 1 instance(s).
Instance "test", status READY, has 1 handler(s) for this service...
The command completed successfully
Good luck!
TAG
References
http://forums.oracle.com/forums/thread.jspa?threadID=260359&tstart=60 http://forums.oracle.com/forums/thread.jspa?threadID=917370
Changing Oracle Enterprise Manager port numbers
Oracle Insert statements
Get list of constraints
Subscribe to:
Posts (Atom)
Feel free to drop me a line or ask me a question.