Archive for March 2014

TSQL: Table count per filegroup

Here’s a query that uses the SQL Server System Catalog Views to return a table count per table. I used this to check even table distribution in a data warehouse. ?View Code TSQLSELECT AS filegroup_name, COUNT(DISTINCT t.[object_id]) AS table_count FROM sys.tables t INNER JOIN sys.indexes i ON t.[object_id] = i.[object_id] AND i.is_primary_key = 1 INNER […]

CentOS: clvmd startup timed out

I received the following error, on CentOS 6.5, when configuring a High Availability cluster. This also cause the computer to freeze on the os boot. clvmd startup timed out The fix was found here and involved an edit of /etc/lvm/lvm.conf. This required a minor change to the library_dir line as the location of these libraries […]

The database cannot be recovered because the log was not restored

A test restore of a SQL Server database had somehow been left in the “RESTORING” state. I attempted to bring the database online with ?View Code TSQLRESTORE DATABASE db_name; But I was greeted with… Msg 4333, Level 16, State 1, Line 1 The database cannot be recovered because the log was not restored. Msg 3013, […]

Adding ISCSI volumes to the nodes

This post is part of a series that will deal with setting up a MySQL shared storage cluster using VirtualBox & FreeNAS. In this post we deal with the setup of an iscsi volume on two nodes. The text in bold below represent commands to be executed in the shell. yum install iscsi-initiator-utils iscsiadm -m […]

Linux Cluster Node Configuration

Linux Node1 In VirtualBox, Node1 > Settings > Network. Adapters 1, 2 & 3 should be enabled and set to “Bridged Adapter”. Start the Linux VM to boot CentOS. Login as root. Execute the below command… ?View Code BASHifconfig -a | grep eth[0-9] You should see interfaces eth0, eth1 & eth2. Run the command system-config-network-tui […]