111 lines
4.7 KiB
HTML
111 lines
4.7 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=Windows-1252">
|
|
<TITLE>Restore</TITLE>
|
|
<SCRIPT LANGUAGE="JavaScript">
|
|
<!--
|
|
TempString = navigator.appVersion
|
|
if (navigator.appName == "Microsoft Internet Explorer"){
|
|
// Check to see if browser is Microsoft
|
|
if (TempString.indexOf ("4.") >= 0){
|
|
// Check to see if it is IE 4
|
|
document.writeln('<link rel="stylesheet" type="text/css" href="/iishelp/common/coua.css">');
|
|
}
|
|
else {
|
|
document.writeln('<link rel="stylesheet" type="text/css" href="/iishelp/common/cocss.css">');
|
|
}
|
|
}
|
|
else if (navigator.appName == "Netscape") {
|
|
// Check to see if browser is Netscape
|
|
document.writeln('<link rel="stylesheet" type="text/css" href="/iishelp/common/coua.css">');
|
|
}
|
|
else
|
|
document.writeln('<link rel="stylesheet" type="text/css" href="/iishelp/common/cocss.css">');
|
|
//-->
|
|
</script>
|
|
<SCRIPT LANGUAGE="VBScript">
|
|
<!--
|
|
Sub Window_OnLoad()
|
|
Dim frmContents
|
|
On Error Resume Next
|
|
If Not Parent Is Nothing Then
|
|
Set frmContents = Parent.Contents
|
|
If Not frmContents Is Nothing Then
|
|
frmContents.Window.TOCSynch_Click
|
|
End If
|
|
End If
|
|
End Sub
|
|
//--></SCRIPT><META NAME="DESCRIPTION" CONTENT="Internet Information Services reference information">
|
|
<META HTTP-EQUIV="PICS-Label" CONTENT='(PICS-1.1 "<http://www.rsac.org/ratingsv01.html>" l comment "RSACi North America Server" by "inet@microsoft.com <mailto:inet@microsoft.com>" r (n 0 s 0 v 0 l 0))'>
|
|
<META NAME="MS.LOCALE" CONTENT="EN-US">
|
|
<META NAME="MS-IT-LOC" Content="Internet Information Services">
|
|
</HEAD>
|
|
|
|
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
|
|
|
|
<H3><A NAME="_k2_restore"></A><SUP></SUP>Restore</H3>
|
|
|
|
<P>You can use the <B>Restore</B> method of the <A HREF="/iishelp/iis/htm/asp/aore2xpu.htm"><B>IIsComputer</B></A> object to restore the metabase from a backup. The restore operation stops all services dependent on IISADMIN, including all servers, until the restore has completed, then restarts all services. Because of this, if you are restoring the metabase by using a script in an ASP page, you must specify a machine name other than the one on which your script is executing. You cannot use LocalHost as the machine name. You should be careful to plan for this service interruption when restoring the metabase from a backup.</P>
|
|
|
|
<H6>Syntax</H6>
|
|
|
|
<P><B>IIsComputer</B>.<B>Restore</B> <I>BackupLocation</I>, <I>BackupVersion</I>, <I>BackupFlags</I> </P>
|
|
|
|
<P> </P>
|
|
|
|
<H6>Parameters</H6>
|
|
|
|
<DL>
|
|
<DT><I>BackupLocation</I></DT>
|
|
|
|
<DD>A string of up to 100 characters that specifies the backup location. If an empty string is specified, the backup will be retrieved from the default location.<BR>
|
|
</DD>
|
|
|
|
<DT><I>BackupVersion</I></DT>
|
|
|
|
<DD>Specifies the version number of the backup to be restored from the backup location, or can be the following constant.
|
|
|
|
<TABLE border=0 cellpadding=5 cols=2 frame=box rules=cols>
|
|
|
|
<TR VALIGN="top">
|
|
<TD width=50%><B>MD_BACKUP_HIGHEST_VERSION</B></TD>
|
|
<TD width=50%>Restore from the highest existing backup version in the specified backup location.</TD>
|
|
</TR>
|
|
</TABLE><BR>
|
|
|
|
<BR>
|
|
</DD>
|
|
|
|
<DT><I>BackupFlags</I></DT>
|
|
|
|
<DD>Reserved. Must be zero.</DD>
|
|
</DL>
|
|
|
|
<H6>Code Example</H6>
|
|
|
|
<PRE><CODE><%
|
|
Dim ComputerObj, ComputerName
|
|
'Restore metabase on a different computer.
|
|
ComputerName = "MyOtherComputer"
|
|
'You can use LocalHost if running under Windows Script Host.
|
|
Set ComputerObj = GetObject("IIS://" & ComputerName)
|
|
'Restore the highest number version in MyBackups.
|
|
ComputerObj.Restore "MyBackups", MD_BACKUP_HIGHEST_VERSION, 0
|
|
%>
|
|
</CODE></PRE>
|
|
|
|
<H6>Remarks</H6>
|
|
|
|
<P>You can use the <B>Restore</B> method with LocalHost in scripts running in a command window by using Cscript.exe. For more information, see the Windows Script Host material in the Windows documentation.</P>
|
|
|
|
<P><span class=le><B>Important </B></span>The metabase backup and restore functionality exists for versioning purposes, not for cross-machine replication. However, you are not necessarily restricted to restoring the computer from which you initiate the process. For more information about restoring from a back up, see "Restoring the Metabase" in the IIS product documentation.</P>
|
|
|
|
<H6>See Also</H6>
|
|
|
|
<P><A HREF="/iishelp/iis/htm/asp/aore32cw.htm"><B>Backup</B></A>, <A HREF="/iishelp/iis/htm/asp/aore1v8z.htm"><B>EnumBackups</B></A>, <A HREF="/iishelp/iis/htm/asp/aore79rk.htm"><B>DeleteBackup</B></A></P>
|
|
<hr class="iis" size="1">
|
|
<p align="center"><em><a href="../../../common/colegal.htm">© 1997-2001 Microsoft Corporation. All rights reserved.</a></em></p>
|
|
</BODY>
|
|
</HTML>
|