-
Notifications
You must be signed in to change notification settings - Fork 60
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
no cloud agents: vmware #70
Comments
For this one it is mostly unfamiliar territory and we'd need a set up environment to experiment and determine what is needed/not needed. We might be able to use packet's ESX servers for this. If that doesn't work then we'd need to access a set up environment. |
In Container Linux:
It appears that the primary benefits of vmtoolsd are:
I think we'll need to address the first point at least, since it seems likely to surprise users if VMware power controls default to hard shutdown/reboot on Fedora CoreOS but not on other distros. On Fedora CoreOS:
|
We are users of CoreOS on VMware in a quite strict environment and I can say that without vmtoolsd we wouldn't get an exception from infra team to run our own image. |
@redbaron Which vmtoolsd functionality do you depend on? As noted, we'd probably disable unnecessary modules. |
One of the vmtoolsd features not listed that I depend on is reporting the IP addresses associated with a given vm. This let's me use the vsphere and/or esx APIs to get associated IPs for follow-on scripted actions. I specifically do this for CI/CD of system deployment scripts. |
As of 4.1 RHCOS ships |
Previously when running CoreOS on VMware it was very nice to have vmtoolsd expose the IP address of the VM, which could then be used as a Terraform output or passed to other resources. Basic Terraform example
|
@kpettijohn that and ansible dynamic inventory is what I'm looking for specifically. |
Network introspection belongs to the "collection of guest metrics on behalf of the host" bucket in the list above. While I understand its usefulness, it isn't (IMHO) a very pressing requirement for the following reasons:
|
Thanks for the feedback @lucab. After looking into things further I think I should be able to get by using the toolbox provided by vmware/govmomi for my use case. Here is a basic usage example that when built and run on a VM hosted by ESX, will register itself as a Guest Managed instance of VMware tools and report the default IP address. |
It would be nice, if FCOS would also ship with |
Also, open-vm-tools would allow a graceful shutdown or reboot of a FCOS VM from the vSphere client or CLI/API. |
I just tried the ova deployment and I dont see any open-vm-tools. So what happened? |
Including it in FCOS by default is not really what we want, because, and I'm quoting from the first comment:
You should be able to install it with:
|
@LorbusChris Great, thanks for the information ... BTW, is there documentation about this? Is there a way to get this "rpm-ostree install open-vm-tools" executed automatically during installation? I did not see something in the description of the ignition files that would allow this? Please correct me if I'm wrong. Thanks! |
This hack more useful instead of "rpm-ostree install open-vm-tools", no reboot needed and possible provision
|
@zotrix Is that container image available somewhere or was that just a proposal? |
I have been using terraforms 'wait for ip' functionality which relies on open-vm-tools when provisioning RHCOS which doesn't work now. Would be nice if it did |
@varesa in private registry, but Dockerfile like in this repo |
I finally came up with this:
This also easily allows to install more packages in one step. |
Hi, We were using CoreOS as underlaying OS for Kubernetes clusters, we try now to move to FCOS, and we encounter this issue with open-vm-tools, workaround requires adding a unit just for installation and a reboot step, that is not very handy ... Like already said, this is required for VM graceful shutdown, vSphere storage provider for K8S, reporting guest metrics, etc ...
If this is a strict decision, Is it possible to re-apply an Ignition file after first boot on FCOS (like for CoreOS) in order to use a tool like Packer to add open-vm-tools extra package? Thanks |
@straffalli why not run in a container (a dockerfile linked above)? Works fine for us. Just add an unit for that, no need to reboot or run Ignition twice |
@varesa does shutdown work on your setup?
|
It does work.
VM starts shutting down and after a minute or so stops |
After installing open-vm-tools with rpm-ostree and rebooting the machine, I'm getting those errors in
The Esxi version is 6.7 is someone face it before? |
@Amos-85 , do you have tried #503 (comment) ? |
@remoe not yet, |
@remoe it's very odd issue. |
@Amos-85 It works with "fedora-coreos-32.20200824.3.0" on ESXi 6.7. I don't have this issue. |
I'm not sure it's relate to the issue, |
This is selected from the official fcos ova template. |
Right now I've succeeded to run open-vm-tools with the container solution @remoe mentioned but now I'm getting other exception relate to perl package in open-vm-tools in
only after installing perl everything work as expected. |
You can also use the official Red Hat image for this My terraform code for this looks like the following. data "ignition_systemd_unit" "open_vm_tools" {
name = "open-vm-tools.service"
enabled = true
content = <<-EOT
[Unit]
Description=Open VM Tools
After=network-online.target
Wants=network-online.target
[Service]
TimeoutStartSec=0
ExecStartPre=-/bin/podman stop open-vm-tools --ignore
ExecStartPre=-/bin/podman rm open-vm-tools --ignore
ExecStartPre=/bin/podman pull registry.access.redhat.com/rhel7/open-vm-tools:latest
ExecStart=/bin/podman run \
--privileged \
--rm \
-v /proc/:/hostproc/ \
-v /sys/fs/cgroup:/sys/fs/cgroup \
-v /var/log:/var/log \
-v /run/systemd:/run/systemd \
-v /sysroot:/sysroot \
-v /etc/passwd:/etc/passwd \
-v /etc/shadow:/etc/shadow \
-v /etc/adjtime:/etc/adjtime \
-v /var/lib/sss/pipes/:/var/lib/sss/pipes/:rw \
-v /tmp:/tmp:rw \
-v /etc/sysconfig:/etc/sysconfig:rw \
-v /etc/resolv.conf:/etc/resolv.conf:rw \
-v /etc/nsswitch.conf:/etc/nsswitch.conf:rw \
-v /etc/hosts:/etc/hosts:rw \
--net=host \
--pid=host \
--ipc=host \
--uts=host \
--name open-vm-tools \
registry.access.redhat.com/rhel7/open-vm-tools:latest
ExecStop=-/usr/bin/podman stop open-vm-tools
ExecStopPost=-/usr/bin/podman rm open-vm-tools
[Install]
WantedBy=multi-user.target
EOT
} You can also create a container image yourself pretty easily via the following Containerfile: FROM registry.fedoraproject.org/fedora-minimal:latesst
ENV SYSTEMD_IGNORE_CHROOT=1
RUN microdnf install -y --nodocs open-vm-tools
CMD ["/usr/bin/vmtoolsd"] |
Built this container image for guest RPC support: https://hub.docker.com/r/arnegroskurth/open-vm-tools |
In #12 we decided that we'd like to try to not ship cloud agents. This ticket will document investigation and strategy for shipping without a cloud agent on the vmware virtualization cloud platform.
See also #41 for a discussion of how to ship cloud specific bits using ignition.
The text was updated successfully, but these errors were encountered: