pcj icon indicating copy to clipboard operation
pcj copied to clipboard

Can't open heap error

Open chuxiuhong opened this issue 6 years ago • 1 comments

I run my code as follow:

import lib.util.persistent.*;
public class Main {
    public static void main(String[] args) {
        PersistentArray<PersistentString> string = new PersistentArray<>(100);
        ObjectDirectory.put("data",string);
        string.set(0,new PersistentString("hello"));
        System.out.println(string.get(0));
    }
}

then raise error: Opening heap... Encountered error opening pool! Please check if /home/ziqi/pmemdir exists and accessible.

I can use pmdk in C project with the path "/home/ziqi/pmemdir". _006

OS:Ubuntu 14.04 memory:16G(8G for emulate persistent memory) The permission of /home/ziqi/pmemdir is 777

chuxiuhong avatar Apr 26 '18 04:04 chuxiuhong

Hi chuxiuhong,

Thanks for trying out PCJ! Can you please double check the "path" setting in your config.properties file?

If you are using emulated persistent memory, the "path" should be set to a file inside the emulated file system, not the mount point itself. You can provide any filename that you'd like and PCJ will automatically create the file for you (e.g. /home/ziqi/pmemdir/persistent_heap).

Please let us know if this resolves your issue.

Thanks, Lei

leifan89 avatar Apr 26 '18 19:04 leifan89