SQL Clone
Author: c | 2025-04-24
SQL Clone Server –the machine on which you install SQL Clone. It runs the SQL Clone service, which coordinates the actions of SQL Clone Agents, and hosts the SQL Clone
SQL Clone Documentation - SQL Clone 5 - Product
Products All products Redgate Flyway Redgate Monitor Redgate Test Data Manager SQL Toolbelt Essentials SQL SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test .NET .NET Developer Bundle .NET Reflector ANTS Performance Profiler ANTS Memory Profiler SmartAssembly All products .NET Developer Bundle .NET Reflector ANTS Memory Profiler ANTS Performance Profiler Data Compare for Oracle Data Masker Redgate Flyway Redgate Test Data Manager Schema Compare for Oracle SmartAssembly Source Control for Oracle SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test SQL Toolbelt Essentials Solutions Overview By Need Standardize Protect Automate Monitor By Role Development Operations IT Management Enterprise leadership By Industry Tech U.S. Federal Australian Government Healthcare Managed Service Providers (MSP) Case studies Insights Our Company Overview Careers Contact us Redgate blog Newsroom Leadership Support Learning & community Learning & community | Redgate Hub Product articles University Events Forums Community Simple Talk Buy now See all products Request a quote Contact sales My account Shopping cart Products All products Redgate Flyway Redgate Monitor Redgate Test Data Manager SQL Toolbelt Essentials SQL SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test .NET .NET Developer Bundle .NET Reflector ANTS Performance Profiler ANTS Memory Profiler SmartAssembly All products .NET Developer Bundle .NET Reflector ANTS Memory Profiler ANTS Performance Profiler Data Compare for Oracle Data Masker Redgate Flyway Redgate Test Data Manager Schema Compare for Oracle SmartAssembly Source Control for Oracle SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate
Getting Started with SQL Clone - Resources - SQL Clone
We will be using the cmdlets to connect to SQL Clone, set the locations of the Image and any clones, and the naming convention. The PowerShell code in Listing 1 provides the basis of the overall provisioning process, into which we can integrate our chosen data masking workflow. # Connect to SQL Clone Server Connect-SqlClone -ServerUrl 'YOUR CLONE SERVER ADDRESS AND PORT HERE' # Set variables for Image and Clone Location $SqlServerInstance = Get-SqlCloneSqlServerInstance -MachineName 'YOUR MACHINE NAME HERE' -InstanceName 'YOUR INSTANCE NAME HERE' $ImageDestination = Get-SqlCloneImageLocation -Path 'YOUR FILESHARE HERE' # Set names for developers to receive Clones $Devs = @("Chris", "Sam", "Cassi", "Becky", "Matt") # Create New Image New-SqlCloneImage -Name 'AdventureWorksImage' -SqlServerInstance $SqlServerInstance -DatabaseName 'AdventureWorks_Production' -Destination $ImageDestination | Wait-SqlCloneOperation $Image = Get-SqlCloneImage -Name 'AdventureWorksImage' # Create New Clones for Devs $Devs | ForEach-Object { # note - '{' needs to be on same line as 'foreach' ! $Image | New-SqlClone -Name "AdventureWorks_Dev_$_" -Location $SqlServerInstance | Wait-SqlCloneOperation } Listing 1a. Choose the data masking workflowIt is at this point you can implement your chosen workflow for masking. There are two basic approaches, either deploy all clones from a masked image (using method 1 or 3 below), or deploy unmasked clones and then mask them (method 2):Apply masking to a clone, create a masked image from the clone In this scheme, we create a temporary image (either from the database or a backup), create a clone from this image, apply the masking to the clone, create a new masked image, then drop the temporary image and clone. In other words, we deploy all clones from a masked image. This keeps everything within SQL Clone, and has fewer system dependencies (such as having to rely on a backup/restore process to complete first).Use the New-SqlCloneImage and New-SqlClone cmdlets within SQL Clone to create your temp environment for masking.Mask each clone individuallyHere, we simply apply the masking to each individual clone, by calling Data Masker and passing in the details of the server on which each clone resides (example shown in Listing 3). This approach minimizes the time impact of creating new imagesWhat is SQL Clone? - SQL Clone 5 - Product
SQL Server databases.The key to understanding how these tools can work together lies within PowerShell; SQL Clone has a full set of cmdlets that allow you to create and remove images and clones, and Data Masker’s command-line interface can be called as part of this process. To set up the provisioning and masking process through PowerShell, follow these steps:1. Discover and classify the dataComplete your own internal due diligence to discover what data you’re going to be providing to your teams and classify this data – What data is the most sensitive? Where is it? Which data elements could be used to personally identify the data subject (either by itself or by correlation with other data), or to place that subject at a specific place at a certain time? Based on this, figure out what level of masking or data removal/generation you need for the various classifications of data in your database.2. Establish the data protection rules using Data MaskerFeed this information into Data Masker for SQL Server. Data Masker allows you to predefine different types of rules (such as substitution or shuffle) on how each column and row should be anonymized. These rules run in sequence (or concurrently based on your rule dependencies) and form your masking set, which should be created in line with the columns and rows of data you have discovered in your tables.In the following example, I am using a simple substitution rule in my masking set to replace the title, first name, middle name and last name in the Person table of the AdventureWorks database.The substitution rule is specified by selecting the columns from the table to be masked and then selecting the correct data set (pre-populated in Data Masker or user-defined) to replace them with substitution values.Figure 1Figure 2 shows the substitution rule, as it appears in the masking set. Triggers are disabled, the substitution rule is run against Person.Person and, once masking is completed, triggers are re-enabled.Figure 23. Automate database provisioning with PowerShell and SQL CloneWe use the PowerShell cmdlets with SQL Clone to set up a basic provisioning process.For this example,. SQL Clone Server –the machine on which you install SQL Clone. It runs the SQL Clone service, which coordinates the actions of SQL Clone Agents, and hosts the SQL Clone SQL Clone Server –the machine on which you install SQL Clone. It runs the SQL Clone service, which coordinates the actions of SQL Clone Agents, and hosts the SQL CloneInstalling the SQL Clone server - SQL Clone 5 - Redgate
But of course also means the image is unmasked.Create a masked image from a masked databaseWe can create a PowerShell script that will restore a database backup, and mask the new database. We create a masked image from this database and so, by extension, masked clones, and then drop the temporary database when finished. You might wish to use this approach instead if you have an existing backup and restore process to create (for example) a staging environment.Use the Restore-SqlDatabase and $server.databases["mydb"].Drop() commands to drop the temporary DB when finished.b. Apply the data maskingIn this step, we pass the database or clone into Data Masker for SQL Server, to apply our masking scheme. We use the command line functionality within the tool as part of your PowerShell job.For Data Masker to run via the command line, the user with permissions to do so must be logged in or must schedule via Windows scheduler to run with permissions.The command in Listing 2 applies the masking set we created previously. The output is written to out-null so that the operation can finish before the script attempts to do anything else. #Mask Temp Clone from Data Masker Command Line & "C:\Program Files\Red Gate\Data Masker for SQL Server\DataMasker.exe" "C:[…]\Documents\Example1.DMSSet" -R -X | out-null Listing 2If you are using either of the approaches that applies the masking to a clone (1 or 2), then you will need to pass the clone name to use into this command also by using the -D argument which will replace the database specified in your existing masking set.In Listing 3, I specified AdventureWorks_Dev_Chris (a full database backup and restore) in the masking set but want the rules to run against AdventureWorks_Dev_Simon (the clone) instead. # Mask Temp Clone & "C:\Program Files\Red Gate\Data Masker for SQL Server\DataMasker.exe" "C:\[…]\Documents\Example1.DMSSet" -R -D "YOURMACHINE\YOURINSTANCE[AdventureWorks_Dev_Chris] = YOURMACHINE\YOURINSTANCE[AdventureWorks_Temp]" -X | out-null Listing 3If you are using approach 3, you will be able to specify the name of the restored Database in the masking set and call this without the -D argument.Listing 4 shows a full example of a masking process in PowerShell, with SQL CloneWhat is SQL Clone? - SQL Clone 5 - Product Documentation
Many variables as possible. Is the issue caused by some special characteristic of the data, in production? One way to prove or disprove this is to capture a data set from the production environment and load it into testing or development environments. With the data in test and development matching as closely as possible what’s present in production, the team will also be able to flush out many data-related bugs much earlier in development, and will gain confidence that their test results will reflect the behavior observed on deploying their changes to production.This is all fine if you’re working with public data, but what if some tables contain data that is personal, identifiable, or is in some other way sensitive or private? Either you need to generate that data, rather than copy it, or you need a data masking or obfuscation strategy, which will prevent unauthorized access of this data, by replacing, anonymizing or removing sensitive pieces of information.However, if you need to copy several terabytes of data to each of the required test and development servers by restoring a backup, while also sanitizing any personal and sensitive information, by running data cleansing scripts, then your database provisioning process will be long, slow and require a large amount of extra storage space.Using SQL Clone and Data Masker for SQL Server, you can provision copies of production data, quickly, while still protecting personal and sensitive information.SQL Clone allows you to rapidly spin up copies of a database, for development and testing purposes. It creates one image, which is a point-in-time representation of your source SQL Server database, and from this image you can create many database copies, or clones. Each clone takes up only tens of megabytes of disk space, and creating each clone takes seconds, rather than hours (see Getting started with SQL Clone for more details of how this works).Data Masker for SQL Server allows you to set up a set of ‘masking rules’ to apply to any PII and PHI in your database. It also allows you to synchronize these changes between tables, across servers and even betweenWhat is SQL Clone - Resources - SQL Clone - Redgate Software
Now with rFactor (created by the... Category: Games / SimulationsPublisher: Cars & Tracks Development Project, License: Freeware, Price: USD $0.00, File Size: 202.8 MBPlatform: Windows Create titles, professional credits, cinemalike trailers, animated itineraries and stunning videowall-Effects with 2D & 3D, sensational. By forgoing the overall complex key frames with a extreme easy handling! Plugins for most actual NLEs available!! Everything the editor's heart desires! Exclusive fade-ins, subtitles, crawls also in 3D - Clever fade-ins with unique effects - professional credits - multimedia trailers created from a mixture of photos, videos and titles - impressive video walls with hundreds of parallel video sources - Visualising itineraries with moving objects on pathes - DVD-Menue-backgrounds... Category: Multimedia & DesignPublisher: proDAD GmbH, License: Demo, Price: USD $199.00, File Size: 34.7 MBPlatform: Windows Moyo Go Studio is an incredible application. Moyo Go Studio is an incredible application. Move the mouse over the board and immediately, Moyo Go shows games with the same patterns in the context of your own game. Moyo Go Studio is a powerful pattern analysis program, very useful for joseki, fuseki and shape. Category: Home & Education / MiscellaneousPublisher: moyogo, License: Freeware, Price: USD $0.00, File Size: 313.0 MBPlatform: Windows NewBlue Art Effects lends visual pizzazz to your video production. NewBlue Art Effects lends visual pizzazz to your video production. This powerful collection of 100 effects in 10 specialized video filters shifts your video into a visually stunning alternate reality. Using the amazing NewBlue Art Effects, you can easily create a scene that will look as if it were hammered out of metal or convert your video image into hand-drawn art. ... Category: Multimedia & Design / Digital Media EditorsPublisher: NewBlue, Inc, License: Shareware, Price: USD $139.95, File Size: 37.0 MBPlatform: Windows DVD Clone Studio: backup your favorite DVD movies. DVD Clone Studio: backup your favorite DVD movies. Complete backup of DVD movies: With DVD Clone Studio, you can back up an entire movie - including menus, trailers and special features. Some of our customers have complained about the difficulty they had copying DVDs, and this urged us to develop this software DVD Clone Studio. It is easy to use, easy to install, and... Category: Multimedia & Design / VideoPublisher: Ronald Tomlinson, License: Shareware, Price: USD $59.95, File Size: 2.2 MBPlatform: Unknown SQL Optimizer for Visual Studio seamlessly integrates with Visual Studio. SQL Optimizer for Visual Studio seamlessly integrates with Visual Studio. As part of the development process, it automatically identifies, rewrites and validates SQL statements to ensure SQL runs as fast as possible for immediate deployment. Easy to install and easy to use, SQL Optimizer for Visual Studio allows you to improve your productivity, shorten application delivery... Category: Software Development / Components & LibrariesPublisher: Quest Software, License: Shareware, Price: USD $199.00, File Size: 12.3 MBPlatform: Windows Tasktop for Visual Studio brings Eclipse Mylyn's task list and connectors into the Microsoft Visual Studio IDE. Tasktop for Visual Studio brings Eclipse Mylyn's task list and connectors into the Microsoft Visual Studio IDE. The. SQL Clone Server –the machine on which you install SQL Clone. It runs the SQL Clone service, which coordinates the actions of SQL Clone Agents, and hosts the SQL Clone SQL Clone Server –the machine on which you install SQL Clone. It runs the SQL Clone service, which coordinates the actions of SQL Clone Agents, and hosts the SQL CloneComments
Products All products Redgate Flyway Redgate Monitor Redgate Test Data Manager SQL Toolbelt Essentials SQL SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test .NET .NET Developer Bundle .NET Reflector ANTS Performance Profiler ANTS Memory Profiler SmartAssembly All products .NET Developer Bundle .NET Reflector ANTS Memory Profiler ANTS Performance Profiler Data Compare for Oracle Data Masker Redgate Flyway Redgate Test Data Manager Schema Compare for Oracle SmartAssembly Source Control for Oracle SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test SQL Toolbelt Essentials Solutions Overview By Need Standardize Protect Automate Monitor By Role Development Operations IT Management Enterprise leadership By Industry Tech U.S. Federal Australian Government Healthcare Managed Service Providers (MSP) Case studies Insights Our Company Overview Careers Contact us Redgate blog Newsroom Leadership Support Learning & community Learning & community | Redgate Hub Product articles University Events Forums Community Simple Talk Buy now See all products Request a quote Contact sales My account Shopping cart Products All products Redgate Flyway Redgate Monitor Redgate Test Data Manager SQL Toolbelt Essentials SQL SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate Monitor SQL Multi Script SQL Prompt SQL Provision SQL Scripts Manager SQL Search SQL Source Control SQL Test .NET .NET Developer Bundle .NET Reflector ANTS Performance Profiler ANTS Memory Profiler SmartAssembly All products .NET Developer Bundle .NET Reflector ANTS Memory Profiler ANTS Performance Profiler Data Compare for Oracle Data Masker Redgate Flyway Redgate Test Data Manager Schema Compare for Oracle SmartAssembly Source Control for Oracle SQL Backup SQL Clone SQL Compare SQL Data Catalog SQL Data Compare SQL Data Generator SQL Dependency Tracker SQL Doc SQL Index Manager Redgate
2025-04-14We will be using the cmdlets to connect to SQL Clone, set the locations of the Image and any clones, and the naming convention. The PowerShell code in Listing 1 provides the basis of the overall provisioning process, into which we can integrate our chosen data masking workflow. # Connect to SQL Clone Server Connect-SqlClone -ServerUrl 'YOUR CLONE SERVER ADDRESS AND PORT HERE' # Set variables for Image and Clone Location $SqlServerInstance = Get-SqlCloneSqlServerInstance -MachineName 'YOUR MACHINE NAME HERE' -InstanceName 'YOUR INSTANCE NAME HERE' $ImageDestination = Get-SqlCloneImageLocation -Path 'YOUR FILESHARE HERE' # Set names for developers to receive Clones $Devs = @("Chris", "Sam", "Cassi", "Becky", "Matt") # Create New Image New-SqlCloneImage -Name 'AdventureWorksImage' -SqlServerInstance $SqlServerInstance -DatabaseName 'AdventureWorks_Production' -Destination $ImageDestination | Wait-SqlCloneOperation $Image = Get-SqlCloneImage -Name 'AdventureWorksImage' # Create New Clones for Devs $Devs | ForEach-Object { # note - '{' needs to be on same line as 'foreach' ! $Image | New-SqlClone -Name "AdventureWorks_Dev_$_" -Location $SqlServerInstance | Wait-SqlCloneOperation } Listing 1a. Choose the data masking workflowIt is at this point you can implement your chosen workflow for masking. There are two basic approaches, either deploy all clones from a masked image (using method 1 or 3 below), or deploy unmasked clones and then mask them (method 2):Apply masking to a clone, create a masked image from the clone In this scheme, we create a temporary image (either from the database or a backup), create a clone from this image, apply the masking to the clone, create a new masked image, then drop the temporary image and clone. In other words, we deploy all clones from a masked image. This keeps everything within SQL Clone, and has fewer system dependencies (such as having to rely on a backup/restore process to complete first).Use the New-SqlCloneImage and New-SqlClone cmdlets within SQL Clone to create your temp environment for masking.Mask each clone individuallyHere, we simply apply the masking to each individual clone, by calling Data Masker and passing in the details of the server on which each clone resides (example shown in Listing 3). This approach minimizes the time impact of creating new images
2025-03-31But of course also means the image is unmasked.Create a masked image from a masked databaseWe can create a PowerShell script that will restore a database backup, and mask the new database. We create a masked image from this database and so, by extension, masked clones, and then drop the temporary database when finished. You might wish to use this approach instead if you have an existing backup and restore process to create (for example) a staging environment.Use the Restore-SqlDatabase and $server.databases["mydb"].Drop() commands to drop the temporary DB when finished.b. Apply the data maskingIn this step, we pass the database or clone into Data Masker for SQL Server, to apply our masking scheme. We use the command line functionality within the tool as part of your PowerShell job.For Data Masker to run via the command line, the user with permissions to do so must be logged in or must schedule via Windows scheduler to run with permissions.The command in Listing 2 applies the masking set we created previously. The output is written to out-null so that the operation can finish before the script attempts to do anything else. #Mask Temp Clone from Data Masker Command Line & "C:\Program Files\Red Gate\Data Masker for SQL Server\DataMasker.exe" "C:[…]\Documents\Example1.DMSSet" -R -X | out-null Listing 2If you are using either of the approaches that applies the masking to a clone (1 or 2), then you will need to pass the clone name to use into this command also by using the -D argument which will replace the database specified in your existing masking set.In Listing 3, I specified AdventureWorks_Dev_Chris (a full database backup and restore) in the masking set but want the rules to run against AdventureWorks_Dev_Simon (the clone) instead. # Mask Temp Clone & "C:\Program Files\Red Gate\Data Masker for SQL Server\DataMasker.exe" "C:\[…]\Documents\Example1.DMSSet" -R -D "YOURMACHINE\YOURINSTANCE[AdventureWorks_Dev_Chris] = YOURMACHINE\YOURINSTANCE[AdventureWorks_Temp]" -X | out-null Listing 3If you are using approach 3, you will be able to specify the name of the restored Database in the masking set and call this without the -D argument.Listing 4 shows a full example of a masking process in PowerShell, with SQL Clone
2025-04-05Many variables as possible. Is the issue caused by some special characteristic of the data, in production? One way to prove or disprove this is to capture a data set from the production environment and load it into testing or development environments. With the data in test and development matching as closely as possible what’s present in production, the team will also be able to flush out many data-related bugs much earlier in development, and will gain confidence that their test results will reflect the behavior observed on deploying their changes to production.This is all fine if you’re working with public data, but what if some tables contain data that is personal, identifiable, or is in some other way sensitive or private? Either you need to generate that data, rather than copy it, or you need a data masking or obfuscation strategy, which will prevent unauthorized access of this data, by replacing, anonymizing or removing sensitive pieces of information.However, if you need to copy several terabytes of data to each of the required test and development servers by restoring a backup, while also sanitizing any personal and sensitive information, by running data cleansing scripts, then your database provisioning process will be long, slow and require a large amount of extra storage space.Using SQL Clone and Data Masker for SQL Server, you can provision copies of production data, quickly, while still protecting personal and sensitive information.SQL Clone allows you to rapidly spin up copies of a database, for development and testing purposes. It creates one image, which is a point-in-time representation of your source SQL Server database, and from this image you can create many database copies, or clones. Each clone takes up only tens of megabytes of disk space, and creating each clone takes seconds, rather than hours (see Getting started with SQL Clone for more details of how this works).Data Masker for SQL Server allows you to set up a set of ‘masking rules’ to apply to any PII and PHI in your database. It also allows you to synchronize these changes between tables, across servers and even between
2025-04-23