Creating an AWS Asset Source

Learn how to create an asset source in an Oracle Cloud Migrations environment.

Before you create an asset source, ensure that you have defined the required AWS privileges. See AWS Credentials.

  • To create an asset source, follow these steps:
    1. Open the navigation menu  and select Migration & Disaster Recovery. Under Cloud Migrations, select Discovery.
    2. On the Asset sources list page, select Create asset source.
    3. For Asset source type, select AWS.
    4. In the Asset source information section, provide the following details:
      1. Name: Enter a name for the asset source.
      2. Account ID: Enter the AWS account ID. See Where Can I Find My AWS Account ID?
      3. Region: Select the AWS region where the source resources are located.
      4. Compartment: Select a compartment for the asset source.
      5. Target compartment: Select the compartment where you created the inventory assets.
    5. In the Remote connections source environment section, select the source environment.
      • If a source environment already exists, select Use existing source environment and select the environment.
      • To create a new environment, select Create new, enter a name for the environment and the compartment to create it in, and optionally assign one or more tags to the environment.
    6. In the Discovery credentials section, use one of the following options:
      • Select Use existing secret and select a vault and secret for existing discovery credentials.
      • Select Create secret, enter a name and description for the secret, select a vault and encryption key, and then enter the access key ID and secret access key for the credentials that have discovery permissions. See Required IAM Permissions for Discovery.
    7. (Optional) In the Replication credentials section, use one of the following options or none:
      • Select Use discovery credentials to use the same credentials selected in the previous section.
      • Select Use existing secret and select a vault and secret for existing replication credentials.
      • Select Create secret and enter a name and description for the secret, select a vault and encryption key, and then enter the access key ID and secret access key for the credentials that have replication permissions. See Required IAM Permissions for Replication.
    8. Under Discovery schedules, select one of the following options to perform the discovery job:
      • To perform an on-demand or manual asset discovery, select No discovery schedule.
      • To use an existing discovery schedule, select Select existing schedule.
      • To create a wanted discovery schedule, select Create schedule.

        You can keep asset information up-to-date by using the discovery scheduling mechanism, as a recurring task. After creating a discovery schedule, you can attach or detach it from an existing asset source to begin or stop scheduling discovery jobs for external asset discovery and metadata collection.

    9. In the Metrics section, select one or more of the following options:
      Note

      The metrics for AWS aren't selected by default. Enabling real-time and historical metrics collection uses the Amazon CloudWatch service and enabling cost estimation metrics uses Amazon Cost Explorer service, which are chargeable resources.
      • If you select Enable collection of cost estimation metrics, OCI automatically collects historical metrics once per day.
      • If you select Enable collection of real-time metrics, OCI automatically collects real-time metrics once per hour
      • If you select Enable collection of historical metrics, OC automatically collects cost-estimation metrics when a discovery job is run.
      • If enabled, both real-time and historical metrics are also collected when a discovery job is run manually.
    10. (Optional) Add tags to organize your resource. To apply a defined tag, you must have permissions to use the tag namespace. For more information about tagging, see Resource Tags. If you're not sure whether to apply tags, skip this option (you can apply tags later) or ask your administrator
    11. Select Create asset source.
    You're redirected to the Asset source details page after the asset source is created successfully.
    You can now create a discovery work request.
  • To create an asset source, use the create command.

    oci cloud-bridge discovery asset-source create --assets-compartment-id asset_compartment_ID --compartment-id target_compartment_ID --environment-id target_environment_ID --inventory-id assets_inventory_ID --type asset_source_type --discoveryCredentials credentials [OPTIONS]
    The required parameters for the create command are:
    • --assets-compartment-id: Specifies the OCID of the compartment that is used to create assets.
    • --compartment-id: Specifies the OCID of the compartment for the resource.
    • --environment-id: Specifies the OCID of the environment.
    • --inventory-id: Specifies the OCID of the inventory that contains the created assets.
    • --type: Specifies the type of asset source in the external environment. The accepted value is AWS.
    • --discovery-credentials: Specifies the OCI Vault secret that contains AWS credentials. The value cannot be null.
    • --aws-account-key: Specifies the AWS account key.
    • --aws-region: Specifies the AWS region where the source resources are located.
    • --are-historical-metrics-collected: Specifies the historical metrics that are collected directly from the source environment and contain a single value for the average network, memory, and CPU usage over an interval. Only one value for each is provided at the one day, one week, and one month intervals. This is optional.
    • --are-realtime-metrics-collected: Specifies the real-time metrics that are periodically collected from the source environment are stored in OCI monitoring. Overtime, more accurate calculations can be made against these metrics without relying on data provided by the source environment. This is optional.
    • --is-cost-information-collected: Specifies the cost estimation metrics. This is optional.

    To get all the commands for discovery asset-source, run:

    oci cloud-bridge discovery asset-source -h

    To get help for the create command, run:

    oci cloud-bridge discovery asset-source create -h

    For a complete list of flags and variable options for CLI commands, see the CLI Command Reference.

  • To create an asset source, use the CreateAssetSource operation.