Archive for oracle

Shared SCSI Storage with VMWare Server 2.0 and OCFS

Posted in Computación with tags , , , , , , , on 19/October/2010 by Alex Pérez

(An update over the same trick with VMWare Server 1.X)

VMWare Server was declared End Of Availability on Jan/2010, while VMWare is pushing to use Player, ESX(i), vCenter, vSphere and all the “formerly known as” product names. I think that VMWare Server series are a great software, but v2.0 was sentenced to death since:

The King is dead. Long live the King.

Well, let’s see a recipe for configuring a shared SCSI bus + OCFS2 with VMWare Server 2.0.

I will use a turnkey Linux appliance in this test, because it has a very simple startup menu for configuring IP address and it’s debian based (apt-get!). Continue reading

Advertisements

Indexing NULL column values

Posted in Computación with tags , , , , , , , , on 1/August/2010 by Alex Pérez

After reading some great articles from Burleson Consulting about the “is null/is not null” predicates I decided to make some additional tests. It’s a very common mistake to write SQL with this kind of predicates since the NULL values aren’t included in regular indexes (B*Tree, not function-based), so almost every “IS NULL” results in a TABLE FULL SCAN.

I want to test how much a index can improve a IS [NOT] NULL predicate measuring the #requests per minute that a legacy box can serve. In the old days this server was a mission-critical server, but nowadays is retired as test server and can be compared to a very low end box (P3-512M ram).
Well, I measure the time that the select statement takes to execute (using JMeter)  instead of cost because a 30% reduction cost does not mean a 30% time reduction, and usually the end-user speak in terms of time, and there are many “tricks” like moving a table to the KEEP_POOL that can speed-up SQL execution although the cost is the same.
Continue reading

Using JMeter to test JDBC databases

Posted in Computación with tags , , , , , , , on 17/April/2010 by Alex Pérez

Despite JMeter is a well-known load testing tool when testing web projects, it seems to be unused when testing SQL performance. So I decided to share how to configure a fairly simple SQL test plan involving only one SQL statement.

Download Apache JMeter and Java, if you don’t have them already.

Get a copy of the oracle driver (ojdbc14.jar) or a JDBC driver of your preferred DB, and throw it into the JMETER_HOME/lib directory

  • Open JMeter and create a test plan as shown in fig1. Based on this plan you can complicate it as you want to load your DB and fit it to your needs. There are two JMeter Listeners (red) called “Aggregate Report” and “Summary Report” that will report us some statistical results like mean, median, throughput among others. I recommend you to use the Statistical Aggregate Report listener. Inside the thread group (blue) are two items of type “JDBC Connection Configuration” and “JDBC Request”. As we will see, is where we define the DB connection properties (user, password, driver, IP, SID), and the statement we want to test. Continue reading

Installing oracle instant client on Linux

Posted in Computación with tags , , , , , , , on 20/July/2009 by Alex Pérez

This is a miniguide to install sqlplus with the minimal oracle-software fingerprint. As far as I can, I avoid to install the Oracle Client in my computers, because in MS Windows it modifies heavily the registry, and in linux you should set a lot of environment variables and deal with Oracle Universal Installer (OUI) that depends on many packages, versions, java … etc. And there is a better solution to install a simple sqlplus without installing the whole Oracle Client: oracle instant client.

I’ve used the 10.2.0.4 version, but I suppose that using any other 10.X or even 11.X version should be similar. Continue reading

Shared SCSI Storage with VMWare Server 1.X and OCFS

Posted in Computación with tags , , , , , on 22/April/2009 by Alex Pérez

Sometimes, when testing software while a pilot test with virtual machines you need to emulate a SAN or setup some kind of shared storage between all nodes. I remember that some (old?) versions of VMWare products allowed SCSI controller to be shared between some nodes, and thus all the devices attached to this SCSI controller are accesible to all nodes: simple and neat. Perhaps that was an option only with VMWare Workstation, or ESX …

VMWare Logo

Free VMWare products -at least VMWare Server 1.0.X- can do the same despite it’s a bit tricky. Along this post I will explain how to setup this kind of shared storage between a group of VM. I’m using a CentOS 5.2 VM because it’s Linux and it’s 99.9% compatible with it’s RHEL counterpart that you can find at your favourite production environment. So, for this test I used the CentOS available at bagside that I found at the VMWare Appliances MarketPlace. Continue reading