Bug 728369

Summary: ClassNotFoundExeption with Apache plugin trying to configure
Product: [Other] RHQ Project Reporter: Mike Foley <mfoley>
Component: PluginsAssignee: Nobody <nobody>
Status: NEW --- QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 4.1CC: hrupp
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 729848    

Description Mike Foley 2011-08-04 20:34:01 UTC
Description of problem: ClassNotFoundExeption with Apache plugin trying to configure


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.  Inventory, Apache Servers, Configuration Tab
2.
3.
  
Actual results:


Expected results:


Additional info:
org.rhq.core.clientapi.agent.PluginContainerException: Could not build component for Resource [Resource[id=10057, type=Apache HTTP Server, key=/etc/httpd||/etc/httpd/conf/httpd.conf, name=10.0.1.189:80, parent=foleymonsterbox1.foleyhomenetwork, version=2.2.17]]
	at org.rhq.core.pc.inventory.InventoryManager.prepareResourceForActivation(InventoryManager.java:1479)
	at org.rhq.core.pc.inventory.InventoryManager.activateResource(InventoryManager.java:1562)
	at org.rhq.core.pc.inventory.InventoryManager.updatePluginConfiguration(InventoryManager.java:527)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)
	at org.rhq.enterprise.communications.command.impl.remotepojo.server.RemotePojoInvocationCommandService.execute(RemotePojoInvocationCommandService.java:184)
	at sun.reflect.GeneratedMethodAccessor964.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)
	at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(StandardMBeanIntrospector.java:111)
	at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(StandardMBeanIntrospector.java:45)
	at com.sun.jmx.mbeanserver.MBeanIntrospector.invokeM(MBeanIntrospector.java:226)
	at com.sun.jmx.mbeanserver.PerInterface.invoke(PerInterface.java:138)
	at com.sun.jmx.mbeanserver.MBeanSupport.invoke(MBeanSupport.java:251)
	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:857)
	at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:795)
	at javax.management.MBeanServerInvocationHandler.invoke(MBeanServerInvocationHandler.java:305)
	at $Proxy0.execute(Unknown Source)
	at org.rhq.enterprise.communications.command.server.CommandProcessor.handleIncomingInvocationRequest(CommandProcessor.java:290)
	at org.rhq.enterprise.communications.command.server.CommandProcessor.invoke(CommandProcessor.java:184)
	at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:809)
	at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:608)
	at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:406)
	at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:173)
Caused by: java.lang.NoClassDefFoundError: org/rhq/augeas/AugeasComponent
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:264)
	at org.rhq.core.pc.plugin.PluginComponentFactory.instantiateClass(PluginComponentFactory.java:246)
	at org.rhq.core.pc.plugin.PluginComponentFactory.buildResourceComponent(PluginComponentFactory.java:150)
	at org.rhq.core.pc.inventory.InventoryManager.prepareResourceForActivation(InventoryManager.java:1477)
	... 25 more
Caused by: java.lang.ClassNotFoundException: org.rhq.augeas.AugeasComponent
	at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
	at org.rhq.core.pc.plugin.PluginClassLoader.loadClass(PluginClassLoader.java:63)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
	... 30 more

Comment 1 Mike Foley 2011-09-07 15:03:03 UTC
*** Bug 736136 has been marked as a duplicate of this bug. ***

Comment 2 Lukas Krejci 2011-09-08 13:14:06 UTC
The exception is very strange. It might be caused by a failure to initialize or even find the augeas native libs or augeas binding library or the RHQ augeas plugin none of which should ever happen when initializing resources from the apache plugin.

Mike, could you please try and provide more detailed repro steps for this? Was this discovered on a Linux/Unix/Windows box? I'm especially interested in what plugins were deployed, what and how many apache instances were inventoried and if the agent installation wasn't tampered with.

I can't see how the provided repro steps would directly trigger this error. I think it was more of an accidental match.

Comment 3 Lukas Krejci 2011-09-08 13:15:21 UTC
Also I re-opened bug 736136 because it most definitely isn't a duplicate of this bug.