Skip to content

Enable OCI as a Cloud provider in PKB. - #4061

Closed
gadgilrajeev wants to merge 13 commits into
GoogleCloudPlatform:masterfrom
gadgilrajeev:oci-provider
Closed

gadgilrajeev wants to merge 13 commits into
GoogleCloudPlatform:masterfrom
gadgilrajeev:oci-provider

Conversation

@gadgilrajeev

Copy link
Copy Markdown
Contributor

Enable OCI as a cloud provider in PKB

  • Virtual Machines:

    • Launch Shapes. Currently supports only Flex VM​
    • What can you configure​
    • Image (Either Ubuntu or Oracle)​
    • Size of Boot Disk (currently only supports Paravirtualized Boot disk)​
    • Machine always gets assigned an external ip address (no option to disable this)​
    • ssh-key pair for every transaction is different autogenerated. Does not yet support providing userdefined ssh-keys​
    • Username is always "perfkit". (No option to change this)​
    • Iptables are flushed on boot in Ubuntu images and firewalld service are disabled in Oracle Linux images (Cloud-init). This ensures we do not need to deal with individual firewall rules​. Will be implemented in NSG
    • Freeform Tags are automatically added
  • OCI Network:

    • oci_use_vcn: (equivalency to gce_use_vcn) ​
      • False: Can use Preconfigured network​
      • True: PKB will manage creating VCN, subnet, Internet Gateway and Security Rules​
    • CIDR block is always created with 17.16.0.0/16​
    • Security Rules on local subnet (172.16.0.0) is ingress all ports open. Only port 22 is open on external ip.
  • OCI Block Volume (BV)​ <-> Disks

    • Supports following types of block volumes (not boot volumes)​
      • Paravirtualized​
      • iscsi​
    • Size of disks is settable. ​
    • Multiple disks can be attached to a shape. Upto 32 disks can be attached.
    • vpus: option in YAML to define the disk with a given IOPS that will be launched. ​
      • Acceptable values for vpus per GB is​
        • 0: Represents Lower Cost option.​
        • 10: Represents Balanced option.​
        • 20: Represents Higher Performance option.​
    • Attaching disks is handled automatically. iscsi attach commands are also autogenerated and executed.​
    • Boot volume disk type is always paravirtualized

Oracle 8 and Oracle 9 Linux related changes will be pushed in a separate commit.

What is not supported:

  1. Opening specific ports in the firewall. Eg: iperf​
  2. Network security Group management – WIP​
  3. VNICs cannot be placed in NSG and attached to a Shape​
  4. Launching Clusters is not supported as of now​
  5. Launching user provided boot images is not supported​
  6. Launching OCI services (Eg: OracleDB, mysql as a service) is not supported.​

Need account on OCI and OCI CLI tools installed:

Example PKB log attached with memcached-memtier

pkb.log

@s-deitz

s-deitz commented Mar 9, 2023

Copy link
Copy Markdown
Member

Thanks for the potential contribution. We are discussing this PR and will try to get back to you in the next two weeks with more information.

@gadgilrajeev

Copy link
Copy Markdown
Contributor Author

Any update?

@s-deitz

s-deitz commented Jun 28, 2023

Copy link
Copy Markdown
Member

Hi Rajeev

Thanks for your patience. We can accept this as a contribution, but will only do a light review and won't run or test the contribution. There is a risk that we may break this with changes so will appreciate further contributions from you or the community.

@asaksena Please find someone to light review and pull in.

@gadgilrajeev

Copy link
Copy Markdown
Contributor Author

@s-deitz @asaksena any possibility to follow up on this?

@asaksena

asaksena commented Aug 21, 2023 via email

Copy link
Copy Markdown
Contributor
@anksena

anksena commented Jan 24, 2024

Copy link
Copy Markdown
Contributor

Hi Rajeev,

First I apologize for the delay.
May I kindly request you to remove the following folders from the PR

bash_scripts/*
config_files/*
docs/*

I do not see them being related to the OCI
Please correct me if I am wrong.

thanks

@gadgilrajeev

Copy link
Copy Markdown
Contributor Author

I am going to close this pull request and open a new one. There is too much conflict in the current codebase.

@gadgilrajeev

Copy link
Copy Markdown
Contributor Author

@anksena will update here once a new one is opened.

@gadgilrajeev

Copy link
Copy Markdown
Contributor Author

Moving to a new pull request.

gadgilrajeev added a commit to gadgilrajeev/PerfKitBenchmarker that referenced this pull request Oct 23, 2026
Reworks the OCI provider from the oci-provider branch (originally proposed
in GoogleCloudPlatform#4061) on top of current master:

- VMs: launch via the oci CLI with Flex shape config (OCPUs/memory),
  boot volume size, preemptible instances, fault/availability domain
  selection, start/stop, interruption detection and resource metadata.
  Images are resolved per os_type (Ubuntu 22.04/24.04, Oracle Linux 8/9),
  by display name, or by OCID.
- Zones are OCI regions with an optional "-ad-N" availability domain
  suffix, e.g. us-ashburn-1-ad-2. VMs in a region share one VCN.
- Networking: VCN, internet gateway, default route and a regional subnet,
  with intra-VCN traffic allowed. OciFirewall opens TCP/UDP ports and ICMP
  on the VCN security list. --oci_network_name reuses an existing VCN
  without modifying it.
- Disks: block volumes with disk types mapped to VPUs/GB (lower_cost,
  balanced, higher_performance, ultra_high_performance), paravirtualized
  or iSCSI attachment at consistent device paths, and striping via the
  standard scratch disk strategies.
- Unit tests for util, network, firewall, disk and VM modules, plus docs
  and default config constants.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

6 participants