Ejemplo n.º 1
0
 public StorageLayoutSPO(P2PBackup.Common.Volumes.StorageLayout layout)
 {
     this.RestorePosition    = RestoreOrder.BeforeStorage;
     this.layout             = layout;
     this.BasePaths          = new List <BasePath>();   // unused , but initialize it anyway
     this.ExplodedComponents = new List <string>();
 }
Ejemplo n.º 2
0
 public VMWareVmConfig(ProxyTaskInfo pti)
 {
     this.RestorePosition    = RestoreOrder.BeforeStorage;
     this.pti                = pti;
     this.BasePaths          = new List <BasePath>();   // unused , but initialize it anyway
     this.ExplodedComponents = new List <string>();
 }
Ejemplo n.º 3
0
Archivo: VSS.cs Proyecto: radtek/BackO
        public VSS(BackupLevel level)
        {
            this.RestorePosition    = RestoreOrder.AfterStorage;
            this.ExplodedComponents = new List <string>();
            Metadata  = new SPOMetadata();
            BasePaths = new List <BasePath>();
            IVssImplementation vss = VssUtils.LoadImplementation();

            backup = vss.CreateVssBackupComponents();
            //Logger.Append(Severity.DEBUG, "0/6 Initializing Snapshot ("+ ((BasePaths == null)? "NON-component mode" : "component mode")+")");
            backup.InitializeForBackup(null);
            VssBackupType vssLevel = VssBackupType.Full;

            if (level == BackupLevel.Full)
            {
                vssLevel = VssBackupType.Full;
            }
            else if (level == BackupLevel.Refresh)
            {
                vssLevel = VssBackupType.Incremental;
            }

            /*	else if (level == BackupLevel.Differential)
             *                      vssLevel = VssBackupType.Differential;*/
            else if (level == BackupLevel.TransactionLog)
            {
                vssLevel = VssBackupType.Log;
            }
            //if(spoPaths == null) // component-less snapshot set
            //		backup.SetBackupState(false, true, VssBackupType.Full, false);
            //else
            backup.SetBackupState(true, true, vssLevel, false);
            if (OperatingSystemInfo.IsAtLeast(OSVersionName.WindowsServer2003))
            {
                // The only context supported on Windows XP is VssSnapshotContext.Backup
                backup.SetContext(VssSnapshotContext.AppRollback);
            }
            //Logger.Append(Severity.DEBUG, "1/6 Gathering writers metadata and status");
            using (IVssAsync async = backup.GatherWriterMetadata()){
                async.Wait();
                async.Dispose();
            }
            // gather writers status before adding backup set components
            using (IVssAsync async = backup.GatherWriterStatus()){
                async.Wait();
                async.Dispose();
            }
        }
Ejemplo n.º 4
0
 public SpecialObjectPluginSkeletton()
 {
     this.RestorePosition    = RestoreOrder.AfterStorage;
     this.BasePaths          = new List <BasePath>();   // initialize it even if unused
     this.ExplodedComponents = new List <string>();     // initialize it even if unused
 }