Exemplo n.º 1
0
 public asyncExecutionResultViaFile(remoteExecution host, execFileSet fileSet)
 {
     _host               = host;
     _stdOutFilename     = fileSet.stdOutFilename;
     _stdErrFilename     = fileSet.stdErrFilename;
     _returnCodeFilename = fileSet.returnCodeFilename;
 }
Exemplo n.º 2
0
        protected hypervisor_vmware_withoutSnapshots(hypSpec_vmware spec, clientExecutionMethod newExecMethod = clientExecutionMethod.vmwaretools)
        {
            _spec = spec;

            VClient = new cachedVIMClientConnection(_spec);

            _executionMethod = newExecMethod;
            switch (newExecMethod)
            {
            case clientExecutionMethod.vmwaretools:
                executor = new vmwareRemoteExecutor(spec, VClient);
                break;

            case clientExecutionMethod.smbWithPSExec:
                executor = new SMBExecutorWithPSExec(spec.kernelDebugIPOrHostname, spec.kernelVMUsername, spec.kernelVMPassword);
                break;

            case clientExecutionMethod.smbWithWMI:
                executor = new SMBExecutor(spec.kernelDebugIPOrHostname, spec.kernelVMUsername, spec.kernelVMPassword);
                break;

            case clientExecutionMethod.SSHToBASH:
                executor = new SSHExecutor(spec.kernelDebugIPOrHostname, spec.kernelVMUsername, spec.kernelVMPassword);
                break;

            default:
                throw new ArgumentOutOfRangeException("newExecMethod", newExecMethod, null);
            }
        }
Exemplo n.º 3
0
 public asyncExecutionResultViaFile(remoteExecution host, string stdOutFilename, string stdErrFilename, string returnCodeFilename)
 {
     _host               = host;
     _stdOutFilename     = stdOutFilename;
     _stdErrFilename     = stdErrFilename;
     _returnCodeFilename = returnCodeFilename;
 }
Exemplo n.º 4
0
        public hypervisor_iLo(hypSpec_iLo spec, clientExecutionMethod newExecMethod = clientExecutionMethod.smbWithPSExec)
        {
            _spec = spec;
            lock (_ilos)
            {
                if (!_ilos.ContainsKey(spec.iLoHostname))
                {
                    _ilos.Add(spec.iLoHostname, new refCount <hypervisor_iLo_HTTP>(new hypervisor_iLo_HTTP(spec.iLoHostname, spec.iLoUsername, spec.iLoPassword)));
                }
                else
                {
                    _ilos[spec.iLoHostname].addRef();
                }
            }

            if (_spec.iscsiserverIP != null && _spec.iscsiServerUsername != null && _spec.iscsiServerPassword != null)
            {
                theNas = FreeNasGroup.getOrMake(_spec.iscsiserverIP, _spec.iscsiServerUsername, _spec.iscsiServerPassword);
            }

            if (newExecMethod == clientExecutionMethod.smbWithPSExec)
            {
                _executor = new SMBExecutorWithPSExec(spec.kernelDebugIPOrHostname, spec.hostUsername, spec.hostPassword);
            }
            else if (newExecMethod == clientExecutionMethod.smbWithWMI)
            {
                _executor = new SMBExecutor(spec.kernelDebugIPOrHostname, spec.hostUsername, spec.hostPassword);
            }
            else if (newExecMethod == clientExecutionMethod.vmwaretools)
            {
                throw new NotSupportedException();
            }
            else if (newExecMethod == clientExecutionMethod.SSHToBASH)
            {
                _executor = new SSHExecutor(spec.kernelDebugIPOrHostname, spec.hostUsername, spec.hostPassword);
            }
        }