Windows IT Pro is the authoritative and independent resource for windows nt, windows 2000, windows 2003, windows xp. Features a collection of resources and magazines for windows IT professionals.
  
  
  Advanced Search 


June 2007

Making Sense of Volume Shadow Copy Service

Spend time now to enable VSS—save time later when users need to recover files
RSS
Subscribe to Windows IT Pro | See More Backup and Recovery Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!
SideBar    5 Keys to VSS

If you need to recover a file that's been deleted, you obviously can't right-click the file in the shared folder and select its properties. In this case, you need to work at the folder level. Instead of connecting to the UNC path \\Uptowndc\Sales, you'd connect to the administrative share of the C drive (which is where the Sales folder resides): \\Uptowndc\C$. Right-click the Sales folder, select Properties, and click the appropriate button to view, copy, or restore the entire contents of the folder. If you're interested in only one file, copy the folder to a new location, then right-click the file and work with that file's previous versions.

Vista and Shadow Copies
Vista is the first desktop OS with built-in shadow copy capabilities. In Vista, shadow copies are part of System Restore and are called restore points. Restore points are enabled by default for the C volume, so right out of the gate you get shadow copies of your files daily, as long as the volume has at least 300MB of free space.

The default scheduled task that creates restore points is called SR, and it runs only when the computer has been idle for 10 minutes or more and is on AC power. If for some reason the SR task fails to run at its scheduled time, it will run as soon as possible. You can also enable restore points for other volumes if you choose. Vista uses up to 15 percent of available hard disk space for storing restore points.

To configure and manage restore points, click the Start orb and right-click Computer, then choose Properties; on the Tasks menu select System protection. Accessing System protection requires administrative privileges, so when prompted by the User Account Control UI, choose Continue.

On the System Protection tab of the System Properties page, which Figure 3 shows, you can manually create a one-time restore point by selecting the volume and clicking Create, naming the restore point, and clicking Create again. The process can take a few minutes, depending on the size of your volume, but when it's finished you get a message confirming success. If you choose to enable automatic restore points for a volume, Vista creates a new restore point for that volume every day and at system startup time.

Accessing previous versions of files and folders on Vista is performed in the same manner as accessing them through a shared folder on Windows 2003 from a client that has the Previous Versions Client application installed. But Vista lets you access the previous versions of files and folders locally. Simply open Windows Explorer, right-click the file or folder you want, select Properties, then click the Previous Versions tab, which Figure 4 shows. The options are the same on Vista as they are for the earlier Previous Versions Client, and they work the same way.

VSS and SANs
Another cool feature of VSS on Windows Server 2003 Enterprise Edition and Datacenter Edition is the ability to quickly and easily copy and move data on a SAN. VSS can create a shadow copy of a multi-terabyte volume that you can then export from a SAN and import to a server in a matter of minutes, thereby transferring a large amount of data very quickly. Every storage vendor sets up this capability differently, so contact your vendor for details.

VSS Configuration
For volumes with VSS enabled, I recommend you configure 16KB or larger cluster sizes. VSS tracks changes to files in 16KB blocks. On volumes that are from 2GB to 2TB in size, 4KB is the default cluster size. But on clusters smaller than 16KB, the VSS provider can't determine whether a file has been defragmented or changed. So VSS treats a defragmented file as it does a changed file—it generates a new shadow copy of the file. After defragmentation of a disk that has small clusters, VSS might cause the shadow copy cache to grow very quickly and overwrite all existing shadow copies. (For more information, see the Microsoft article "Shadow copies may be lost when you defragment a volume" at http://support.microsoft.com/kb/312067.)

To find the cluster size on a volume, you can use the Fsutil command. For example, to find the cluster size for volume C, you'd type the following at a command prompt:

fsutil fsinfo ntfsinfo C: 

If your cluster size is smaller than 16KB and you want to increase it, you need to back up your data, reformat the volume with a larger cluster size, then restore your data. Be aware that NTFS compression works only with 4KB cluster sizes, so you might need to decide whether compression or VSS is more important in your environment.

How NTBackup and VSS Work Together
In the past, if a file was open or locked by a service or application while a backup was being performed, the locked or open file wasn't backed up, causing problems when administrators needed to restore that file. Data consistency is paramount when it comes to applications that require many files to be open at the same time, such as databases. When multiple files are open during a backup, it's possible that between the time that the first and last file is backed up, changes might have occurred in the last file. So when the database is restored, the data is no longer in a consistent state.

Windows 2003's backup utility, NTBackup, uses VSS to ensure that backups are consistent and complete. VSS works in conjunction with a piece of code, called a writer, from a file's application. A writer protects the application's data and provides information such as the location of the data and the backup and restore methods available. Applications that don't contain a writer are not VSS aware. Administrators need to know whether their applications are VSS-aware. In a worst-case scenario, an administrator might try to restore an important file and discover it's not even there—it never got backed up because the application wasn't VSS aware. Windows 2003 includes writers for AD and NTFS. To find all available writers on a server, type the following at a command prompt:

vssadmin list writers 

When you run NTBackup in Windows 2003, the utility requests a list of all writers that VSS is aware of. VSS not only lists the writers, but also provides all known metadata about the writers, such as each writer's backup and restore methods. VSS uses the metadata to determine which applications support shadow copies. When NTBackup asks VSS to create a shadow copy, VSS sends a message to the known writers to freeze all data writes, create a shadow copy, and store it in a difference file. A difference file keeps track of what has changed or is different since the last shadow copy was created. Then VSS lets the writer continue its write operations. The backup is performed using the data in the difference file.

   Previous  1  [2]  3  Next 


Reader Comments
Exactly how does one use the VSS service to duplicate a SAN volume to another LUN?

Tobias Schmidt June 15, 2007 (Article Rating: )


You must log on before posting a comment.

If you don't have a username & password, please register now.




Learning Path To learn more about Volume Shadow Copy Service (VSS)
"What's the Windows Server 2003 Volume Shadow Copy Service (VSS)?"

"Volume Shadow Copy Service"


Top Viewed ArticlesView all articles
Command Prompt Tricks

One reader shares his tip for setting up the command prompt to reflect a remote path. ...

New Microsoft/Yahoo! Deal? No

On Sunday, the Times of London reported that Microsoft had renewed talks with failing Internet giant Yahoo! and would manage its search engine for 10 years, while Yahoo! would retain control of its email, messaging, and content services. This report ...

How can I stop and start services from the command line?

...


Storage Whitepapers Combining Deduplication and VMware Disaster Recovery: Cascading Savings Improves Cost Effectiveness

Virtualizing Microsoft Exchange Server 2007

StoreVault SnapManagers for Microsoft Exchange and SQL Server

Related Events Storage Consolidation for Your Microsoft Applications: Reducing Cost and Complexity

SQL Server 2008 – Can You Wait? | Philadelphia

Virtualization, Automation and Databases

Check out our list of Free Email Newsletters!

Storage eBooks A Guide to Windows Certification and Public Keys

SQL Server Administration for Oracle DBAs

Keeping Your Business Safe from Attack: Encryption and Certificate Services

Related Storage Resources Become a VIP member of the Windows IT Pro community!
Get it all with the VIP CD and VIP access. A $500+ value for only $279!

Subscribe to Windows IT Pro!
Solve your toughest technical problems with our experts and access 10,000 + articles online. 30% off

Monthly Online Pass - Only $5.95!
Get instant access to 10,000+ articles from Windows IT Pro Magazine!

TechNet Virtual Labs
Evaluate and test Microsoft's newest products.


Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro Windows Dev Pro IT Job Hound ITTV
IT Library Technology Resource Directory Connected Home Windows Excavator Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 Copyright © 2008 Penton Media, Inc., All rights reserved. Terms and Use | Privacy Statement | Reprints and Licensing