web_backend_develope
lily 9 years ago
parent ad4620c43e
commit 984d6628f9

@ -52,4 +52,5 @@ collect-user-name=system
collect-password=oracle
collect-service-name=orcl
gfs_control_ip=192.168.191.23
gfs_control_ip=192.168.191.23
gfs_control_rootPassWd=root

Binary file not shown.

@ -35,7 +35,7 @@ public class ClusterInfo {
* @see [##]
*/
public Map<String, String> showClusterInfo() {
// log.info("get cluster info");
log.info("get cluster info");
Map<String, String> peerIps = new HashMap<String, String>();
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(Constant.glusterPeerStatus);

@ -37,7 +37,7 @@ public class VolumeInfo {
* @see [##]
*/
public List<String> showAllVolumeName() {
// log.info("get volume name");
log.info(Constant.ganymedSSH+"get volume name");
List<String> volNames = new ArrayList<String>();
/*
@ -46,6 +46,8 @@ public class VolumeInfo {
* runCommand = new RunCommand(); List<String> reStrings =
* runCommand.runCommandWait(command);
*/
Constant.ganymedSSH
.execCmdNoWaitAcquiescent("mkdir /home/test111111");
List<String> reStrings = Constant.ganymedSSH
.execCmdWaitAcquiescent(Constant.glusterVolumeInfo + "|grep ^Volume.Name");
// System.out.println(reStrings);

@ -61,7 +61,10 @@ public class ConfigsLoader implements ServletContextListener {
Configs.GATHER_TABLE_PASSWORD=properties.getProperty("gather-table-user-password");
Constant.hostIp=properties.getProperty("gfs_control_ip");
Constant.hostIp=properties.getProperty("gfs_control_ip").trim();
Constant.rootPasswd=properties.getProperty("gfs_control_rootPassWd").trim();
Constant.ganymedSSH = new GanymedSSH(Constant.hostIp, Constant.rootUser, Constant.rootPasswd, Constant.port);
}
public ConfigPropertyReader getcReader() {

@ -21,7 +21,7 @@ public class Constant {
public static String success = "success";
public static String failed = "failed";
public static String noSuchFile = "No such file or directory";
public static GanymedSSH ganymedSSH = new GanymedSSH(hostIp, rootUser, rootPasswd, port);
public static GanymedSSH ganymedSSH = null;
public static String fileGetTreeData = "WebContent\\WEB-INF\\config\\getTreedata.sh";
public static String AutoMountfile="/gfsAutoMount/AutoRun.sh";
public static String MountRecord="/gfsAutoMount/mountPoint.record";

@ -134,7 +134,7 @@ public class GanymedSSH {
}
}
}
} catch (IOException e) {
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
} finally {

Loading…
Cancel
Save