2020-03-10 12:29:55,740 (conf-file-poller-0) [WARN - org.apache.flume.channel.jdbc.impl.JdbcChannelProviderImpl.initializeDataSource(JdbcChannelProviderImpl.java:428)] Overriding values for - driver: org.apache.derby.jdbc.EmbeddedDriver, user: saconnectUrl: jdbc:derby:/root/.flume/jdbc-channel/db;create=true, jdbc properties file: null, dbtype: DERBY
java.lang.SecurityException: sealing violation: package org.apache.derby.impl.services.timer is sealed
at java.net.URLClassLoader.getAndVerifyPackage(URLClassLoader.java:399)
at java.net.URLClassLoader.definePackageInternal(URLClassLoader.java:419)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:451)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader 1. r u n ( U R L C l a s s L o a d e r . j a v a : 362 ) a t j a v a . s e c u r i t y . A c c e s s C o n t r o l l e r . d o P r i v i l e g e d ( N a t i v e M e t h o d ) a t j a v a . n e t . U R L C l a s s L o a d e r . f i n d C l a s s ( U R L C l a s s L o a d e r . j a v a : 361 ) a t j a v a . l a n g . C l a s s L o a d e r . l o a d C l a s s ( C l a s s L o a d e r . j a v a : 424 ) a t s u n . m i s c . L a u n c h e r 1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher 1.run(URLClassLoader.java:362)atjava.security.AccessController.doPrivileged(NativeMethod)atjava.net.URLClassLoader.findClass(URLClassLoader.java:361)atjava.lang.ClassLoader.loadClass(ClassLoader.java:424)atsun.misc.LauncherAppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader 1. r u n ( U R L C l a s s L o a d e r . j a v a : 362 ) a t j a v a . s e c u r i t y . A c c e s s C o n t r o l l e r . d o P r i v i l e g e d ( N a t i v e M e t h o d ) a t j a v a . n e t . U R L C l a s s L o a d e r . f i n d C l a s s ( U R L C l a s s L o a d e r . j a v a : 361 ) a t j a v a . l a n g . C l a s s L o a d e r . l o a d C l a s s ( C l a s s L o a d e r . j a v a : 424 ) a t s u n . m i s c . L a u n c h e r 1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher 1.run(URLClassLoader.java:362)atjava.security.AccessController.doPrivileged(NativeMethod)atjava.net.URLClassLoader.findClass(URLClassLoader.java:361)atjava.lang.ClassLoader.loadClass(ClassLoader.java:424)atsun.misc.LauncherAppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at org.apache.derby.impl.services.monitor.BaseMonitor.getImplementations(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.getDefaultImplementations(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.runWithState(Unknown Source)
at org.apache.derby.impl.services.monitor.FileMonitor.(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.startMonitor(Unknown Source)
at org.apache.derby.iapi.jdbc.JDBCBoot 1. r u n ( U n k n o w n S o u r c e ) a t j a v a . s e c u r i t y . A c c e s s C o n t r o l l e r . d o P r i v i l e g e d ( N a t i v e M e t h o d ) a t o r g . a p a c h e . d e r b y . i a p i . j d b c . J D B C B o o t . b o o t ( U n k n o w n S o u r c e ) a t o r g . a p a c h e . d e r b y . i a p i . j d b c . J D B C B o o t . b o o t ( U n k n o w n S o u r c e ) a t o r g . a p a c h e . d e r b y . j d b c . E m b e d d e d D r i v e r . b o o t ( U n k n o w n S o u r c e ) a t o r g . a p a c h e . d e r b y . j d b c . E m b e d d e d D r i v e r . < c l i n i t > ( U n k n o w n S o u r c e ) a t j a v a . l a n g . C l a s s . f o r N a m e 0 ( N a t i v e M e t h o d ) a t j a v a . l a n g . C l a s s . f o r N a m e ( C l a s s . j a v a : 264 ) a t o r g . a p a c h e . f l u m e . c h a n n e l . j d b c . i m p l . J d b c C h a n n e l P r o v i d e r I m p l . i n i t i a l i z e D a t a S o u r c e ( J d b c C h a n n e l P r o v i d e r I m p l . j a v a : 452 ) a t o r g . a p a c h e . f l u m e . c h a n n e l . j d b c . i m p l . J d b c C h a n n e l P r o v i d e r I m p l . i n i t i a l i z e ( J d b c C h a n n e l P r o v i d e r I m p l . j a v a : 100 ) a t o r g . a p a c h e . f l u m e . c h a n n e l . j d b c . J d b c C h a n n e l P r o v i d e r F a c t o r y . g e t P r o v i d e r ( J d b c C h a n n e l P r o v i d e r F a c t o r y . j a v a : 35 ) a t o r g . a p a c h e . f l u m e . c h a n n e l . j d b c . J d b c C h a n n e l . c o n f i g u r e ( J d b c C h a n n e l . j a v a : 89 ) a t o r g . a p a c h e . f l u m e . c o n f . C o n f i g u r a b l e s . c o n f i g u r e ( C o n f i g u r a b l e s . j a v a : 41 ) a t o r g . a p a c h e . f l u m e . n o d e . A b s t r a c t C o n f i g u r a t i o n P r o v i d e r . l o a d C h a n n e l s ( A b s t r a c t C o n f i g u r a t i o n P r o v i d e r . j a v a : 203 ) a t o r g . a p a c h e . f l u m e . n o d e . A b s t r a c t C o n f i g u r a t i o n P r o v i d e r . g e t C o n f i g u r a t i o n ( A b s t r a c t C o n f i g u r a t i o n P r o v i d e r . j a v a : 104 ) a t o r g . a p a c h e . f l u m e . n o d e . P o l l i n g P r o p e r t i e s F i l e C o n f i g u r a t i o n P r o v i d e r 1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at org.apache.derby.iapi.jdbc.JDBCBoot.boot(Unknown Source) at org.apache.derby.iapi.jdbc.JDBCBoot.boot(Unknown Source) at org.apache.derby.jdbc.EmbeddedDriver.boot(Unknown Source) at org.apache.derby.jdbc.EmbeddedDriver.
at java.util.concurrent.Executors R u n n a b l e A d a p t e r . c a l l ( E x e c u t o r s . j a v a : 511 ) a t j a v a . u t i l . c o n c u r r e n t . F u t u r e T a s k . r u n A n d R e s e t ( F u t u r e T a s k . j a v a : 308 ) a t j a v a . u t i l . c o n c u r r e n t . S c h e d u l e d T h r e a d P o o l E x e c u t o r RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) at java.util.concurrent.ScheduledThreadPoolExecutor RunnableAdapter.call(Executors.java:511)atjava.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)atjava.util.concurrent.ScheduledThreadPoolExecutorScheduledFutureTask.access 301 ( S c h e d u l e d T h r e a d P o o l E x e c u t o r . j a v a : 180 ) a t j a v a . u t i l . c o n c u r r e n t . S c h e d u l e d T h r e a d P o o l E x e c u t o r 301(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor 301(ScheduledThreadPoolExecutor.java:180)atjava.util.concurrent.ScheduledThreadPoolExecutorScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
因为hive下lib中已有derby的jar包。是jar包的引用问题。
解决方法:可以将hive的环境变量注释掉。或者将hive中derby的jar包删除(但是要记住曾经删除过)