Tuesday 11 March 2014

SAN storage basics

One of the customers I work with had poor storage performance on his database server. This customer uses the database to run a transaction host and experiences volumes of tens of millions of transactions per month.

His transaction host back-end is an Oracle 11g database running on Windows Server 2003, and uses a SAN for storage.

This customer's database performance reports have been consistently highlighting poor i/o throughput and excessive virtual memory paging.

Therefore, I decided to take a closer look at SANs and understand how they work. This article tries to put together a few basic points about SAN storage technology collected during that study.

SANs are specialized high performance, high capacity network-based storage solutions, and require specialized hardware and software to work. 

Sometimes, the incorrect configuration of SANs or their components can cause performance and availability problems, so its good for a DBA/Solution Architect to know a bit how they work.

Below, are some basic points related to SANs which could be useful to have in mind when faced with SAN storage performance problems. 

# What is the manufacturer/model of host bus adapter (HBA) cards installed on the database server.

HBAs are are cards which slot into the database server. They do the TCP to Fiber channel protocol conversion, and enable the client (database server) to talk to the SAN, which only understands Fiber-channel protocol. 

Fiber-channel protocol basically consists of SCSI disk management commands transmitted over the fiber-channel network, on fiber-optic cables. Data is transmitted as a laser signal instead of electric signals.


# What is the capacity of the installed HBA in terms of Mbits/Gbits per second. 

Perhaps this could be compared to the numbers in the AWR report's load profile section.

# Check how many such adapters cards are installed on database server and whether all are functional.  

If one HBA is not functional the other ones may have to do process extra traffic, depending on how the HBAs are configured.

# What is the model and capacity (in Mbits/Gbits per second) of the SAN Fiber Channel switch installed, if using a fiber channel switch.

A  fiber-channel switch is much like an ethernet switch, except it links fiber-channel devices and networks instead of ethernet networks. 

For example, the database server may be hooked up to a fiber-channel switch, which in turn hooks up to the storage array.

# How many fiber-channel ports are available on the switch? 
More ports may mean potentially more servers attached to those ports, demanding more IO services from the SAN, increasing the load on the SAN.


# Check whether the SAN environment is using fiber channel hub rather than a switch, what are hub's Mbits/second numbers.

Fiber-channel hubs were used before switches were introduced, but today, they would be rare. They are analogous to ethernet hubs, and only one device can communicate at a time, while the others wait for their turn.

# If using a fiber-channel hub, check whether other servers than the database server also use the disk array - they would need to queue up to use the hub.

# Check the rated capacity of disk array in Mbits per second.

# Get the the number of disks in disk array.

# Get the Raid configuration created, if any, on disk array.

The RAID configuration created will have an impact on the read/write performance. 

# Get a network diagram showing all the connections.

Database server <--> any ethernet switches <---> san switch/hub <---> disk array.

Try to determine how many network hops there are from database server to storage disk - fewer the better.

# Determine whether any patch panels employed in creation/configuration of SAN network.

Patch panels join two fiber optic cable together, and if the geometric center of the cables are not aligned well, then these panels may become a source of signal loss.

# Check the estimated length of fiber optic cable running from database server host bus adapter to SAN fiber channel switch and from there on to storage array. 

Depending on the nature of the fiber-optic cable used, there are limits on how long a fiber optic cable can transmit without signal loss. 
  
# Check if there are any issues in the optic cable like > 90 degree bends or pinches in the wiring ?

Optic fiber cables are very sensitive to pinches, sharp bends and will suffer signal loss if subjected to physical stresses, this may be worth checking.

# Check, whether the disk array come with a cache ? What is it's size ?

# Check whether the SAN has any continuous data protection/other high availablity features enabled?

# Check whether all the SAN components - the database server host bus adapter, the fiber-channel switch, and the disk array  all communicate at same speed or not ? 

If not, the storage network will only function as fast as the slowest     component in it.
    
# Check whether the host bus adapter driver software on the database server the correct and recommended ones


Application database usage is a far more frequent cause of db performance problems. But, the above information could help to understand the storage environment better and identify bottlenecks which may exist in the SAN configuration.




No comments:

Post a Comment