yarn.nodemanager.local-dirs文件夹的文件许可权应该是什么?我弄乱了这些文件的权限,但无法解决。目前,我已将文件夹权限设置为755 yarn:hadoop。每当我尝试运行nodemanager时,我都会遇到EPERM:不允许操作错误。细节 -

2014-06-19 22:15:17,954 INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService: usercache path : file://opt1/yarn/nm2/usercache_DEL_1403241103430
2014-06-19 22:15:17,954 INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService: usercache path : file://opt1/yarn/nm2/usercache_DEL_1403241317919
2014-06-19 22:15:17,954 INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService: usercache path : file://opt1/yarn/nm2/usercache_DEL_1403241109852
2014-06-19 22:15:17,954 INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService: usercache path : file://opt1/yarn/nm2/usercache_DEL_1403241098628
2014-06-19 22:15:17,992 INFO org.apache.hadoop.service.AbstractService: Service org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService failed in state INITED; cause: org.apache.hadoop.yarn.exceptions.YarnRuntimeException: Failed to initialize LocalizationService
org.apache.hadoop.yarn.exceptions.YarnRuntimeException: Failed to initialize LocalizationService
        at org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService.serviceInit(ResourceLocalizationService.java:233)
        at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
        at org.apache.hadoop.service.CompositeService.serviceInit(CompositeService.java:108)
        at org.apache.hadoop.yarn.server.nodemanager.containermanager.ContainerManagerImpl.serviceInit(ContainerManagerImpl.java:220)
        at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
        at org.apache.hadoop.service.CompositeService.serviceInit(CompositeService.java:108)
        at org.apache.hadoop.yarn.server.nodemanager.NodeManager.serviceInit(NodeManager.java:188)
        at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
        at org.apache.hadoop.yarn.server.nodemanager.NodeManager.initAndStartNodeManager(NodeManager.java:353)
        at org.apache.hadoop.yarn.server.nodemanager.NodeManager.main(NodeManager.java:401)
Caused by: EPERM: Operation not permitted
        at org.apache.hadoop.io.nativeio.NativeIO$POSIX.chmodImpl(Native Method)
        at org.apache.hadoop.io.nativeio.NativeIO$POSIX.chmod(NativeIO.java:226)
        at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(RawLocalFileSystem.java:629)
        at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem.java:421)
        at org.apache.hadoop.fs.FileSystem.primitiveMkdir(FileSystem.java:1061)
        at org.apache.hadoop.fs.DelegateToFileSystem.mkdir(DelegateToFileSystem.java:157)
        at org.apache.hadoop.fs.FilterFs.mkdir(FilterFs.java:187)
        at org.apache.hadoop.fs.FileContext$4.next(FileContext.java:720)
        at org.apache.hadoop.fs.FileContext$4.next(FileContext.java:716)
        at org.apache.hadoop.fs.FSLinkResolver.resolve(FSLinkResolver.java:90)
        at org.apache.hadoop.fs.FileContext.mkdir(FileContext.java:716)
        at org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ResourceLocalizationService.serviceInit(ResourceLocalizationService.java:230)
        ... 9 more

尝试启动失败后,local-dirs文件夹具有以下文件夹-filecache,nmPrivate,3 usercache_DEL_timestamp。根据错误的位置(ResourceLocalizationService.java,第233行),三个可能的操作可能会引发此错误-
a)清理旧文件-如此工作,如日志输出所示
b)创建新文件-尝试启动失败后,我在本地目录中看到三种文件-三个usercache_DEL _ *,filecache和nmPrivate文件。
c)制作日志路径-我检查了日志文件夹,以获取对yarn:hadoop的权限775。

可能出什么问题了?我正在使用Cloudera来管理我的集群。

最佳答案

您应该让您的nodemanager目录具有执行权,
chmod 700 ..(nodemanager目录)

关于java - Namenode抛出EPERM:启动时不允许进行操作,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/24329735/

10-12 14:11