Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
La résolution DNS est disponible dans les instances privées exécutées dans Cloud Data Fusion version 6.7.0 ou ultérieure. Il vous permet d'utiliser des noms d'hôte ou de domaine pour les sources et les récepteurs lorsque vous concevez votre pipeline dans une instance Cloud Data Fusion privée. Vous n'avez ainsi pas besoin de modifier la définition du pipeline lors du basculement.
Sans cela, vous utilisez des adresses IP codées en dur, ce qui pose problème lorsque les adresses changent en cas de basculement dans les déploiements à haute disponibilité. La résolution DNS est recommandée lorsque vous concevez un pipeline dans une instance privée et que vous souhaitez récupérer le schéma, exécuter des aperçus, organiser et tester des connexions.
Cloud Data Fusion utilise l'appairage de réseaux VPC pour établir la connectivité réseau avec votre réseau VPC ou VPC partagé. Cela permet à Cloud Data Fusion d'accéder aux ressources de votre réseau via des adresses IP internes.
Lorsque vous le configurez, procédez comme suit :
Saisissez le nom de votre connexion d'appairage.
Pour Votre réseau VPC, sélectionnez le réseau dans lequel vous avez créé votre instance Cloud Data Fusion.
Pour Réseau VPC appairé, sélectionnez Dans un autre projet.
Pour Nom du réseau VPC, saisissez INSTANCE_REGION-INSTANCE_ID.
Remplacez les éléments suivants :
INSTANCE_REGION : région dans laquelle vous avez créé votre instance Cloud Data Fusion.
INSTANCE_ID : ID de l'instance Cloud Data Fusion.
Pour Échanger des routes personnalisées, cliquez sur Exporter les routes personnalisées. Cela permet d'échanger toutes les routes personnalisées définies dans votre réseau VPC avec le réseau VPC locataire.
Cliquez sur Créer.
Si l'appairage de réseaux VPC est correctement configuré, l'état sur la page des détails du réseau VPC est Actif.
Créer une zone DNS privée gérée
Pour résoudre les noms de domaine dans Cloud Data Fusion, créez une zone DNS privée gérée dans le même réseau VPC ou réseau VPC partagé que celui utilisé pour l'appairage de réseaux VPC. Pour en savoir plus, consultez Créer une zone privée.
Console
Pour créer une zone DNS privée gérée :
Dans la console Google Cloud , accédez à la page Créer une zone DNS.
Dans le champ Nom DNS, saisissez un nom de domaine.
Dans Options, cliquez sur Par défaut (privé).
Sous Réseaux, sélectionnez le réseau VPC ou le réseau VPC partagé qui a été utilisé pour l'appairage de réseaux VPC.
Cliquez sur Créer.
Créer un jeu d'enregistrements dans la zone DNS
Créez l'ensemble d'enregistrements dans la zone DNS qui contient les adresses IP internes à résoudre lorsque vous concevez votre pipeline. Pour en savoir plus, consultez Ajouter un enregistrement.
Console
Pour créer le jeu d'enregistrements, procédez comme suit :
Dans la console Google Cloud , accédez à la page Cloud DNS.
Cliquez sur la zone pour laquelle vous souhaitez créer un jeu d'enregistrements de ressources.
Sur la page Détails de la zone, cliquez sur Ajouter un jeu d'enregistrements standard.
Dans le champ Nom DNS, saisissez un nom de domaine qui doit être résolu au moment de la conception.
Saisissez les informations sur le type d'enregistrement. Pour l'adresse IPv4, indiquez l'adresse IP interne du récepteur ou de la source à utiliser dans le pipeline. Pour en savoir plus sur les types d'enregistrements, consultez Ajouter un enregistrement.
Cliquez sur Créer.
Ajouter un appairage DNS dans une instance
Console
Pour créer un appairage DNS dans la console Google Cloud :
Ouvrez votre instance.
Dans la Google Cloud console, accédez à la page Cloud Data Fusion.
Cliquez sur Instances, puis sur le nom de l'instance pour accéder à la page Détails de l'instance.
Pour vous assurer que le compte de service Cloud Data Fusion dispose des autorisations nécessaires pour créer un peering DNS dans un réseau VPC partagé, demandez à votre administrateur d'accorder au compte de service Cloud Data Fusion le rôle IAM Pair DNS (roles/dns.peer) sur le projet hôte VPC partagé.
Votre administrateur peut également attribuer au compte de service Cloud Data Fusion les autorisations requises à l'aide de rôles personnalisés ou d'autres rôles prédéfinis.
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2025/09/04 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Difficile à comprendre","hardToUnderstand","thumb-down"],["Informations ou exemple de code incorrects","incorrectInformationOrSampleCode","thumb-down"],["Il n'y a pas l'information/les exemples dont j'ai besoin","missingTheInformationSamplesINeed","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2025/09/04 (UTC)."],[[["\u003cp\u003eDNS resolution, available in Cloud Data Fusion version 6.7.0 or later in private instances, enables the use of hostnames or domain names for pipeline sources and sinks, eliminating the need to change pipeline definitions during failover.\u003c/p\u003e\n"],["\u003cp\u003eTo use DNS resolution, create a private Cloud Data Fusion instance (version 6.7.0 or later), set up VPC Network Peering, create a managed private DNS zone, and add record sets with internal IP addresses for domain name resolution.\u003c/p\u003e\n"],["\u003cp\u003eDNS peering can be added to a Cloud Data Fusion instance through the console or the REST API, by providing a DNS peering ID, domain name, target project, and network.\u003c/p\u003e\n"],["\u003cp\u003eIn shared VPC networks, DNS resolution requires creating private zones in the host project or setting them up in a service project with cross-project binding, and the Cloud Data Fusion Service Account needs the \u003ccode\u003eroles/dns.peer\u003c/code\u003e IAM role.\u003c/p\u003e\n"]]],[],null,["# Resolve domain names or hostnames\n\nDNS resolution is available in private instances running in\nCloud Data Fusion version 6.7.0 or later. It lets you use hostnames or\ndomain names for sources and sinks when you design your pipeline in a private\nCloud Data Fusion instance so that you don't have to change the pipeline\ndefinition during failover.\n\nWithout it, you use hard-coded IP addresses, which are problematic when the\naddresses change in the event of a failover in highly-available deployments. DNS\nresolution is recommended when you design a pipeline in a private instance and\nwant to retrieve schema, run previews, wrangle, and test connections.\n| **Note:** Internal IP address resolution is also available with VPC Peering in all Cloud Data Fusion versions.\n\nFor more information, see\n[DNS resolution in Cloud Data Fusion](/data-fusion/docs/concepts/networking#dns-resolution).\n\nBefore you begin\n----------------\n\n### Create a private instance\n\nCreate a private instance in Cloud Data Fusion and set up a VPC network or\nshared VPC network in the instance with the following steps.\n\n1. [Create a private Cloud Data Fusion instance](/data-fusion/docs/how-to/create-private-ip).\n When you create the instance, choose the following options:\n\n 1. Choose version 6.7.0 or later.\n 2. In the **Network** field, choose the appropriate associated network for the private connection.\n 3. Enter any other instance details and click **Create** . For information about all fields, see [Create a private Cloud Data Fusion instance](/data-fusion/docs/how-to/create-private-ip).\n2. [Set up VPC Network Peering](/data-fusion/docs/how-to/create-private-ip#set-up-vpc-peering).\n\n Cloud Data Fusion uses VPC Network Peering to establish network\n connectivity to your VPC or shared VPC network. This lets\n Cloud Data Fusion access resources on your network through internal IP\n addresses.\n\n When you set it up, do the following:\n 1. Enter a **Name** for your peering connection.\n 2. For **Your VPC network**, choose the network where you created your Cloud Data Fusion instance.\n 3. For **Peered VPC network** , choose **In another project**.\n 4. For **Project ID** , enter the [tenant project ID](/data-fusion/docs/how-to/create-private-ip#find_your_tenant_project_ID).\n 5. For **VPC network name** , enter\n \u003cvar translate=\"no\"\u003eINSTANCE_REGION\u003c/var\u003e`-`\u003cvar translate=\"no\"\u003eINSTANCE_ID\u003c/var\u003e.\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003eINSTANCE_REGION\u003c/var\u003e: the region in which you created your Cloud Data Fusion instance.\n - \u003cvar translate=\"no\"\u003eINSTANCE_ID\u003c/var\u003e: the ID of the Cloud Data Fusion instance.\n 6. For **Exchange custom routes** , click **Export custom routes**. This\n allows for exchanging any custom routes defined in your VPC network with\n the tenant VPC network.\n\n 7. Click **Create**.\n\n If the VPC Network Peering is successfully set up, the **Status** on the VPC\n network details page is **Active**.\n | **Note:** Create a firewall rule on your VPC network that allows for incoming SSH connections from the IP address range you specified when you created the private Cloud Data Fusion instance.\n\n### Create a managed private DNS zone\n\nTo resolve domain names in Cloud Data Fusion, create a new managed private\nDNS zone in the same VPC network or shared VPC network that was used for VPC\nnetwork peering. For more information, see\n[Create a private zone](/dns/docs/zones#create-private-zone). \n\n### Console\n\n\nTo create a private managed DNS zone, do the following:\n\n1. In the Google Cloud console, go to the **Create a DNS zone** page.\n\n [Go to Create a DNS zone](https://console.cloud.google.com/net-services/dns/zones/new/create)\n2. For **Zone name**, enter a name.\n3. For **Zone type** , click **Private**.\n4. For **DNS name**, enter a domain name.\n5. For **Options** , click **Default (private)**.\n6. For **Networks**, select the VPC network or shared VPC network that was used for VPC Network Peering.\n7. Click **Create**.\n\n### Create a record set in the DNS zone\n\nCreate the record set in the DNS zone that has the internal IP addresses to\nresolve when you design your pipeline. For more information, see\n[Add a record](/dns/docs/records#add_a_record). \n\n### Console\n\n\nTo create the record set, do the following:\n\n1. In the Google Cloud console, go to the **Cloud DNS** page.\n\n [Go to Cloud DNS](https://console.cloud.google.com/net-services/dns)\n2. Click the zone for which you want to create a resource record set.\n\n3. On the **Zone details** page, click **Add Standard**.\n\n4. For **DNS name**, enter a domain name that must be resolved during design\n time.\n\n5. Enter the record type details. For the IPv4 address, provide the internal\n IP address for the sink or source to be used in the pipeline. For more\n information about record types, see\n [Add a record](/dns/docs/records#add_a_record).\n\n6. Click **Create**.\n\nAdd DNS Peering in an instance\n------------------------------\n\n### Console\n\n\nTo create DNS peering in the Google Cloud console, do the following:\n\n1. Open your instance.\n\n 1. In the Google Cloud console, go to the Cloud Data Fusion page.\n\n 2. Click **Instances** , and then click the instance's name to go to the\n **Instance details** page.\n\n [Go to Instances](https://console.cloud.google.com/data-fusion/locations/-/instances)\n2. Click **Add DNS peering**.\n\n The **Add DNS peering** dialog opens.\n3. For **DNS peering ID**, enter a name.\n\n4. For **Domain**, enter the domain name that you used for creating the\n private DNS zone.\n\n5. For the **Target project**, select the project name where the private\n DNS zone was created.\n\n6. For the **Network**, select the VPC network name where the\n private DNS zone was created.\n\n7. Click **Save** to create the DNS peering.\n\n### REST API\n\n\nTo resolve domain and hostnames with the Cloud Data Fusion DNS Peering\nAPI, call its\n[`create()`](/data-fusion/docs/reference/rest/v1/projects.locations.instances.dnsPeerings/create)\nmethod.\n\nFor more information and methods, see the Cloud Data Fusion\n[DNS Peering API reference](/data-fusion/docs/reference/rest/v1/projects.locations.instances.dnsPeerings).\n\nDNS resolution in shared VPC networks\n-------------------------------------\n\nTo create the Cloud DNS private zones in a [shared VPC](/vpc/docs/shared-vpc)\nnetwork, create a\n[private zone](/vpc/docs/shared-vpc#shared_vpc_and_cloud_dns_private_zones) in\nthe host project and authorize access to the zone for the shared VPC network or\nset up the zone in a service project using\n[cross-project binding](/dns/docs/zones/cross-project-binding). For more\ninformation, see\n[Best practices for Cloud DNS private zones](/dns/docs/best-practices#best_practices_for_private_zones).\n\n### Required roles for shared VPC networks\n\n\nTo ensure that the Cloud Data Fusion Service Account has the necessary\npermissions to create a DNS peering in a shared VPC network,\n\nask your administrator to grant the Cloud Data Fusion Service Account the\n\n\n[DNS Peer](/iam/docs/roles-permissions/dns#dns.peer) (`roles/dns.peer`)\nIAM role on the shared VPC host project.\n\n\n| **Important:** You must grant this role to the Cloud Data Fusion Service Account, *not* to your user account. Failure to grant the role to the correct principal might result in permission errors.\nFor more information about granting roles, see [Manage access to projects, folders, and organizations](/iam/docs/granting-changing-revoking-access).\n\n\u003cbr /\u003e\n\n\nYour administrator might also be able to give the Cloud Data Fusion Service Account\nthe required permissions through [custom\nroles](/iam/docs/creating-custom-roles) or other [predefined\nroles](/iam/docs/roles-overview#predefined).\n\nFor more information, see\n[Granting access to the required service accounts](/iam/docs/granting-changing-revoking-access#granting-console).\n\nWhat's next\n-----------\n\n- Learn more about [Networking in Cloud Data Fusion](/data-fusion/docs/concepts/networking).\n- Refer to the [Cloud Data Fusion API](/data-fusion/docs/reference/rest/v1/projects.locations.instances.dnsPeerings)."]]