Process process;
//String rsync="/usr/bin/rsync -arp "+imageSaveTrue+" "+imageRead;
String rsync="cp "+imageSave+SMALL_IMAGE_SIGN+fileNameAll+" "+imageRead+"/upload/";
logger.info("同步命令"+rsync);
process=Runtime.getRuntime().exec(rsync);
InputStream os = process.getInputStream();
BufferedReader br = new BufferedReader(
new InputStreamReader(os));
String line = "";
while ((line = br.readLine()) != null) {
logger.info(line);
}
logger.info(" rsync end");
时间: 2024-10-10 21:42:18