Error while installing spark - hadoop

I am trying to install spark in windows 8.1 and getting below error.
C:>cd Program Files\spark-1.5.0\bin
C:\Program Files\spark-1.5.0\bin>spark-shell
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
C:\Program Files\spark-1.5.0\bin>
and done prerequisites,please refer below commands,
C:\Users\Anbu>java -version
java version "1.8.0_65"
Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.65-b01, mixed mode)
C:\Users\Anbu>scala -version
Scala code runner version 2.11.8 -- Copyright 2002-2016, LAMP/EPFL
C:\Users\Anbu>
set the system properties also.
so where i missed? why this error coming?
Any one please help me to install spark.
Thanks,
Anbu k

It seems you downloaded source code package of Spark.
For installations you need built package of Spark. You can download pre-built package of Spark from Sparks's downloads page by choosing a specific package type(as shown in below image). So download pre-built package and check the installation. It should work.

Related

Why I couldn't run same installed app on IDE integrated terminal even I could run on default terminal

I just switch to try develop on Linux for a while.
But one thing I couldn't understand how to solve it, as I mentioned in topic.
I'm going to develop a project that need Java SDK, then I installed the SDK with command:
#bash
sudo apt install openjdk-17-jdk-headless
After installation finished, I could run command java -version and javac -version to see the result of installation and it looks OK.
openjdk version "17.0.3" 2022-04-19
OpenJDK Runtime Environment (build 17.0.3+7-Ubuntu-0ubuntu0.22.04.1)
OpenJDK 64-Bit Server VM (build 17.0.3+7-Ubuntu-0ubuntu0.22.04.1, mixed mode, sharing)
And then when I open IDE (Intellij IDEA) and it has feature of integrated terminal. (see picture)
But when I try to test java -version it was shown the error:
bash: java: command not found
As you can see from picture, I run java -version on terminal it return output properly, but when I run the same command java -version, it output with error message, like it couldn't find the java SDK that I installed.
Could anyone help me to describe the reason and solutions to solve the issue?
P.S. This is same on VS Codium.
I found the answer.
Solution:
Install the IDE app with the file from official website instead of using package manager of OS.
Description:
The cause is I installed the IDE via Package Manager of OS (here I'm using Pop_OS, install via Pop!_Shop)
And its package manager has some strict rules for security purpose.
I'm not sure, Pop_OS using which package manager, but I'll raise Flatpak as reference: https://docs.flatpak.org/en/latest/sandbox-permissions.html
And on blacklisted directories, my installed java command is under /usr/bin/ which is in blacklist.

databricks-connect not working on windows

I've installed databricks-connect on Windows 10 with the instructions here: https://docs.databricks.com/dev-tools/databricks-connect.html
After running databricks-connect configure and entering all values, i'm running databricks-connect test. This is the output I'm getting, and it hangs:
* PySpark is installed at c:\users\user\.conda\envs\myenv\lib\site-packages\pyspark
* Checking SPARK_HOME
* Checking java version
java version "1.8.0_251"
Java(TM) SE Runtime Environment (build 1.8.0_251-b08)
Java HotSpot(TM) 64-Bit Server VM (build 25.251-b08, mixed mode)
* Skipping scala command test on Windows
* Testing python command
The system cannot find the path specified.
Digging a bit deeper, it seems that the underlying pyspark package fails to initialize. It fails on this line:
from pyspark.sql import SparkSession
spark = SparkSession.builder.getOrCreate()
When I try to run this manually, it hangs. I guess this is a problem is either the local Spark or the required Hadoop (and winutils.exe) installations, but databricks-connect requires a fresh pyspark installation (doc says to uninstall pyspark prior to installation).
Would be happy for any references for:
Fixing the databricks-connect issue
Fixing the underlying pyspark installation issue

Error installing eclipse (jvm.dll load error) - how to fix?

I am trying to install Eclipse inside a virtual machine running Windows 7 64-bit.
When I launch eclipse-inst-win64.exe, I get the following error: Failed to load the JNI shared library "C:\Program Files\Java\jdk-12.0.2\bin\server\jvm.dll.
Both eclipse and JDK are 64-bit.
The DLL is there:
c:\>dir "c:\Program Files\Java\jdk-12.0.2\bin\server\jvm.dll"
Volume in drive C has no label.
Volume Serial Number is 8E3B-94B
Directory of c:\Program Files\Java\jdk-12.0.2\bin\server
07/27/2019 04:47 PM 11,538,912 jvm.dll
Java is 64-bit:
c:\>"c:\Program Files\Java\
jdk-12.0.2\bin\java.exe" -version
java version "12.0.2" 2019-07-16
Java(TM) SE Runtime Environment (build 12.0.2+10)
Java HotSpot(TM) 64-Bit Server VM (build 12.0.2+10, mixed mode, sharing)
No other JDK or JRE versions are installed.
Java itself works just fine - I compiled and ran few Spring samples, installed and used Maven, everything works.
Any idea what can be wrong here? Is there any way to force Eclipse to output more info about the error (e.g. the value returned by GetLastError() in the Windows API after loading the library failed).
Thanks!
I solved the problem by downloading and installing the Visual C++ 2015 runtime from Microsoft.
Apparently it's needed for that specific jvm.dll and isn't installed automatically by the JDK installer.

Why cmd give error when we open uiautomatorviewer?

When I run the following command in the command prompt that time I am getting the following error.
Command: C:\Users\ob>uiautomatorviewer
Error:
-Djava.ext.dirs=..\lib\x86_64;..\lib is not supported.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Set your all android path properly.
Add variable in system environment as mention below.
ANDROID_SWT : C:\Users\chetan\AppData\Local\Android\Sdk\tools\lib\x86_64
ANDROID_HOME : C:\Users\chetan\AppData\Local\Android\Sdk
ANDROID_PLATFORM_TOOLS : C:\Users\chetan\AppData\Local\Android\Sdk\platform-tools
Add below mention Path in Path Variable in system environment.
C:\Program Files\Java\jdk\bin;
C:\Users\chetan\AppData\Local\Android\Sdk\tools\bin;
C:\Users\chetan\AppData\Local\Android\Sdk\tools;
C:\Users\chetan\AppData\Local\Android\Sdk\platform-tools;
C:\Program Files\nodejs\node_modules\npm\bin;
C:\Users\chetan\AppData\Local\Android\Sdk;
C:\Users\chetan\AppData\Local\Android\Sdk\tools\lib\x86_64\swt.jar;
Pre-Check - Verify the java Version installed in your system.
VERIFY - java -version
java version "1.8.0_221" Java(TM) SE Runtime Environment (build
1.8.0_221-b11) Java HotSpot(TM) 64-Bit Server VM (build 25.221-b11, mixed mode)
If this message appears that means you have JAVA 8 install and uiautomatorviewer only supports till JAVA 8.
So install JAVA 8 from here and if you already have JAVA install down grade it to JAVA 8

ElasticSearch installation error with CLASSPATH

I am getting the below mentioned error when i am trying to install elastic search version 6.6.0 on my windows 10 OS. The command i am using to install is
-- Command:
elasticsearch -Ecluster.name=TestES -Enode.name=First_Node
-- Error:
\Java\jre-9.0.4\bin\java.exe" -cp "!ES_CLASSPATH!" "org.elasticsearch.tools.launchers.TempDirectory""` was unexpected at this time.
-- Java Version install on my pc:
java version "9.0.4"
Java(TM) SE Runtime Environment (build 9.0.4+11)
Java HotSpot(TM) 64-Bit Server VM (build 9.0.4+11, mixed mode)
Please guide how to fix this issue.
Regards
Qasim
Same issue i was getting on my machine.
I then found issue was related to 32 bit Java was installed instead of 64 bit, i reinstalled and it started working fine.
if your java is installed under C:\Program Files (x86) then set the JAVA_HOME like will below
set JAVA_HOME=C:\Progra~2\Java\jre1.8.0_131
if your java is installed under C:\Program Files then set the JAVA_HOME like will below
set JAVA_HOME=C:\Progra~1\Java\jre1.8.0_131
After that try to start the elastic search, it should start then.
Thanks & Regards
Jaiswar Vipin Kumar R.

Resources