1

I am writing a Java code to unzip a zip file in my RedHat env. Please see below:-

    String tempRestoreDirPath=/tmp
Process p;
    p = Runtime.getRuntime().exec("unzip -o " + tempRestoreDirPath + "/" + "backup_*.zip" + " -d " + tempRestoreDirPath + "/");
    p.waitFor();

The unzip command is working fine when there is few files in the zip to unzip.But when there is more than 50 files,the command just hangs and does not proceed.When i check the unzip dir,I can see that it has unzipped first 10 files after that the files are not unzipped.

I think that there is issue with Memory.Can anyone please help me who has faced similar issue.

iftekhar khan
  • 178
  • 12

0 Answers0