Flink unable to generate a JAAS configuration file

报错


2021-03-26 12:18:04,517 INFO  org.apache.flink.runtime.entrypoint.ClusterEntrypoint        [] - Shutting YarnSessionClusterEntrypoint down with application status FAILED. Diagnostics java.lang.RuntimeException: unable to generate a JAAS configuration file
        at org.apache.flink.runtime.security.modules.JaasModule.generateDefaultConfigFile(JaasModule.java:183)
        at org.apache.flink.runtime.security.modules.JaasModule.install(JaasModule.java:92)
        at org.apache.flink.runtime.security.SecurityUtils.installModules(SecurityUtils.java:76)
        at org.apache.flink.runtime.security.SecurityUtils.install(SecurityUtils.java:57)
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.installSecurityContext(ClusterEntrypoint.java:215)
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:173)
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.runClusterEntrypoint(ClusterEntrypoint.java:569)
        at org.apache.flink.yarn.entrypoint.YarnSessionClusterEntrypoint.main(YarnSessionClusterEntrypoint.java:90)
Caused by: java.nio.file.AccessDeniedException: /data/flink/tmp/jaas-3783078189264913575.conf
        at sun.nio.fs.UnixException.translateToIOException(UnixException.java:84)
        at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
        at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
        at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214)
        at java.nio.file.Files.newByteChannel(Files.java:361)
        at java.nio.file.Files.createFile(Files.java:632)
        at java.nio.file.TempFileHelper.create(TempFileHelper.java:138)
        at java.nio.file.TempFileHelper.createTempFile(TempFileHelper.java:161)
        at java.nio.file.Files.createTempFile(Files.java:852)
        at org.apache.flink.runtime.security.modules.JaasModule.generateDefaultConfigFile(JaasModule.java:173)
        ... 7 more
.
2021-03-26 12:18:04,530 ERROR org.apache.flink.runtime.entrypoint.ClusterEntrypoint        [] - Could not start cluster entrypoint YarnSessionClusterEntrypoint.
org.apache.flink.runtime.entrypoint.ClusterEntrypointException: Failed to initialize the cluster entrypoint YarnSessionClusterEntrypoint.
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:200) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.runClusterEntrypoint(ClusterEntrypoint.java:569) [flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.yarn.entrypoint.YarnSessionClusterEntrypoint.main(YarnSessionClusterEntrypoint.java:90) [flink-dist_2.11-1.12.2.jar:1.12.2]
Caused by: java.lang.RuntimeException: unable to generate a JAAS configuration file
        at org.apache.flink.runtime.security.modules.JaasModule.generateDefaultConfigFile(JaasModule.java:183) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.modules.JaasModule.install(JaasModule.java:92) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.SecurityUtils.installModules(SecurityUtils.java:76) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.SecurityUtils.install(SecurityUtils.java:57) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.installSecurityContext(ClusterEntrypoint.java:215) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:173) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        ... 2 more
Caused by: java.nio.file.AccessDeniedException: /data/flink/tmp/jaas-3783078189264913575.conf
        at sun.nio.fs.UnixException.translateToIOException(UnixException.java:84) ~[?:1.8.0_271]
        at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) ~[?:1.8.0_271]
        at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) ~[?:1.8.0_271]
        at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214) ~[?:1.8.0_271]
        at java.nio.file.Files.newByteChannel(Files.java:361) ~[?:1.8.0_271]
        at java.nio.file.Files.createFile(Files.java:632) ~[?:1.8.0_271]
        at java.nio.file.TempFileHelper.create(TempFileHelper.java:138) ~[?:1.8.0_271]
        at java.nio.file.TempFileHelper.createTempFile(TempFileHelper.java:161) ~[?:1.8.0_271]
        at java.nio.file.Files.createTempFile(Files.java:852) ~[?:1.8.0_271]
        at org.apache.flink.runtime.security.modules.JaasModule.generateDefaultConfigFile(JaasModule.java:173) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.modules.JaasModule.install(JaasModule.java:92) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.SecurityUtils.installModules(SecurityUtils.java:76) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.security.SecurityUtils.install(SecurityUtils.java:57) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.installSecurityContext(ClusterEntrypoint.java:215) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        at org.apache.flink.runtime.entrypoint.ClusterEntrypoint.startCluster(ClusterEntrypoint.java:173) ~[flink-dist_2.11-1.12.2.jar:1.12.2]
        ... 2 more

原因:
/data/flink/tmp 权限不足 , 改为 777 , chmod 777 /data/flink/tmp

posted @ 2021-03-26 13:15  宁君  阅读(1384)  评论(0编辑  收藏  举报