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>(); }
public bool Initialize(ProxyTaskInfo ptI) { if (!Directory.Exists(sysfsRoot)) { return(false); } return(true); }
public bool Initialize(ProxyTaskInfo ptI) { if (ptI.Node == null || ptI.Hypervisor == null) { return(false); } proxyInfo = ptI; vmwh = new VMWareHandler(); vmwh.LogEvent += new EventHandler <LogEventArgs>(this.LogReceivedEvent); vddk = new VDDK.VDDK(Environment.OSVersion.Platform == PlatformID.Unix); vddk.LogEvent += new EventHandler <LogEventArgs>(this.LogReceivedEvent); //new VDDK.LogHandler(this.LogReceived); // Force log to be suscribed to if (this.LogEvent == null) { throw new Exception("Must suscribe to LogEvent"); } return(true); }
/// <summary> /// Gets the storage layout. If rootStoragePaths is NULL, returns layout of the local system. Else, treat /// rootStoragePaths as locally accessible loop disks and scan them /// </summary> /// <returns> /// The storage layout. /// </returns> /// <param name='rootStoragePaths'> /// Root storage paths. /// </param> internal StorageLayout BuildStorageLayout(string physicalDisksProviderName, ProxyTaskInfo proxyingInfo) { discoverer = StorageLayoutFactory.Create(physicalDisksProviderName); if (discoverer == null || !discoverer.Initialize(proxyingInfo)) { //Logger.Append(Severity.ERROR, "Could not initialize storage layout manager '"+physicalDisksProviderName+"'"); throw new Exception("Could not initialize storage layout manager '" + physicalDisksProviderName + "'"); } discoverer.LogEvent += this.LogReceivedEvent; Logger.Append(Severity.INFO, "Building storage layout using provider '" + discoverer.Name + "'..."); layout = (discoverer.BuildStorageLayout()); Console.WriteLine(" BuildStorageLayout() ---- is layout complete? " + layout.IsComplete()); Logger.Append(Severity.INFO, "Got " + layout.Entries.Count + " disks from storage layout provider"); FinishBuildDisksLinux(); return(layout); }
/*public SPOProvider (){ * }*/ public static ISpecialObject GetByCategory(string objectName, Backup backup, P2PBackup.Common.BackupLevel level, ProxyTaskInfo pti) { /*switch(objectName){ * case "VSS": * return new VSS(level); * case "VMWare VM configuration": * return new VMWareVmConfig(pti); * case "StorageLayout": * return new StorageLayoutSPO(backup.StorageLayout); * * default: * throw new Exception("No Special object matching category '"+objectName+"'");*/ return((ISpecialObject)Activator.CreateInstance(PluginsDiscoverer.Instance().Plugins[objectName].RawType)); }
public bool Initialize(ProxyTaskInfo ptI) { return(true); }
public bool Initialize(ProxyTaskInfo ptI) { openHandles = new List <IntPtr>(); return(true); }