Description of problem: Plain rpm does not persist after upgrade. 'rpm -[Ui] foo.rpm' can not persist packages after upgrade. Should persist plain rpm('rpm -[Ui] **.rpm') after upgrade. Version-Release number of selected component (if applicable): 1. Before upgrade: redhat-virtualization-host-4.1-0.20170112.1 imgbased-0.9.4-0.1.el7ev.noarch kernel-3.10.0-514.2.2.el7.x86_64 redhat-virtualization-host-image-update-placeholder-4.1-0.5.el7.noarch 2. After upgrade: redhat-virtualization-host-4.1-0.20170116.0 imgbased-0.9.4-0.1.el7ev.noarch kernel-3.10.0-514.2.2.el7.x86_64 redhat-virtualization-host-image-update-4.1-20170116.0.el7_3.noarch How reproducible: 100% Test steps: 1. Install redhat-virtualization-host-4.1-0.20170112.1 2. Reboot and login RHVH4.1, Install kmod-oracleasm-2.0.8-17.el7.x86_64.rpm and check it after installation: # rpm -ivh kmod-oracleasm-2.0.8-17.el7.x86_64.rpm # ls /usr/lib/modules/3.10.0-514.2.2.el7.x86_64/weak-updates/ 3. Setup local repo in RHVH4.1 and upgrade to redhat-virtualization-host-4.1-0.20170116.0: # yum update 4. Reboot and login new build RHVH-4.1-0.20170116.0, check kmod-oracleasm: # ls /usr/lib/modules/3.10.0-514.2.2.el7.x86_64/weak-updates/ Actual results: 1. In step2, install RPM successful: # ls /usr/lib/modules/3.10.0-514.2.2.el7.x86_64/weak-updates/ oracleasm 2. In step4, the RPM installed in step2 are disappeared. # ls /usr/lib/modules/3.10.0-514.2.2.el7.x86_64/weak-updates/ Expected results: 2. In step4, the RPM kmod-oracleasm installed in step2 should be persisted, the check results should be same as step2.
Ryan isn't this already done?
RPMs are persisted in 4.1 through yum plugins (a dnf plugin also exists). We don't tie into `rpm`, though -- the RPM plugin API doesn't provide a way to get at the "actual" package. Instead, ways to hook various RPM transaction steps are provided. We can probably do this with a trivial wrapper around `rpm` which saves RPMs to persist if '-i' or '-U' are seen, and removes if '-e', plus the long versions of those flags.
Closing as wont fix, we provide yum local install and we documented it's the way to persist rpm installation.