S2VUtils.getConnectionToVerticaHost(): FATAL ERROR. cound not get connection to any host in list

Environment: 

vertica-7.2.3_ovf

VMware-player-12.1.1-3770994

Windows 10

apache spark-1.6.2

hpe-vertica-spark-connector-0.2.2

 

Code:

 

HashMap<String, String> verticaConnectorProperties = new HashMap<String, String>();
verticaConnectorProperties.put("table", "testtable");
verticaConnectorProperties.put("db", "testdb");
verticaConnectorProperties.put("user", "testuser");
verticaConnectorProperties.put("password", "testpassword");
verticaConnectorProperties.put("host", "192.168.10.10"); // IP of Vertica VM installed on this machine
dataFrame.write()
.format("com.vertica.spark.datasource.DefaultSource")
.mode(SaveMode.Overwrite)
.options(verticaConnectorProperties)
.save();

 

Error:

 

16/08/08 14:38:57 INFO S2VUtils: current partitions in DataFrame=2; S2V default value=16; user option numPartitions=16; final S2V numPartitions for save=2
16/08/08 14:38:57 INFO S2VUtils: All user options and S2V options validated ok: temp_table=S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391, strlen=1024, save_mode=Overwrite, last_committer_table=S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391_last_committer, host=192.168.10.10, num_partitions=2, tmpdir=/tmp, db=somedb, empty_count=-1, job_name=S2V_job4115324674851267391, all_done_table=S2V_JOB_STATUS, commit_tables_prefix=S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391_commits_partition, dbschema=public, port=5433, autocommit=false, log_rejected_rows_sample_size=10, primary_ip=192.168.10.10, failed_rows_percent_tolerance=0.0, batch_size=100000, user=dbadmin, table=sometable, password=MASKED
16/08/08 14:38:57 INFO S2VUtils: Unique job name:S2V_job4115324674851267391 will appear in Vertica table: public.S2V_JOB_STATUS
16/08/08 14:38:57 INFO S2V: Vertica node IPs mapping=Map(127.0.0.1 -> 127.0.0.1)
16/08/08 14:38:57 INFO S2V: Vertica node IPs that will be used by the connector=List(127.0.0.1)
16/08/08 14:38:58 ERROR S2VUtils: ERROR: getConnectionToVerticaHost(): ConnectException: java.lang.NullPointerException
16/08/08 14:38:58 ERROR S2VUtils: ERROR: ConnectException: java.lang.Exception: ERROR: S2VUtils.getConnectionToVerticaHost(): FATAL ERROR. cound not get connection to any host in list:'List(127.0.0.1)'.
16/08/08 14:38:58 INFO S2VUtils: createTempTables(): creating all temp tables now...
16/08/08 14:38:59 ERROR S2VUtils: ERROR: getConnectionToVerticaHost(): ConnectException: java.lang.NullPointerException
16/08/08 14:38:59 ERROR S2VUtils: ERROR: ConnectException: java.lang.Exception: ERROR: S2VUtils.getConnectionToVerticaHost(): FATAL ERROR. cound not get connection to any host in list:'List(127.0.0.1)'.
16/08/08 14:39:00 ERROR S2VUtils: ERROR: getConnectionToVerticaHost(): ConnectException: java.lang.NullPointerException
16/08/08 14:39:00 ERROR S2VUtils: Error: Update statement: CREATE table public.S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391 (sd_enodeb_name LONG VARCHAR (1024),
sd_managed_object2 LONG VARCHAR (1024),
sd_cell_name LONG VARCHAR (1024),
sd_vendor LONG VARCHAR (1024),
sd_status LONG VARCHAR (1024),
sd_date_onair LONG VARCHAR (1024),
sd_long_wgs84 DOUBLE PRECISION,
sd_lat_wgs84 DOUBLE PRECISION,
sd_height DOUBLE PRECISION,
sd_azimuth DOUBLE PRECISION,
sd_cluster LONG VARCHAR (1024),
sd_operator LONG VARCHAR (1024),
sd_region LONG VARCHAR (1024),
sd_province LONG VARCHAR (1024),
sd_city LONG VARCHAR (1024),
sd_projection_utm LONG VARCHAR (1024),
sd_earfcn_dl INTEGER,
sd_freq_band LONG VARCHAR (1024),
sd_freq_type LONG VARCHAR (1024),
sd_horizontal_beamwidth INTEGER,
sd_node_type LONG VARCHAR (1024),
sd_enodeb_id INTEGER,
sd_cellid INTEGER,
sd_cell_type LONG VARCHAR (1024),
sd_tal LONG VARCHAR (1024),
sd_tac INTEGER,
sd_pci INTEGER,
sd_frequency LONG VARCHAR (1024),
sd_mcc LONG VARCHAR (1024),
sd_mnc LONG VARCHAR (1024),
sd_antenna LONG VARCHAR (1024),
sd_e_tilt LONG VARCHAR (1024),
sd_m_tilt LONG VARCHAR (1024),
sd_ne LONG VARCHAR (1024),
sd_engineer LONG VARCHAR (1024),
sd_cell_coverage LONG VARCHAR (1024),
sd_siteatt LONG VARCHAR (1024) ). java.lang.Exception: ERROR: S2VUtils.getConnectionToVerticaHost(): FATAL ERROR. cound not get connection to any host in list:'List(127.0.0.1)'.
16/08/08 14:39:00 ERROR S2VUtils: createTempTables(): FAILED to create table public.S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391
16/08/08 14:39:00 ERROR S2VUtils: createTempTables(): FAILED to create table public.S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391_last_committer
16/08/08 14:39:01 ERROR S2VUtils: ERROR: getConnectionToVerticaHost(): ConnectException: java.lang.NullPointerException
16/08/08 14:39:01 ERROR S2VUtils: ERROR: ConnectException: java.lang.Exception: ERROR: S2VUtils.getConnectionToVerticaHost(): FATAL ERROR. cound not get connection to any host in list:'List(127.0.0.1)'.
16/08/08 14:39:01 ERROR S2VUtils: createTempTables(): FAILED to create table public.S2V_JOB_STATUS
16/08/08 14:39:02 ERROR S2VUtils: createTempTables(): FAILED to create tables public.S2V_TEMP_TABLE_sometable_S2V_job4115324674851267391_commits_partition_0...1
16/08/08 14:39:02 ERROR VerticaSparkConnectorLoader: Error in saveToVertica
java.lang.Exception: ERROR: S2V.save(): Failed to setup the temp tables to track Spark partition commits.
at com.vertica.spark.s2v.S2V.save(S2V.scala:117)
at com.vertica.spark.datasource.DefaultSource.createRelation(VerticaSource.scala:77)
at org.apache.spark.sql.execution.datasources.ResolvedDataSource$.apply(ResolvedDataSource.scala:222)
at org.apache.spark.sql.DataFrameWriter.save(DataFrameWriter.scala:148)
at my.java.File(MyJavaFile.java:54)

 

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file