Odd plugin behaviour after reinstall with complete cleanup

Support and question forum for Patch Remedy 4 WUA plugin for LabTech. This plugin was retired on 06/01/2022. All new Patch Remedy 5 is now the current plugin. This forum is for retaining the old posts for Patch Remedy 4.
kfear
Posts: 11
Joined: Fri Nov 30, 2018 1:07 am
5

Odd plugin behaviour after reinstall with complete cleanup

Post by kfear »

I have recently been trying to get PatchRemedy working properly but have unfortunately been running into issues no matter what I try.

I have followed the steps from this post:
viewtopic.php?f=7&t=5522

I reached the stage where I scheduled the scan time interval and then the clients to scan.
I then hit the master switch to On and then left the plugin window open, about a minute or so later it closed.

I reopened the Patch Remedy plugin and it shows no configuration, the master switch is Off and the version shows as ver 1.0.0.1
If I close LT, delete the DLL from C:\ProgramData\Labtech Plugins\LTSERVERNAME and reopen LT it will download the file again from the server. I reopen the plugin and it shows the correct version but the master switch is on.

Once again if I close the plugin only and reopen it, master switch is off and version is back to 1.0.0.1
Screenshot attached to this post.

To recap I have run the following:
1) Disable PatchRemedy in plugin manager
2) Deleted plugin
3) Restarted DB agent
4) Closed LT
5) Dropped all plugin_sw_patchremedy tables
6) Removed PatchRemedy DLL files from C:\ProgramData\Labtech Plugins\LTSERVERNAME
7) Downloaded latest version from https://delivery.shopifyapps.com/-/fac3 ... 8ecf28bd31
8) Installed plugin
9) Enabled plugin
10) Restarted DB agent when prompted
11) Closed and reopened LT (tested both opening as myself and run as admin)
12) Launched plugin
13) Set scan interval
14) Select all customers
15) Hit save
16) Toggled master switch to On
17) Reopen of plugin clears settings and shows incorrect version
Attachments
patchremedyissue.png
patchremedyissue.png (97.68 KiB) Viewed 12032 times

User avatar
Cubert
Posts: 2456
Joined: Tue Dec 29, 2015 7:57 pm
8
Contact:

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by Cubert »

Wow,

Ok so I sure I understand.

So before step 13 you show an accurate plugin version number, but after step 13 you relaunch a completely blank PR?

I have never seen that before so not sure how that is. We have seen the Automate caching issue where on first days install a MSP would set all switches on and relaunch and switches would be off (but settings are still on in DB even though switch said off). This would self clear and stop displaying off after the LT database went through a standard maintenance cycle which is set to happen daily at night.

The fact that the plugin loads with no version number is really bizarre and I suspect it is related to some environment issue in Automate.

I do assume you show a valid license when the plugin is first launched? You do not get a pop up that license is expired?

Next if license is good then do not manually run any scans but instead, turn on master switch only leaving other 2 switches off.

Enable clients and set scan interval to 4. Allow 24 hours for it to run across the environments and then launch plugin and see if data exists. Just turning on master switch lets the plugin scan agents but will not do anything to agents. Totaly safe to leave on and will not affect environments.

kfear
Posts: 11
Joined: Fri Nov 30, 2018 1:07 am
5

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by kfear »

Hi Cubert,

I've come in this morning and these are the steps and results given:

1. Opened LT fresh (not previously open)
2. Opened PatchRemedy plugin
3. Version # is correct
4. All switches are off
5. No popup, license valid through to 8th Jan 2019
6. Turned ON master switch
7. Closed PatchRemedy plugin
8. Reopened PatchRemedy
9. Master switch OFF, all config gone.
10. Version showing as 1.0.0.1
11. Configure Tab shows license expired

Any ideas on how to move forward?

Thanks!

User avatar
Cubert
Posts: 2456
Joined: Tue Dec 29, 2015 7:57 pm
8
Contact:

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by Cubert »

Yea, that's not a plugin issue from our side, you must have some environment issue with the LT database. The plugin on every open does several things

#1 checks license, If invalid it pops up a invalid license and then stops.

#2 Loads roughly 10 to 15 SQL queries

#3 Displays the data queried from #2


Seeing that you opening the plugin and not getting a pop up straight away means the license made it.

So we are stopping at #2. One of the first queries is for plugin version # followed by query to see if switches should show on or off and many others to collect data to display.

Can you look at server logs to see if you see SQL failures right after you relaunch plugin (trying to get it to fail)

Do you see anything in logs that would show Patch Remedy having issues loading data?

User avatar
Cubert
Posts: 2456
Joined: Tue Dec 29, 2015 7:57 pm
8
Contact:

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by Cubert »

Secondly,

If you go directly to LTHost and run console off of host does the same issues arise? It maybe the LT client console on your workstation that is having the issues with the plugin and not the system as a whole.


Give that a try as well and report back your findings.

kfear
Posts: 11
Joined: Fri Nov 30, 2018 1:07 am
5

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by kfear »

Hi Cubert,

I've tested this on multiple other machines and we have the same behaviour.
I checked the LT server logs, both provided by the LT Server software and within the LT Server Event Logs.

There is nothing being logged that would be causing this issue in either locations.

I even reached out to LT support and they ran their toolkit over our server and made some changes and optimised things but we are still in the same boat.

Not too sure where to go from here..

Edit:
I found some error logs, it happens on multiple machines:

Dispatcher Exception: Could not load file or assembly 'DevExpress.XtraCharts.v12.2, Version=12.2.17.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a' or one of its dependencies. The system cannot find the file specified.
Stacktrace:
at PatchRemedy.ToolsForm.InitializeComponent()
at PatchRemedy.ToolsForm..ctor(IControlCenter objClient)
at PatchRemedy.clsMenus.ShowApprovalForm(Object sender, EventArgs e)
at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
at System.Windows.Forms.MenuItem.PerformClick()
at LTClient.ControlCenter.ViewModels.ControlCenterSideNavViewModel.WinFormItemSupportCommand.Execute(Object parameter)
at LabTechPresentation.Controls.CategoryExplorer.CategoryExplorer.TreeViewItem_MouseLeftButtonUp(Object sender, MouseEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
v120.473

ID:Unhandled thread exception Name:loadSettings MSG:Object reference not set to an instance of an object. STACK: at PatchRemedy.ToolsForm.loadSettings()
at PatchRemedy.ToolsForm.MainMenuForm_Load(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) v120.473

ID:Unhandled thread exception Name:InvokeMethod MSG:Object reference not set to an instance of an object. STACK: at Microsoft.VisualBasic.CompilerServices.Symbols.Container.InvokeMethod(Method TargetProcedure, Object[] Arguments, Boolean[] CopyBack, BindingFlags Flags)
at Microsoft.VisualBasic.CompilerServices.NewLateBinding.CallMethod(Container BaseReference, String MethodName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, BindingFlags InvocationFlags, Boolean ReportErrors, ResolutionFailure& Failure)
at Microsoft.VisualBasic.CompilerServices.NewLateBinding.ObjectLateCall(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, Boolean IgnoreReturn)
at Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateCall(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, Boolean IgnoreReturn)
at PatchRemedy.ToolsForm.MainMenuForm_Load(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) v120.473

User avatar
Cubert
Posts: 2456
Joined: Tue Dec 29, 2015 7:57 pm
8
Contact:

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by Cubert »

Interesting.. So your missing a DevExpress Library file.

When a user is missing this file the plugin should not launch at all. So the fact that it launches and opens both with info and without is very odd. Maybe this is a new behavior not seen before when libs are missing.

So lets try this to correct the libs issue.

viewtopic.php?f=55&t=5518

First see if just copying the libs will do, if not run the lib installer in "Demo" mode and that will resolve the lib issue.

Then lets see if that has any effect on your other issue.

kfear
Posts: 11
Joined: Fri Nov 30, 2018 1:07 am
5

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by kfear »

Hi Cubert,

I copied the files into the \LabTech Client\ folder and overwrote the files there.
When trying to launch the plugin event viewer shows:

Dispatcher Exception: Could not load file or assembly 'DevExpress.XtraCharts.v12.2, Version=12.2.17.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a' or one of its dependencies. The module was expected to contain an assembly manifest.
The module was expected to contain an assembly manifest. (Exception from HRESULT: 0x80131018)
Stacktrace:
at PatchRemedy.ToolsForm.InitializeComponent()
at PatchRemedy.ToolsForm..ctor(IControlCenter objClient)
at PatchRemedy.clsMenus.ShowApprovalForm(Object sender, EventArgs e)
at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
at System.Windows.Forms.MenuItem.PerformClick()
at LTClient.ControlCenter.ViewModels.ControlCenterSideNavViewModel.WinFormItemSupportCommand.Execute(Object parameter)
at LabTechPresentation.Controls.CategoryExplorer.CategoryExplorer.TreeViewItem_MouseLeftButtonUp(Object sender, MouseEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
v120.473

I then downloaded the DevExpress installer and tried to install. It errored showing:
Cannot register types for eXpressAppFramework assembly

After googling this error DevExpress said this shows if VS C++ 2005 is missing or has errors. I can see this installed in my Programs and Features but I found an express edition and installed this.

I checked the plugin, still having the same issues so I reran the DevExpress installation in a repair install, we get the same error: Cannot register types for eXpressAppFramework assembly

I then found VC++ 2005 x86 and x64 Redistributable packages and installed them both from here:
https://www.microsoft.com/en-au/downloa ... px?id=3387
https://www.microsoft.com/en-AU/downloa ... x?id=21254

I uninstalled DevExpress and reinstalled it, we get the same error.

I decided to test on another machine that had never previously had LT installed on it.
Prior to installing I can see this only has VSC++ 2008 and 2015 redistributables.

While installing LT installs the other VC++ redistributables, 2005 (both x86 and x64) and 2013 x86.
I logged in and launched the control centre - This has pulled the DevExpress files into the \LabTech Client\ folder.
I've gone to run the PatchRemedy plugin and Event Viewer shows:

Dispatcher Exception: Could not load file or assembly 'DevExpress.XtraCharts.v12.2, Version=12.2.17.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a' or one of its dependencies. The system cannot find the file specified.
Stacktrace:
at PatchRemedy.ToolsForm.InitializeComponent()
at PatchRemedy.ToolsForm..ctor(IControlCenter objClient)
at PatchRemedy.clsMenus.ShowApprovalForm(Object sender, EventArgs e)
at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
at System.Windows.Forms.MenuItem.PerformClick()
at LTClient.ControlCenter.ViewModels.ControlCenterSideNavViewModel.WinFormItemSupportCommand.Execute(Object parameter)
at LabTechPresentation.Controls.CategoryExplorer.CategoryExplorer.TreeViewItem_MouseLeftButtonUp(Object sender, MouseEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
v120.473

The plugin did not show either - Testing any other plugins these show.
I didn't mention this earlier as I thought it was just a glitch which wasn't too much of a concern but I will mention it now.

If you follow these steps:
1) Open LT client
2) Attempt to launch PatchRemedy plugin - Error shows in Event Viewer (as shown above) and the plugin doesn't pop up
3) Open another plugin - Works fine
4) Go back to open PatchRemedy - Opens fine
5) Close and reopen PatchRemedy - Version resets to 1.0.0.1 and no config

You can repeat the same steps on any machine and it has the same result.
The latest machine we tested on does not have AV, for the machines we tested on that did have AV we scoured the logs and there is nothing.

On the new system without AV, I tried installing the DevExpress in trial installation - We have the same error of Cannot register types for eXpressAppFramework assembly.

So we have several computers, physical and virtual, some with and some without AV, in different locations and different operating systems all with the same issues.

Any idea on where to go from here ?

User avatar
Cubert
Posts: 2456
Joined: Tue Dec 29, 2015 7:57 pm
8
Contact:

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by Cubert »

The fact that you can not install that package is extremely odd, You are the first in over 50 cases where one or the other did not resolve issues and work straight away. What's more bizarre is that trying the installs on several systems produces the same issues.

Not really sure where to go from here, let me go look anything on my end that can be done.

kfear
Posts: 11
Joined: Fri Nov 30, 2018 1:07 am
5

Re: Odd plugin behaviour after reinstall with complete cleanup

Post by kfear »

Hi Cubert,

Any updates?

Thanks

Post Reply

Return to “Patch Remedy for LabTech (Patch Remedy 4) Retired”