I am running a spark job: And the command gives an error: Invalid maximum heap size: -Xmx4g –jars Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred. Program will exit. I checked memory: So, it seems to be fine. I checked java: Then I checked in Chrome whether spark is running at ai-grisnodedev1:7077 and it does