Open dockerwang opened 7 years ago
The same error for me, It is not related to the OS apparently
I found out what was the problem. Apparently you should do the following 1- change the name of the example ( no idea why but if you keep the name the simulation will give you the same output no matter what) 2- go to the method (createContainerCloudletList) 3- the main problem is the path extraction in this line String inputFolderName = ContainerCloudSimExample1.class.getClassLoader().getResource("workload/planetlab").getPath();
since there is a jar file in the path this line gives, it keeps getting null indicating no folder is there, so what i did is I extracted the jar file named cloudsim-examples-4.0.jar, and just put my path written like this String inputFolderName = "/home/alex/Documents/JarsforCloudsim/Cloudsim/cloudsim-examples-4.0/workload/planetlab"; and that fixed the problem
please if any of you worked on coludsim container, could you please help me ?
The same problem for me and my environment is windows 10. Thanks a lot @alexander989 , it works for me.
I found out what was the problem. Apparently you should do the following 1- change the name of the example ( no idea why but if you keep the name the simulation will give you the same output no matter what) 2- go to the method (createContainerCloudletList) 3- the main problem is the path extraction in this line String inputFolderName = ContainerCloudSimExample1.class.getClassLoader().getResource("workload/planetlab").getPath();
since there is a jar file in the path this line gives, it keeps getting null indicating no folder is there, so what i did is I extracted the jar file named cloudsim-examples-4.0.jar, and just put my path written like this String inputFolderName = "/home/alex/Documents/JarsforCloudsim/Cloudsim/cloudsim-examples-4.0/workload/planetlab"; and that fixed the problem
Hello alex please explain clearly how to set this path
D:\cloudsim-4.0\cloudsim-4.0\jars>java -classpath cloudsim-4.0.jar;cl oudsim-examples-4.0.jar org.cloudbus.cloudsim.examples.container.ContainerCloudS imExample1 Starting ContainerCloudSimExample1... Initialising... java.lang.NullPointerException at org.cloudbus.cloudsim.examples.container.ContainerCloudSimExample1.cr eateContainerCloudletList(ContainerCloudSimExample1.java:419) at org.cloudbus.cloudsim.examples.container.ContainerCloudSimExample1.ma in(ContainerCloudSimExample1.java:158) Unwanted errors happen