Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
by Faith A
This quick guide will show you how to create an package (compressed file) of a Web site, and then restore the site from the package.
This guide requires the following prerequisites:
- .NET Framework 2.0 SP1 or greater
- Web Deployment Tool 1.1
Note: If you have not already installed the Web Deployment Tool, see Installing Web Deploy.
To create a package, run the following command:
msdeploy.exe -verb:sync -source:metakey=lm/w3svc/1 -dest:package=c:\dws.zip > DWSpackage6.log
To restore the package, run the following command:
msdeploy.exe -verb:sync -source:package=c:\dws.zip -dest:metakey=lm/w3svc/1 > DWSpackage6.log
To create a package, run the following command:
msdeploy.exe -verb:sync -source:apphostconfig="Default Web Site" -dest:package=c:\dws.zip > DWSpackage7.log
To restore the package, run the following command:
msdeploy.exe -verb:sync -source:package=c:\dws.zip -dest:apphostconfig="Default Web Site" > DWSpackage7.log
If you need to package a second directory outside the scope of your Web site, or you want to include other sites or objects, you have two options:
- Package each of them separately
- Create a manifest file to package multiple paths (see Using Custom Manifests)
You have now created a package of a Web site, and restored the site from the package. This is useful if you need to revert to a prior version of the site, or if files have become corrupt or missing from the site's content directory.