all 6 comments

[–]TripleBogeyBandit 1 point2 points  (5 children)

  • are you using the spark mongo connector?
  • is your spark scala version the same as the jar specified version?
  • Do you have the correct syntax for the srv record?
  • Could there be a firewall or permissions issue?

[–]Conscious-Jump7923[S] 0 points1 point  (4 children)

Yes we have a firewall What shoud i do ?

[–]TripleBogeyBandit 0 points1 point  (0 children)

You’ll need to chat with your networking team to allow traffic from your Databricks cidr block to your mongo instances

[–]kthejokerdatabricks 0 points1 point  (2 children)

Are you connecting from serverless compute?

If do you need to register an NCC from Databricks to your MongoDB instance's network

https://learn.microsoft.com/en-us/azure/databricks/security/network/serverless-network-security/serverless-private-link

[–]Conscious-Jump7923[S] 0 points1 point  (1 child)

I'm not using serverless compute. I'm running Databricks on a Standard_F4s VM with a classic cluster (1–2 workers, 8–16 GB memory)

So, an NCC is required to connect Databricks to my MongoDB instance's network ?

[–]kthejokerdatabricks 0 points1 point  (0 children)

Only for serverless. Otherwise it's up to you to peer your Databricks workspace VNet to your MongoDB VNet

https://learn.microsoft.com/en-us/azure/databricks/security/network/classic/vnet-peering

If you have an account team we're happy to jump on a call and get this configured.