Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Platform Request: Oracle Cloud Infrastructure (OCI) #414

Open
11 tasks
chris93111 opened this issue Mar 7, 2020 · 20 comments
Open
11 tasks

Platform Request: Oracle Cloud Infrastructure (OCI) #414

chris93111 opened this issue Mar 7, 2020 · 20 comments
Labels
area/platforms cloud* related to public/private clouds

Comments

@chris93111
Copy link

chris93111 commented Mar 7, 2020

Initial request

Hello

I would like use fedora coreos in oracle cloud , i try with vmdk it's work the os boot but i can't login with ssh key or password , i have inderstand cloud-init it's not compatible for inject ign

How i can i do ? It's possible to edit my vmdk for inject a basic ign in waiting better solution ?

Thanks


New platform template

In order to implement support for a new cloud platform in Fedora CoreOS, we need to know several things about the platform. Please try to answer as many questions as you can.

  • Why is the platform important? Who uses it?

  • What is the official name of the platform? Is there a short name that's commonly used in client API implementations?

  • How can the OS retrieve instance userdata? What happens if no userdata is provided?

  • Does the platform provide a way to configure SSH keys for the instance? How can the OS retrieve them? What happens if none are provided?

  • How can the OS retrieve network configuration? Is DHCP sufficient, or is there some other network-accessible metadata service?

  • In particular, how can the OS retrieve the system hostname?

  • Does the platform require the OS to have a specific console configuration?

  • Is there a mechanism for the OS to report to the platform that it has successfully booted? Is the mechanism required?

  • Does the platform have an agent that runs inside the instance? Is it required? What does it do? What language is it implemented in, and where is the source code repository?

  • How are VM images uploaded to the platform and published to other users? Is there an API? What disk image format is expected?

  • Are there any other platform quirks we should know about?

@dustymabe dustymabe changed the title Fedora coreos support for cloud oci Fedora coreos support for cloud oci (Oracle Cloud) Mar 7, 2020
@dustymabe
Copy link
Member

@dustymabe dustymabe added the cloud* related to public/private clouds label Mar 7, 2020
@chris93111
Copy link
Author

baremetal is not available with custom image , coreos.autologin=tty1 it's available in fedora coreos ?

@dustymabe
Copy link
Member

baremetal is not available with custom image ,

you could try using the vmdk and try catching the machine on bootup and supply a ignition.config.url=http://example.com/config.ign kernel arg and see if that works for you.

coreos.autologin=tty1 it's available in fedora coreos ?

see #112

@chris93111
Copy link
Author

no i not see error in boot log , but also i not see load config ignition

@dustymabe kernel arg it's ok ?

'''
load_video
set gfxpayload=keep
insmod gzio
linux ($root)/ostree/fedora-coreos-19190477fad0e60d605a623b86e06bb92aa318b6b79
f78696b06f68f262ad5d6/vmlinuz-5.4.17-200.fc31.x86_64 mitigations=auto,nosmt sy
stemd.unified_cgroup_hierarchy=0 console=tty0 console=ttyS0,115200n8 ostree=/
ostree/boot.1/fedora-coreos/19190477fad0e60d605a623b86e06bb92aa318b6b79f78696b
06f68f262ad5d6/0 ignition.config.url=https://$mybucket/chris.ign
initrd ($root)/ostree/fedora-coreos-19190477fad0e60d605a623b86e06bb92aa318b6b7
9f78696b06f68f262ad5d6/initramfs-5.4.17-200.fc31.x86_64.img
'''

@chris93111
Copy link
Author

@dustymabe thanks the #112 worked for me :D

i tryed ignition.config.url with ignition.firstboot and it's partial work , the url is request but i think the network is not up

@dustymabe
Copy link
Member

i tryed ignition.config.url with ignition.firstboot and it's partial work , the url is request but i think the network is not up

make sure you're also passing rd.neednet=1 and ip=dhcp

@bgilbert
Copy link
Contributor

OCI was briefly supported in Ignition and Afterburn under the platform name oracle-oci. coreos/ignition#537 and coreos/afterburn#86 were the PRs that removed it.

At that time, OCI bare metal nodes (at least) had an iSCSI-based root disk. I don't know if that has changed.

@lucab
Copy link
Contributor

lucab commented Nov 29, 2021

I recently noticed that OCI now offers aarch64 machines on Ampere Altra processors, so I gave it a try (but didn't otherwise check the x86_64 instances).

It looks like the actual instances (VM.Standard.A1.Flex shape) are paravirtualized machines running on qemu/kvm with UEFI support. They support booting through a virtualized "Boot Volume" directly attached to the VM, which allows avoiding the iSCSI mess.
There seem to be advanced options to enable TPM and SecureBoot, but I wasn't able to turn them on (possibly due to a limitation on my account/resources).
I tried all our streams and didn't see particular issues, current stable that I'm running is 35.20211029.3.0 booted through UEFI on a metal image.
I had to bootstrap/install them with coreos-installer through another distro/VM in order to pre-provision the boot volumes for FCOS machines. No particular tricks, other than a --append-karg "ignition.config.url=..." for the Ignition configuration.

Networking goes through DHCP, and it has options to separately provide the hostname and the search-domain. It seems to work fine on FCOS, in the initramfs too (ignition-files stage was happy when fetching some remote resources).
I didn't check the metadata endpoint, but it seems well covered in the docs and overall sane.

There is a JS-based virtual console which can be attached to a VM on demand. It doesn't require extra plugins, it's text-based, and for a quick check it worked quite well.

@dustymabe
Copy link
Member

Thanks @lucab for the insight into the platform!

@travier travier changed the title Fedora coreos support for cloud oci (Oracle Cloud) Platform Request: Oracle Cloud Infrastructure (OCI) Nov 30, 2021
@travier
Copy link
Member

travier commented Nov 30, 2021

Updated to match new platform issue template.

@dominikbayerl
Copy link

dominikbayerl commented Jan 9, 2023

I am currently working on this over here: https://github.com/dominikbayerl/ignition/tree/feat/oraclecloud

I am planning to use the instance metadata service (IMDS) to fetch the extendedMetadata attribute for the VM instance.
Some notes:

  • essentially, all you need is a single cURL request to fetch the configuration. Thus, I am not yet sure, if Ignition is the correct place to add this, or if one should just add a custom systemd-Unit to fetch the config on first boot. Comments on this are very welcome!
  • the extendedMetadata-attribute has a size limit of 32 KB. For larger configurations you'll probably have to use a shim config to load the real configuration from f.e. a HTTP object storage bucket
  • there are also some changes necessary in afterburn to support the handling of network config and SSH keys. No progress on that yet.

@bgilbert
Copy link
Contributor

bgilbert commented Jan 9, 2023

Instance metadata fetch usually only requires a single HTTP request. 🙂 It should still be done in Ignition, though. Note that Ignition and Afterburn previously had support for OCI, so you may be able to dig through the Git history (#414 (comment)) and use the old code as a starting point.

@lucab
Copy link
Contributor

lucab commented Jan 10, 2023

@bgilbert if we re-add support for this platform, do you want to keep the previous platform ID (oracle-oci) or introduce a new one (I see @dominikbayerl's commit is using oraclecloud)?

@bgilbert
Copy link
Contributor

oracle-oci was always kind of awkward. oraclecloud seems reasonable to me.

@travier
Copy link
Member

travier commented Oct 4, 2023

Folks interested for initial support for this platform in Fedora CoreOS should open an issue with the emerging platform template and follow the steps there. Thanks!

@jlebon
Copy link
Member

jlebon commented Nov 6, 2023

Some info re. Oracle Cloud support in #1590 (comment).

Filling in more details mentioned in some of the discussions above. Oracle Cloud has both VM and bare metal shapes/instance types with differences that affect us.

VMs don't require any special handling and just a platform ID restamp should suffice.

For bare metal, the boot disk is exposed as an iSCSI target and the OS must be configured to look for it. This is done with rd.iscsi.firmware=1. Adding ip=ibft is also preferable (that karg is deprecated in favour of rd.iscsi.ibft=1 but Afterburn needs to be enhanced to treat it as it would an ip karg and not emit the default ip=auto karg).

To avoid having to have separate images for each, I think what we could do is have logic that injects rd.iscsi.firmware=1 into /etc/cmdline.d if it detects that we booted off of iSCSI (e.g. iscsiadm -m fw, or just looking at the iBFT parameters in sysfs). To leverage the regular iSCSI activation paths in dracut, that needs to happen before dracut-cmdline.service.

Note that OCP is looking to add support for Oracle Cloud in the near future, but in a way that completely sidesteps this by treating it like a bare metal target (AFAICT you can't boot live ISOs in Oracle Cloud, but they're planning to boot a "live qcow2" for the install phase).

@chris93111
Copy link
Author

Hi @jlebon , i try to boot fedora coreos on OCI Oracle cloud with vm x86_64 and (Openstack Qcow2) but nothing appear as boot
With OCP and rhcos is work correctly nothing is needed just import qcow and boot

They are something needed to do with the plateformID ?

@jlebon
Copy link
Member

jlebon commented Apr 17, 2024

Oracle Cloud is not yet supported as is. In OCP, we actually treat it like a bare metal installation on top of iSCSI. That same logic should work with FCOS, but of course ideally we have proper platform support.

@chris93111
Copy link
Author

it's work on vm, is needed to unpack de xz of the fedora coreos on oci, rhcos is gz

i have now okd on vm with ccm/csi oci without probleme thanks

@travier
Copy link
Member

travier commented Jul 10, 2024

I started documenting what we have in coreos/fedora-coreos-docs#652

travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 16, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 16, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 17, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 17, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 17, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
travier added a commit to travier/fedora-coreos-docs that referenced this issue Jul 23, 2024
Initial documentation to setup FCOS on Oracle Cloud Infrastructure.

See:coreos/fedora-coreos-tracker#414
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/platforms cloud* related to public/private clouds
Projects
None yet
Development

No branches or pull requests

7 participants