[midPoint] [External] Re: [EXTERNAL SENDER] Midpoint 4.8 Configuration error: JDBC Driver is not found on classpath.
lazy tech
huutm at lazytech.biz.vn
Sat Nov 25 10:54:41 CET 2023
Hi all,Following Robert and Jean's instructions I was able to fix the error.Thank you.Huutm ---- On Fri, 24 Nov 2023 23:31:30 +0700 Drew Roberts via midPoint<midpoint at lists.evolveum.com> wrote ---- Hey Huutm,In your initial email you talked about installing Tomcat (which I believe is optional, depending on what you're doing) but I don't see you mention actually getting the .jar file for the JDBC driver and putting it in the directory.I'm not using a MySQL resource but I use an Oracle DB and I have this bit in my Containerfile (Dockerfile):
FROM quay.apu.edu/mirrors/midpoint:4.8-support-alpine
# Oracle Driver
ARG JRE_VERSION=8
ARG ORCL_VERSION=19.14.0.0
ADD https://repo1.maven.org/maven2/com/oracle/database/jdbc/ojdbc${JRE_VERSION}/${ORCL_VERSION}/ojdbc${JRE_VERSION}-${ORCL_VERSION}.jar /opt/midpoint/var/lib/
So you just need to recreate that for whatever version of MySQL driver you want and make sure it gets put in the correct directory, E.G.:
FROM quay.apu.edu/mirrors/midpoint:4.8-support-alpine
# MySQL Driver
ARG MYSQL_VERSION=8.2.0
ADD https://repo1.maven.org/maven2/com/mysql/mysql-connector-j/${MYSQL_VERSION}/mysql-connector-j-${MYSQL_VERSION}.jar /opt/midpoint/var/lib/
Pick any version from the list on https://mvnrepository.com/artifact/com.mysql/mysql-connector-j and that should work.Sorry if this is redundant information, just wanted to make sure you were starting with the JDBC Driver actually being there.On Fri, Nov 24, 2023 at 7:39 AM Jean Michel via midPoint <midpoint at lists.evolveum.com> wrote:
Hi,
In general, I copy my JDBC drivers to $MIDPOINT_HOME/lib or
/opt/midpoint/lib and it works.
Then I test the connector without restart Midpoint, but you can
restart if you want to.
Best regards,
Jean Santos
Analista de Sistema
Linha Passo das Tropas, 3600 - Encruzilhada do Sul, RS
Office: +55 (11) 3042-5610 / +55 (51) 4042-8153
https://ebz.tec.br
----------------------------------------------------------------------
Message: 1
Date: Fri, 24 Nov 2023 14:37:01 +0000
From: "King, Robert" <robk at mun.ca>
To: lazy tech <huutm at lazytech.biz.vn>, midPoint General Discussion
<midpoint at lists.evolveum.com>
Subject: Re: [midPoint] [EXTERNAL SENDER] Midpoint 4.8 Configuration
error: JDBC Driver is not found on classpath.
Message-ID:
<DS7PR17MB673095317A244BE59D2B4611B4B8A at DS7PR17MB6730.namprd17.prod.outlook.com>
Content-Type: text/plain; charset="utf-8"
I do not have any experience with the docker container. Unfortunately.
From: lazy tech <huutm at lazytech.biz.vn>
Sent: Friday, November 24, 2023 10:20 AM
To: midPoint General Discussion <midpoint at lists.evolveum.com>
Cc: King, Robert <robk at mun.ca>
Subject: Re: [midPoint] [EXTERNAL SENDER] Midpoint 4.8 Configuration error: JDBC Driver is not found on classpath.
Hi Robert,
Yes, I'm using docker. I looked at demo.evolveum.com/midpoint and got the same error. Are your instructions applicable to docker?
Thank you.
Huutm
---- On Fri, 24 Nov 2023 20:36:09 +0700 King, Robert via midPoint<midpoint at lists.evolveum.com<mailto:midpoint at lists.evolveum.com>> wrote ----
Are you using the distribution or docker image for running your Midpoint 4.8 install?
For the distribution install on a RHEL box:
Midpoint HOME directory set to : /opt/midpoint (substitute for where ever you have it on your system)
Copy the mysql-connector jar to : /opt/midpoint/var/lib/
Make sure the midpoint user owns the file and the permissions are readable by user.
Restart midpoint.
Look in your /opt/midpoint/var/log/midpoint.log and make sure that you see the mysql connector is loaded.
From: midPoint <midpoint-bounces at lists.evolveum.com<mailto:midpoint-bounces at lists.evolveum.com>> On Behalf Of lazy tech via midPoint
Sent: Thursday, November 23, 2023 11:46 PM
To: midPoint General Discussion <midpoint at lists.evolveum.com<mailto:midpoint at lists.evolveum.com>>
Cc: lazy tech <huutm at lazytech.biz.vn<mailto:huutm at lazytech.biz.vn>>
Subject: [EXTERNAL SENDER] [midPoint] Midpoint 4.8 Configuration error: JDBC Driver is not found on classpath.
Hi team,
I am creating a new resource connected to the MySQL database using the connector on Midpoint 4.8 but I get the error: Configuration error: JDBC Driver is not found on classpath.
I installed tomcat and followed this guide but it still doesn't work
https://docs.evolveum.com/connectors/resources/databasetable/:
"JDBC Driver
The connector requires appropriate JDBC driver. The driver needs to be available to the web server. It usually has to be placed on web server classpath. E.g. this means copying the driver to $TOMCAT_HOME/lib directory if tomcat server is used and restarting the server."
Please help me find the cause and how to solve this problem.
Error log as below:
Error
Configuration error: JDBC Driver is not found on classpath.com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation$TestFailedException: Configuration error: JDBC Driver is not found on classpath. at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation$TestConnectorOperation.stopIfResultNotOk(ResourceTestOperation.java:625) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation$TestConnectorOperation.testConnector(ResourceTestOperation.java:587) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation$TestConnectorOperation.execute(ResourceTestOperation.java:432) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation.testConnector(ResourceTestOperation.java:283) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation.testMainConnector(ResourceTestOperation.java:267) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation.executeTest(ResourceTestOperation.java:241) at com.evolveum.midpoint.provisioning.impl.resources.ResourceTestOperation.execute(ResourceTestOperation.java:206) at com.evolveum.midpoint.provisioning.impl.resources.ResourceManager.testResource(ResourceManager.java:241) at com.evolveum.midpoint.provisioning.impl.ProvisioningServiceImpl.testResourceInternal(ProvisioningServiceImpl.java:663) at com.evolveum.midpoint.provisioning.impl.ProvisioningServiceImpl.testResource(ProvisioningServiceImpl.java:650) at com.evolveum.midpoint.provisioning.api.ProvisioningService.testPartialConfiguration(ProvisioningService.java:955) at com.evolveum.midpoint.model.impl.controller.ModelController.testResourcePartialConfiguration(ModelController.java:1394) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:568) at org.apache.wicket.proxy.jdk.JdkProxyFactory$JdkHandler.invoke(JdkProxyFactory.java:172) at jdk.proxy4/jdk.proxy4.$Proxy163.testResourcePartialConfiguration(Unknown Source) at com.evolveum.midpoint.gui.impl.util.ProvisioningObjectsUtil.partialConfigurationTest(ProvisioningObjectsUtil.java:519) at com.evolveum.midpoint.gui.impl.page.admin.resource.component.wizard.basic.PartialConfigurationStepPanel.onNextPerformed(PartialConfigurationStepPanel.java:97) at com.evolveum.midpoint.gui.api.component.wizard.BasicWizardStepPanel$4.onSubmit(BasicWizardStepPanel.java:123) at org.apache.wicket.ajax.markup.html.form.AjaxSubmitLink$1.onSubmit(AjaxSubmitLink.java:112) at org.apache.wicket.ajax.form.AjaxFormSubmitBehavior$AjaxFormSubmitter.onSubmit(AjaxFormSubmitBehavior.java:249) at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1371) at org.apache.wicket.markup.html.form.Form.process(Form.java:1033) at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:857) at org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:202) at org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:147) at org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:630) at org.apache.wicket.core.request.handler.ListenerRequestHandler.internalInvoke(ListenerRequestHandler.java:300) at org.apache.wicket.core.request.handler.ListenerRequestHandler.invoke(ListenerRequestHandler.java:274) at org.apache.wicket.core.request.handler.ListenerRequestHandler.invokeListener(ListenerRequestHandler.java:222) at org.apache.wicket.core.request.handler.ListenerRequestHandler.respond(ListenerRequestHandler.java:202) at org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:910) at org.apache.wicket.request.RequestHandlerExecutor.execute(RequestHandlerExecutor.java:63) at org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:294) at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:255) at org.apache.wicket.protocol.http.WicketFilter.processRequestCycle(WicketFilter.java:277) at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:208) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:307) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at com.evolveum.midpoint.web.util.MidPointProfilingServletFilter.doFilter(MidPointProfilingServletFilter.java:79) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:131) at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:85) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:449) at com.evolveum.midpoint.authentication.impl.filter.RefuseUnauthenticatedRequestFilter.doFilterInternal(RefuseUnauthenticatedRequestFilter.java:37) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:117) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at com.evolveum.midpoint.authentication.impl.filter.FinishAuthenticationFilter.doFilterInternal(FinishAuthenticationFilter.java:89) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at com.evolveum.midpoint.authentication.impl.filter.MidpointAnonymousAuthenticationFilter.doFilter(MidpointAnonymousAuthenticationFilter.java:94) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:227) at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:221) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at com.evolveum.midpoint.authentication.impl.filter.RedirectForLoginPagesWithAuthenticationFilter.doFilterInternal(RedirectForLoginPagesWithAuthenticationFilter.java:38) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.csrf.CsrfFilter.doFilterInternal(CsrfFilter.java:131) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter$VirtualFilterChain.doFilter(MidpointAuthFilter.java:461) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter.processingOfAuthenticatedRequest(MidpointAuthFilter.java:421) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter.doFilterInternal(MidpointAuthFilter.java:127) at com.evolveum.midpoint.authentication.impl.filter.MidpointAuthFilter.doFilter(MidpointAuthFilter.java:95) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at com.evolveum.midpoint.authentication.impl.filter.TransformExceptionFilter.doFilterInternal(TransformExceptionFilter.java:32) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at com.evolveum.midpoint.authentication.impl.filter.SequenceAuditFilter.doFilterInternal(SequenceAuditFilter.java:90) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at org.springframework.security.web.session.ConcurrentSessionFilter.doFilter(ConcurrentSessionFilter.java:151) at org.springframework.security.web.session.ConcurrentSessionFilter.doFilter(ConcurrentSessionFilter.java:129) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:352) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:268) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at com.evolveum.midpoint.web.boot.TrailingSlashRedirectingFilter.doFilterInternal(TrailingSlashRedirectingFilter.java:60) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:174) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:149) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:166) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:90) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:482) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:115) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:93) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) at com.evolveum.midpoint.web.boot.NodeIdHeaderValve.invoke(NodeIdHeaderValve.java:41) at com.evolveum.midpoint.web.boot.TomcatRootValve.invoke(TomcatRootValve.java:61) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:341) at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:391) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:63) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:894) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1740) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.base/java.lang.Thread.run(Thread.java:833)
Thank you,
Huutm
_______________________________________________
midPoint mailing list
midPoint at lists.evolveum.com<mailto:midPoint at lists.evolveum.com>
https://lists.evolveum.com/mailman/listinfo/midpoint
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20231124/cb2e36f7/attachment.htm>
------------------------------
Subject: Digest Footer
_______________________________________________
midPoint mailing list
midPoint at lists.evolveum.com
https://lists.evolveum.com/mailman/listinfo/midpoint
------------------------------
End of midPoint Digest, Vol 139, Issue 28
*****************************************
_______________________________________________
midPoint mailing list
midPoint at lists.evolveum.com
https://lists.evolveum.com/mailman/listinfo/midpoint
-- Drew Roberts | Systems Administrator IIIT Platform Engineering, Azusa Pacific Universityapu.edu
_______________________________________________midPoint mailing listmidPoint at lists.evolveum.comhttps://lists.evolveum.com/mailman/listinfo/midpoint
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20231125/08c0e509/attachment-0001.htm>
More information about the midPoint
mailing list