Bug 1733325

Summary: ovit-guest-agent system container naming changes
Product: Red Hat Enterprise Linux 7 Reporter: Alex Jia <ajia>
Component: rhel-server-atomicAssignee: Bohdan Khomutskyi <bkhomuts>
Status: CLOSED CURRENTRELEASE QA Contact: atomic-bugs <atomic-bugs>
Severity: medium Docs Contact:
Priority: high    
Version: 7.6CC: bkhomuts, jlebon, miabbott
Target Milestone: rcKeywords: Extras
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Cause: The ovirt-guest-agent is incorrectly tagged. Consequence: The ovirt-guest-agent may not start correctly. Workaround (if any): Tag the existing image correctly and re-install the guest agent. 1. atomic -y containers delete ovirt-guest-agent-1.0.16-30 2. atomic images tag registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30 registry.access.redhat.com/rhev4/ovirt-guest-agent:latest 3. atomic -y images delete registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30 4. atomic install --system registry.access.redhat.com/rhev4/ovirt-guest-agent:latest Result: The ovirt-guest-agent starts successfully.
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-02-16 13:54:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Alex Jia 2019-07-25 17:31:11 UTC
Description of problem:
For details, please see similar bug 1733323, if customers start their RHELAH installs from new cloud images, official document need to be updated - https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux_atomic_host/7/html/managing_containers/running_system_containers#using_the_ovirt_guest_agent_system_container_image_for_red_hat_virtualization

Version-Release number of selected component (if applicable):

$  atomic host status
State: idle; auto updates disabled
Deployments:
● ostree://rhel-atomic-host-ostree:rhel-atomic-host/7/x86_64/standard
                   Version: 7.6.6 (2019-07-24 08:47:27)
                    Commit: 33bb37a7d207ce653eab70306d18deea7daf444b6b7f7aeadef722f96d7e8e6d
              GPGSignature: Valid signature by 567E347AD0044ADE55BA8A5F199E2F91FD431D51

$ sudo runc list
ID                            PID         STATUS      BUNDLE                                                     CREATED                          OWNER
ovirt-guest-agent-1.0.16-30   704         running     /var/lib/containers/atomic/ovirt-guest-agent-1.0.16-30.0   2019-07-25T07:47:21.873093591Z   root


How reproducible:
always

Steps to Reproduce:
1. systemctl status/enable/start/stop/... ovirt-guest-agent


Actual results:


Expected results:


Additional info:

Comment 2 Micah Abbott 2019-07-26 16:44:43 UTC
The workaround for this would be to:

1.  Delete the existing system container that was installed
2.  Tag the container images with `:latest`
3.  Re-install the system container with the `:latest` tag

```
# atomic images list
   REPOSITORY                                           TAG         IMAGE ID       CREATED            VIRTUAL SIZE   TYPE      
>  registry.access.redhat.com/rhev4/ovirt-guest-agent   1.0.16-30   7864d6588cc9   2019-07-24 12:40   79.47 MB       ostree    

# atomic containers list -a --no-trunc
   CONTAINER ID                IMAGE                                                        NAME                        COMMAND                                                           CREATED          STATE     
 BACKEND    RUNTIME   
   ovirt-guest-agent-1.0.16-30 registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30 ovirt-guest-agent-1.0.16-30 /usr/bin/python /usr/share/ovirt-guest-agent/ovirt-guest-agent.py 2019-07-24 12:40 failed    
 ostree     /usr/bin/r

# atomic -y containers delete ovirt-guest-agent-1.0.16-30
The following containers will be deleted.

   ID           NAME                 IMAGE_NAME                STORAGE   
   ovirt-guest- ovirt-guest-agent-1. registry.access.redhat.co ostree    
systemctl disable --now ovirt-guest-agent-1.0.16-30
systemctl daemon-reload
systemd-tmpfiles --remove /etc/tmpfiles.d/ovirt-guest-agent-1.0.16-30.conf

# atomic images tag registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30 registry.access.redhat.com/rhev4/ovirt-guest-agent:latest

# atomic images list
   REPOSITORY                                           TAG         IMAGE ID       CREATED            VIRTUAL SIZE   TYPE      
   registry.access.redhat.com/rhev4/ovirt-guest-agent   latest      7864d6588cc9   2019-07-24 12:40   79.47 MB       ostree    
   registry.access.redhat.com/rhev4/ovirt-guest-agent   1.0.16-30   7864d6588cc9   2019-07-24 12:40   79.47 MB       ostree    

# atomic -y images delete registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30
The following images will be deleted.

   IMAGE                                                          STORAGE
   registry.access.redhat.com/rhev4/ovirt-guest-agent:1.0.16-30   ostree

# atomic images list
   REPOSITORY                                           TAG      IMAGE ID       CREATED            VIRTUAL SIZE   TYPE      
   registry.access.redhat.com/rhev4/ovirt-guest-agent   latest   7864d6588cc9   2019-07-24 12:40   79.47 MB       ostree    

# atomic install --system registry.access.redhat.com/rhev4/ovirt-guest-agent:latest
Extracting to /var/lib/containers/atomic/ovirt-guest-agent.0
systemctl daemon-reload
systemd-tmpfiles --create /etc/tmpfiles.d/ovirt-guest-agent.conf
systemctl enable ovirt-guest-agent

# systemctl status ovirt-guest-agent
● ovirt-guest-agent.service - oVirt Guest Agent Container
   Loaded: loaded (/etc/systemd/system/ovirt-guest-agent.service; enabled; vendor preset: disabled)
   Active: inactive (dead)
```