Jira (PUP-10616) Windows: package doesn't pass uninstall_options to uninstaller

17 views
Skip to first unread message

Dirk Heinrichs (Jira)

unread,
Aug 11, 2020, 6:51:02 AM8/11/20
to puppe...@googlegroups.com
Dirk Heinrichs created an issue
 
Puppet / Bug PUP-10616
Windows: package doesn't pass uninstall_options to uninstaller
Issue Type: Bug Bug
Affects Versions: PUP 6.17.0
Assignee: Unassigned
Components: Types and Providers
Created: 2020/08/11 3:50 AM
Priority: Major Major
Reporter: Dirk Heinrichs

Puppet Version: 6.17.0
Puppet Server Version: 6.12.1
OS Name/Version: Windows

In order to uninstall a package from Windows agent, I created a package resource, which also included specific "uninstall_options" for the package. While the correct uninstaller ("...\uninstall.exe", as recorded in the registry) was executed, the package wasn't uninstalled. I checked with Process Explorer and found that the uninstaller was called w/o any option. So I ended up using an exec resource...

 

package {'Sentinel Agent':
 
  ensure            => absent,
 
  uninstall_options => ['/uninstall', '/norestart', '/q', "/k=\"${unlock_key}\""],
 
}

 

Desired Behavior:

Puppet should have uninstalled the package by passing the correct options to the uninstaller.

Actual Behavior:

Options were not passed, which lead to package not being uninstalled. (Maybe related: There was also no error in the report, but that might have been caused by the uninstaller itself, which might not have reported one).

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)
Atlassian logo

Dirk Heinrichs (Jira)

unread,
Aug 11, 2020, 6:52:03 AM8/11/20
to puppe...@googlegroups.com
Dirk Heinrichs updated an issue
Change By: Dirk Heinrichs
*Puppet Version: 6.17.0*
*Puppet Server Version: 6.12.1*
*OS Name/Version: Windows*


In order to uninstall a package from Windows agent, I created a package resource, which also included specific "uninstall_options" for the package. While the correct uninstaller ("...\uninstall.exe", as recorded in the registry) was executed, the package wasn't uninstalled. I checked with Process Explorer and found that the uninstaller was called w/o any option. So I ended up using an exec resource...

 
{code:java}
package {'Sentinel Agent':

  ensure            => absent,

  uninstall_options => ['/uninstall', '/norestart', '/q', "/k=\"${unlock_key}\""],

}
{code}
 

*Desired Behavior:*


Puppet should have uninstalled the package by passing the correct options to the uninstaller.

*Actual Behavior:*


Options were not passed, which lead to package not being uninstalled. (Maybe related: There was also no error in the report, but that might have been caused by the uninstaller itself, which might not have reported one).

Dirk Heinrichs (Jira)

unread,
Aug 11, 2020, 6:52:04 AM8/11/20
to puppe...@googlegroups.com

Dirk Heinrichs (Jira)

unread,
Aug 11, 2020, 6:55:03 AM8/11/20
to puppe...@googlegroups.com
Dirk Heinrichs updated an issue
*Puppet Version: 6.17.0*
*Puppet Server Version: 6.12.1*
*OS Name/Version: Windows*

In order to uninstall a package from Windows agent agents , I created a package resource, which also included specific "uninstall_options" for the package. While the correct uninstaller ("...\uninstall.exe", as recorded in the registry) was executed, the package wasn't uninstalled. I checked with Process Explorer and found that the uninstaller was called w/o any option. So I ended up using an exec resource...

{code:java}package {'Sentinel Agent':
  ensure => absent,
  uninstall_options => ['/uninstall', '/norestart', '/q', "/k=\"${unlock_key}\""],
}
{code}
 

*Desired Behavior:*

Puppet should have uninstalled the package by passing the correct options to the uninstaller.

*Actual Behavior:*

Options were not passed, which lead to package not being uninstalled. (Maybe related: There was also no error in the report, but that might have been caused by the uninstaller itself, which might not have reported one).

Mihai Buzgau (Jira)

unread,
Aug 12, 2020, 2:08:04 AM8/12/20
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
Aug 12, 2020, 2:08:04 AM8/12/20
to puppe...@googlegroups.com

Bogdan Irimie (Jira)

unread,
Nov 5, 2020, 3:51:04 AM11/5/20
to puppe...@googlegroups.com

Bogdan Irimie (Jira)

unread,
Nov 5, 2020, 3:52:05 AM11/5/20
to puppe...@googlegroups.com

Ciprian Badescu (Jira)

unread,
Jun 22, 2021, 3:58:02 AM6/22/21
to puppe...@googlegroups.com
Ciprian Badescu updated an issue
Change By: Ciprian Badescu
Sprint: ready for triage
This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97)
Atlassian logo

Josh Cooper (Jira)

unread,
Jul 26, 2022, 5:07:01 PM7/26/22
to puppe...@googlegroups.com
Josh Cooper commented on Bug PUP-10616
 
Re: Windows: package doesn't pass uninstall_options to uninstaller

I can't reproduce this and the code shows we append the uninstall options to the uninstall command, where the uninstall command is taken from the registry.

https://github.com/puppetlabs/puppet/blob/7e6e6c03b28b263548c26288cfa3a4fa5e1d71ce/lib/puppet/provider/package/windows.rb#L89

Please reopen with steps to reproduce including the manifest and output of puppet agent -t --debug..

This message was sent by Atlassian Jira (v8.20.11#820011-sha1:0629dd8)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages