Solved

save website configuration to file from command line

Posted on 2007-04-07
9
240 Views
Last Modified: 2010-04-20
I'm looking for a way to save a website configuration to file from command line. Or a way to import a specific site from the metabase as a different name. I need a way to backup one site from IIS and restore it in the same IIS as a different name.
0
Comment
Question by:josgan
  • 4
  • 4
9 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 18871915
you got a M$ system which is designed to work without input devices, oops, at least without a keyboard ... ;-) IIRC there is no way to export the configuration except using regdump or something like that.
0
 
LVL 34

Expert Comment

by:Dave_Dietz
ID: 18872926
What version of IIS are you running?

Dave Dietz
0
 

Author Comment

by:josgan
ID: 18873070
IIS 6
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 34

Expert Comment

by:Dave_Dietz
ID: 18873098
IISCNFG.VBS can do what you're looking for.

There is good documentation for it if you search in the IIS help files, or you can try running 'iiscnfg.vbs /export /?' from a command line for usage parameters.

You would then use the /import flag to take the saved data and red it back into the Metabase and you can specify a different destination than the path that was saved from.

Dave Dietz
0
 

Author Comment

by:josgan
ID: 18875999
From all the docs i'm reading it says that yes it is possible to do just parts of the metabase, but it doesn't show how.
0
 
LVL 34

Accepted Solution

by:
Dave_Dietz earned 500 total points
ID: 18877200
If you want to back up just the default web site you would do the following:

iiscnfg.vbs /export /f site.xml /sp /lm/w3svc/1 /children

To import this as a site with identifier '2' you would use the following:

iiscnfg.vbs /import /f site.xml /sp /lm/w3svc/1 /dp /lm/w3svc/2 /children

Dave Dietz
0
 

Author Comment

by:josgan
ID: 18877296
do the sites go in that order inside the manager? The site listed first is 1, the site listed second is number 2 and so on?
0
 
LVL 34

Expert Comment

by:Dave_Dietz
ID: 18877462
I believe the sites are listed in order of creation (the order they appear in the Metabase).

The sites are appended to the Metabase and are not arranged in any special order.

You can simply click on the 'Web Sites' entry in the IIS MMC and look at the Identifier column to see which identifier to use for exporting and which ones *not* to use for importing.....  :-)

Dave Dietz
0
 

Author Comment

by:josgan
ID: 18877557
thanks loads. I was looking in the metabase backups for the ident. Yours' is a ton more explainable.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
Lync server 2013 or Skype for business Backup Service Error ID 4049 – After File Share Migration
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question