package org.zstack.storage.fusionstor;

import org.zstack.header.core.Completion;
import org.zstack.utils.ssh.Ssh;

/**
 * Created by frank on 7/27/2015.
 */
public abstract class FusionstorMonBase {
    protected FusionstorMonAO self;

    public abstract void connect(Completion completion);

    public FusionstorMonBase(FusionstorMonAO self) {
        this.self = self;
    }

    protected void checkTools() {
        Ssh ssh = new Ssh();
        ssh.setHostname(self.getHostname()).setUsername(self.getSshUsername()).setPassword(self.getSshPassword())
                .checkTool("/opt/fusionstor/lich/bin/lich", "/opt/fusionstor/lich/sbin/lichd").runErrorByExceptionAndClose();
    }

    public FusionstorMonAO getSelf() {
        return self;
    }
}

@@ -608,26 +608,27 @@
 opt/fusionst
-or
+ack
 /lich/bin/li
@@ -646,18 +646,19 @@
 fusionst
-or
+ack
 /lich/sb

update path