Hi@akhtar,
In /etc/spark/conf/spark-defaults.conf, append the path of your custom JAR to the class names.
Open vim /etc/spark/conf/spark-defaults.conf and add jars.
spark.driver.extraClassPath :/home/hadoop/extrajars/*
spark.executor.extraClassPath :/home/hadoop/extrajars/*
Hope this will work.