One more question :slightly_smiling_face: We deplo...
# gooddata-cn
t
One more question 🙂 We deployed pods but for example sql-executor pods are failing to start and keep restarting container, in logs I see the following error:
Copy code
HikariPool-1 - Exception during pool initialization.","exc":"org.postgresql.util.PSQLException: FATAL: Client from Azure Virtual Networks is not allowed to access the server. Please make sure your Virtual Network is correctly configured.
I double checked the azure postgresql db setup and all seem to be ok (password, user, host..). Where could be the problem?
✔️ 1
the whole log line:
Copy code
{
  "ts": "2022-05-31 11:32:39.160",
  "level": "ERROR",
  "logger": "com.zaxxer.hikari.pool.HikariPool",
  "thread": "main",
  "msg": "HikariPool-1 - Exception during pool initialization.",
  "exc": "org.postgresql.util.PSQLException: FATAL: Client from Azure Virtual Networks is not allowed to access the server. Please make sure your Virtual Network is correctly configured.\n\tat org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:613)\n\tat org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:161)\n\tat org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:213)\n\tat org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:51)\n\tat org.postgresql.jdbc.PgConnection.<init>(PgConnection.java:225)\n\tat org.postgresql.Driver.makeConnection(Driver.java:465)\n\tat org.postgresql.Driver.connect(Driver.java:264)\n\tat com.zaxxer.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:138)\n\tat com.zaxxer.hikari.pool.PoolBase.newConnection(PoolBase.java:364)\n\tat com.zaxxer.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:206)\n\tat com.zaxxer.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:476)\n\tat com.zaxxer.hikari.pool.HikariPool.checkFailFast(HikariPool.java:561)\n\tat com.zaxxer.hikari.pool.HikariPool.<init>(HikariPool.java:115)\n\tat com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:112)\n\tat liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:272)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1863)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1800)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:620)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:542)\n\tat org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)\n\tat org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)\n\tat org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)\n\tat org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)\n\tat org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:953)\n\tat org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)\n\tat org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)\n\tat org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145)\n\tat org.springframework.boot.SpringApplication.refresh(SpringApplication.java:775)\n\tat org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:448)\n\tat org.springframework.boot.SpringApplication.run(SpringApplication.java:339)\n\tat org.springframework.boot.SpringApplication.run(SpringApplication.java:1365)\n\tat org.springframework.boot.SpringApplication.run(SpringApplication.java:1354)\n\tat com.gooddata.tiger.metadata.MetadataApplicationKt.main(MetadataApplication.kt:103)\n\tat java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)\n\tat java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)\n\tat java.base/java.lang.reflect.Method.invoke(Unknown Source)\n\tat org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)\n\tat org.springframework.boot.loader.Launcher.launch(Launcher.java:108)\n\tat org.springframework.boot.loader.Launcher.launch(Launcher.java:58)\n\tat org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:88)\n\tSuppressed: org.postgresql.util.PSQLException: FATAL: Client from Azure Virtual Networks is not allowed to access the server. Please make sure your Virtual Network is correctly configured.\n\t\tat org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:613)\n\t\tat org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:161)\n\t\tat org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:222)\n\t\t... 38 more\n"
}
setup values
the command to create the postgresdb
Copy code
az postgres server create --resource-group $RESOURCE_GROUP \
  --name gooddata-cn-pg --location $LOCATION --version 11 \
  --admin-user postgres --admin-password $PASSWORD \
  --sku-name GP_Gen5_4 --public Enabled --ssl-enforcement Disabled
I am not an expert in this area, but the answer in the Stackoverflow seems to be valid.
t
yes, thanks! it seems to be the problem that service endpoint is enabled for the vnet. I originally thought it will go via public internet since the db is fully public.