Bug 151421 - Installer can't delete Desktop Shortcut
Summary: Installer can't delete Desktop Shortcut
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Installation (show other bugs)
Version:
(earliest affected)
7.3.5.2 release
Hardware: All Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 150995
  Show dependency treegraph
 
Reported: 2022-10-08 12:32 UTC by bugzilla2
Modified: 2022-10-08 12:40 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
The whole uninstall logfile (zipped) (527.73 KB, application/zip)
2022-10-08 12:40 UTC, bugzilla2
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bugzilla2 2022-10-08 12:32:08 UTC
Description:
[EN]
In some situations the Uninstaller is unable to remove the Desktop-Shortcut from the public desktop. The unintall-process runs normally up to the moment when the desktop-icon should be removed and runs backward from that point, because the removal of the icon fails. In the logfile of the uninstaller (see [COMMON – Logfile Exerpt]) that there is no write-access to the public-desktop-folder, but that is not true. The uninstaller runs within the User-Account and is elevated. In this context it is no problem to create or remove files in the public desktop folder (this has been tested to be sure). Therefore, I do not understand, why the uninstaller is unable to remove the desktop-shortcut. The problem does not arise on 100% of uninstallations, but with 7.3.5 it happens extremely often compared to previous LibreOffice versions.

When the uninstallation of the old version is unsuccessfully, the installation of the new version also fails. Before I knew, that the reason for the problems is within uninstallation, I created Bug 150995, which very detailed describes the problems with the installation of the new version, when this problem happens before. Even though I marked that bug as „worksforme me – moved“ now, it still contains informations that might be useful.

Currently, I work around this issue by deleting the desktop-icon via script before the actual uninstallation. This way, uninstallation of the old version and installation of the new version works flawlessly. Nevertheless, I think this bug should be resolved at root, because it's not impossible that “normal” installations/upgrades might be affected by that problem too.

Remark to System-Environment: The “public”-folder on this systems is not on the default path „C:\Users\Puplic“ but on a separate partition. According to the logfile the uninstaller is aware if that and trys to delete the file from the right folder. The ACL’s on the folder and files are ok. Nevertheless, the “non default environment” might factor into the problem somehow.

PS: Driveletters and Names in the Logfile are changed for security reasons. The 3rd Party Virus-Scan was OFF during the tests, to make sure it doesn’t interfere with the uninstall-process.


[DE]
In manchen Situationen scheitert der Uninstaller daran die Desktop-Verknüpfung zu LibreOffice zu entfernen. Die Deinstallation läuft ganz normal bis zu dem Punkt wo das Desktop-Icon entfernt werden soll und wird dann wieder rückgängig gemacht, weil die Entfernung des Icons/Verknüpfung fehlschlägt. Im Logfile des Uninstallers (siehe [COMMON – Logfile Exerpt]) steht, dass kein Schreibzugriff auf den gemeinsamen Desktop-Ordner besteht, das ist jedoch falsch. Der Uninstaller wird im Kontext des Benutzers ausgeführt und ist „elevated“ (läuft also mit Admin-Rechten). In diesem Kontext ist es problemlos möglich Dateien im gemeinsamen Desktop-Ordner anzulegen oder zu löschen (wurde auch explizit nochmal getestet um sicherzugehen). Ich verstehe also nicht, warum der (Un)Installer in dem Moment behauptet er hätte keinen Schreibzugriff. Das Phänomen tritt auch nicht in 100% der Deinstallationen auf, wenngleich es bei 7.3.5 nun sehr häufig passiert (bei früheren LibO Versionen trat es auch auf, aber so selten, dass ich dem nie gezielt nachgehen konnte).

Dadurch, dass die Deinstallation der alten Version nicht erfolgreich ist, läuft dann auch die Installation der neuen Version nicht fehlerfrei durch. Bevor ich die Ursache kannte, hatte ich daher bereits Bug 150995 erstellt, wo detailliert beschrieben ist wie die Installation fehlschlägt eben wegen dieses Fehlers. Obwohl der Bug mittlerweile von mir als „worksforme – moved“ deklariert wurde, enthält er ev. wertvolle Informationen über das Problem.

Das Problem wird jetzt aktuell so umgangen, das vor der Deinstallation der alten Version die Desktop-Verknüpfung bereits vom Update-Skript gelöscht wird. Damit läuft die Deinstallation der alten und Installation der neuen Version problemlos durch. Nichtsdestotrotz sollte der zugrunde liegende Bug behoben werden, da es potenziell auch manuelle Updates betreffen kann.

Anmerkungen zur System-Umgebung: Auf den betroffenen Systemen liegt der „Public“-Ordner nicht auf „C:\Users\Puplic“ sondern auf einer eigenen Partition. Der Installer weiß das aber (siehe Logfiles) und versucht die Datei auch aus dem richtigen Ordner zu entfernen. Auch die ACL’s des Ordner und der Verknüpfung sind einwandfrei. Nichtsdestotrotz ist diese Abweichung von der Norm möglicherweise ein Faktor der da mit hineinspielt.

PS: Namen und Laufwerksbuchstaben wurden in der Logdatei aus Sicherheitsgründen geändert. Der Virenscanner war bei dem Test deaktiviert um sicherzugehen, dass dieser nicht das löschen der Datei beeinträchtigt.


[COMMON – Logfile Exerpt]
MSI (s) (34:04) [15:55:43:059]: SHELL32::SHGetFolderPath returned: X:\Users\Public\Desktop
MSI (s) (34:04) [15:55:43:059]: Executing op: ShortcutRemove(Name=LIBREO~9|LibreOffice 7.3)
MSI (s) (34:04) [15:55:43:059]: Note: 1: 1402 2: HKEY_CLASSES_ROOT\.3 3: 2 
MSI (s) (34:04) [15:55:43:059]: Backup folder is created by user
MSI (s) (34:04) [15:55:43:059]: Verifying accessibility of file: LibreOffice 7.3.lnk
MSI (s) (34:04) [15:55:43:059]: Using source file security for destination.
MSI (s) (34:04) [15:55:43:075]: Note: 1: 1310 2: 5 3: X:\Users\Public\Desktop\5dae5.rbf 
MSI (s) (34:04) [15:55:43:075]: Transforming table Error.

MSI (s) (34:04) [15:55:43:075]: Transforming table Error.

MSI (s) (34:04) [15:55:43:075]: Produkt: LibreOffice 7.3.5.2 – Fehler 1310.Fehler beim Schreiben in die Datei: X:\Users\Public\Desktop\5dae5.rbf.  Systemfehler 5. Überprüfen Sie, ob Sie Zugriff auf das Verzeichnis haben.

Steps to Reproduce:
1. Uninstall LibreOffice

Actual Results:
Uninstall fails

Expected Results:
Uninstall should not fail


Reproducible: Sometimes


User Profile Reset: No



Additional Info:
Comment 1 bugzilla2 2022-10-08 12:40:46 UTC
Created attachment 182914 [details]
The whole uninstall logfile (zipped)