PPM Install and Uninstall Improvements

Moderator: Forum moderators

Post Reply
User avatar
rerwin
Posts: 156
Joined: Fri Jul 17, 2020 4:35 pm
Location: Maine, USA
Has thanked: 1 time
Been thanked: 82 times

PPM Install and Uninstall Improvements

Post by rerwin »

@radky @Marv @jrb
Although the version of the Puppy Package Manager adapted for Debian and the Overlay file system omits some of the expected functions of the legacy version, I offer fixes for the issues in the attached package.

There are two regressions in the installer, both fixed by a one-line change. The timestamps of installed files get overridden by the time of installation. The other issue relates to the handling of files that replace a symlink: If the old version of a file is actually a link, the file gets installed to the target of that old link!

Both issues are due to the copying of the expanded tarball to the install locations and are resolved by changing the copy (cp) command from:
cp -fr ${WKDIR}/* /
to:
cp -ar --remove-destination ${WKDIR}/* /

The uninstall regression is that uninstalled files that replaced files that are part of the installation are not replaced by the original versions. This leaves the installation versions unusable because the files are missing.

The problem with the Overlay file system is that it is impacted by changes to an individual layer of the layered file system, which the aufs (and its predecessor) tolerated. My solution merely changes the visible (or deleted) files, to restore the old version of a file. Deleted files are represented by zero-length, no-permission files that cannot be deleted without damaging the layered file system.

With that technique, though, installation files that a package deleted will be copied from the installation to the pupsave file/directory, whereas with aufs the "whiteout" indicator was simply deleted from the second layer of the file system as well as the top layer, to expose the installation-layer copy.

With the uninstall fix, save-file space is not recovered as it was. I am considering a way to recover the space during the next reboot.

If anyone has reservations about the uninstall changes, please post them.

Note that installing the package will initially fail but will succeed if you immediately install it again. This is because the package changes the install script while it is installing that package; the second install uses the new version.

Richard

Attachments
petget_fixes-20240124.pet
(26.03 KiB) Downloaded 29 times
diff-petget_overlay_fixes-20240124.txt
(6.22 KiB) Downloaded 14 times
Last edited by rerwin on Thu Jan 25, 2024 1:13 am, edited 1 time in total.
User avatar
rerwin
Posts: 156
Joined: Fri Jul 17, 2020 4:35 pm
Location: Maine, USA
Has thanked: 1 time
Been thanked: 82 times

Re: PPM Install and Uninstall Improvements Update

Post by rerwin »

@radky @Marv @jrb
I have updated the fix package (above) to correct the uninstalling of directories.

The beta restored directories of built-in packages into the wrong place -- into itself!

Anyone seeing this problem can simply delete the incorrectly restored directory, reinstall the same package and then uninstall it with the new petget package.

To install the new petget package:

  • Uninstall the beta version, which probably will not be acknowledged because the script gets changed before it can display the result. Ignore that misbehavior.

  • Install the new petget package, which will appear to fail but will succeed on the second install.

Please tell me of any new issues with this version of petget/PPM.

Richard

User avatar
bigpup
Moderator
Posts: 7298
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 951 times
Been thanked: 1615 times

Re: PPM Install and Uninstall Improvements

Post by bigpup »

If you are trying to fix issues with the PPM in BookwormPup64

In the Uninstall.

If you click on a listed item and select remove package.
It does get removed.
But it is still listed in uninstall list.
The list does not update.

To update the uninstall list you have to close PPM and restart it.

Now the uninstall list is updated to what is still installed.

This is still an issue after installing the petget_fixes-20240123.pet

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

User avatar
rerwin
Posts: 156
Joined: Fri Jul 17, 2020 4:35 pm
Location: Maine, USA
Has thanked: 1 time
Been thanked: 82 times

Re: PPM Install and Uninstall Improvements

Post by rerwin »

Thanks, bigpup, for mentioning the uninstall list issue, which appears to have been around for several years.

I have fixed the problem and uploaded the new package (petget_fixes-20240124.pet). That is the only change.

Richard

User avatar
bigpup
Moderator
Posts: 7298
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 951 times
Been thanked: 1615 times

Re: PPM Install and Uninstall Improvements

Post by bigpup »

I can confirm that petget_fixes-20240124.pet fixed it.

Uninstall list updates, when an item is removed by selecting remove package.

That was a fix that very much was needed.

Before, with the list not updating, it made you wonder if it really did get uninstalled.

Thanks!

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

Post Reply

Return to “BookwormPup”