Category Archives: Drupal

A Simple Bash Script to Clone a Drupal Core GIT Repository

This is a simple bash script used to clone a Drupal Core GIT repository locally when passed a branch number and a new directory name (to host the Drupal repo). I use the issue number as the directory to keep Drupal API documentation patches coordinated with the issue number.

To execute the script, copy and past the commands in the code block into a text editor then save the script as (e.g.

Run from a bash prompt (in the same directory) by typing: sh

Drupal on Windows: Using SQL Server Merge Replication

In my first “Drupal on Windows” blog post, I wrote about using Windows authentication with SQL Server. That’s a recommended best practice for SQL Server in any production environment. So with the knowledge that Drupal can run on Windows technologies in a production environment, how can we scale Drupal to achieve high availability? How do we move beyond a single web farm?

One solution is:

  • Geographically dispersed web farms using Global Load Balancing
    • Each web farm resides in it’s own data center
    • Each web farm utilizes it’s own SQL Server instance
  • SQL Server Merge Replication
    • Keep the database in each web farm in sync, so the served content is identical

SQL Server Merge Replication

Setting up merge replication (and global load balancing) is beyond the scope of this blog post, but there are lots of great instructions out there. I would recommend the following reading for those not familiar with merge replication: Continue reading Drupal on Windows: Using SQL Server Merge Replication

Drupal on Windows: Using Windows Authentication with SQL Server

With the release of Drupal 7, it became easy to run the whole Drupal stack on Windows technologies. Instead of requiring a LAMP stack (Linux, Apache, MySQL, PHP), you now have the option of a WISP stack (Windows, IIS, SQL Server, PHP). The excellent Drupal 7 driver for SQL server makes using a SQL Server backend with Drupal possible. Even better, the underlying PDO (PHP Data Objects) driver for SQL Server supports Windows authentication! But wait… there are no instructions provided on using Windows authentication to SQL Server with Drupal! I knew that in theory it should be possible. After some tweaking, I finally figured it out. So how do you set it up? Here are the missing instructions…

Getting Windows Authentication working with SQL Server

Before you start, you will need either:

  • A domain user account, with both web server and SQL server joined to the domain
  • Identical user accounts on both servers (same username and password); in this case the servers do not need to be joined to a domain

In my example below, I will use the identical user accounts method. Omit step 1 and substitute your domain account information wherever step 1 is referenced if you want to use the domain account method. Continue reading Drupal on Windows: Using Windows Authentication with SQL Server