【原创】大叔经验分享(57)hue启动coordinator时报错

hue启动coordinator时报错,页面返回undefinied错误框:

后台日志报错:

runcpserver.log

[13/May/2019 04:34:55 -0700] middleware   INFO     Processing exception: ‘NoneType‘ object has no attribute ‘is_superuser‘: Traceback (most recent call last):
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Django-1.6.10-py2.7.egg/django/core/handlers/base.py", line 112, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Django-1.6.10-py2.7.egg/django/db/transaction.py", line 371, in inner
    return func(*args, **kwargs)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/decorators.py", line 113, in decorate
    return view_func(request, *args, **kwargs)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/decorators.py", line 75, in decorate
    return view_func(request, *args, **kwargs)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/views/editor2.py", line 683, in submit_coordinator
    job_id = _submit_coordinator(request, coordinator, mapping)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/views/editor2.py", line 709, in _submit_coordinator
    wf_dir = Submission(request.user, wf, request.fs, request.jt, mapping, local_tz=coordinator.data[‘properties‘][‘timezone‘]).deploy()
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/desktop/libs/liboozie/src/liboozie/submission2.py", line 298, in deploy
    oozie_xml = self.job.to_xml(self.properties)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/models2.py", line 468, in to_xml
    ‘workflow_mapping‘: workflow_mapping
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/desktop/core/src/desktop/lib/django_mako.py", line 114, in render_to_string_normal
    result = template.render(**data_dict)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Mako-0.8.1-py2.7.egg/mako/template.py", line 443, in render
    return runtime._render(self, self.callable_, args, data)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Mako-0.8.1-py2.7.egg/mako/runtime.py", line 786, in _render
    **_kwargs_for_callable(callable_, data))
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Mako-0.8.1-py2.7.egg/mako/runtime.py", line 818, in _render_context
    _exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/build/env/lib/python2.7/site-packages/Mako-0.8.1-py2.7.egg/mako/runtime.py", line 844, in _exec_template
    callable_(context, *args, **kwargs)
  File "/tmp/tmpurIkf9/oozie/editor2/gen/workflow.xml.mako.py", line 110, in render_body
    __M_writer( node.to_xml(mapping, node_mapping, workflow_mapping) )
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/models2.py", line 860, in to_xml
    notebook = Notebook(document=Document2.objects.get_by_uuid(user=self.user, uuid=self.data[‘properties‘][‘uuid‘]))
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/desktop/core/src/desktop/models.py", line 975, in get_by_uuid
    latest_doc.can_read_or_exception(user)
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/desktop/core/src/desktop/models.py", line 1305, in can_read_or_exception
    if self.can_read(user):
  File "/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/desktop/core/src/desktop/models.py", line 1302, in can_read
    return user.is_superuser or self.owner == user or self.can_write(user) or has_read_permissions
AttributeError: ‘NoneType‘ object has no attribute ‘is_superuser‘

解决方法:

/opt/cloudera/parcels/CDH-5.16.1-1.cdh5.16.1.p0.3/lib/hue/apps/oozie/src/oozie/models2.py

   3395   @property
   3396   def workflow(self):
   3397     if self.document is None:
   3398       raise PopupException(_(‘Cannot return workflow since document attribute is None.‘))
   3399
   3400     # Integrated scheduler
   3401     if self.data[‘properties‘][‘document‘]:
   3402       document = Document2.objects.get_by_uuid(user=self.document.owner, uuid=self.data[‘properties‘][‘document‘])
   3403       wf_doc = WorkflowBuilder().create_workflow(document=document, user=self.document.owner, managed=True)
   3404       wf = Workflow(data=wf_doc.data)
   3405       wf_doc.delete()
   3406       return wf
   3407     else:
   3408       wf_doc = Document2.objects.get_by_uuid(user=self.document.owner, uuid=self.data[‘properties‘][‘workflow‘])
   3409       return Workflow(document=wf_doc)

修改为

   3395   @property
   3396   def workflow(self):
   3397     if self.document is None:
   3398       raise PopupException(_(‘Cannot return workflow since document attribute is None.‘))
   3399
   3400     # Integrated scheduler
   3401     if self.data[‘properties‘][‘document‘]:
   3402       document = Document2.objects.get_by_uuid(user=self.document.owner, uuid=self.data[‘properties‘][‘document‘])
   3403       wf_doc = WorkflowBuilder().create_workflow(document=document, user=self.document.owner, managed=True)
   3404       wf = Workflow(data=wf_doc.data,user=self.document.owner)
   3405       wf_doc.delete()
   3406       return wf
   3407     else:
   3408       wf_doc = Document2.objects.get_by_uuid(user=self.document.owner, uuid=self.data[‘properties‘][‘workflow‘])
   3409       return Workflow(document=wf_doc,user=self.document.owner)

参考:
https://issues.cloudera.org/browse/HUE-7919
https://github.com/cloudera/hue/commit/4db8f45862302436e3a1f61be509a016f9cd1576

原文地址:https://www.cnblogs.com/barneywill/p/10858666.html

时间: 2024-10-27 01:57:33

【原创】大叔经验分享(57)hue启动coordinator时报错的相关文章

【原创】大叔经验分享(53)kudu报错unable to find SASL plugin: PLAIN

kudu安装后运行不正常,master中找不到任何tserver,查看tserver日志发现有很多报错: Failed to heartbeat to master:7051: Invalid argument: Failed to ping master at master:7051: Client connection negotiation failed: client connection to master:7051: unable to find SASL plugin: PLAIN

Linux 启动 Apache 时报错:(98)Address already in use: make_sock: could not bind to address [::]:80

1. 启动 Apache 时报错: [[email protected] sh]# service httpd start Starting httpd: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName (98)Address already in use: make_sock: could not bi

MyEclipse 启动tomcat时报错:Cannot change deployment state from ERROR to REDEPLOYING.ds

myeclipse 启动tomcat时报错:Cannot change deployment state from ERROR to REDEPLOYING.ds - 刘琦的专栏 - 博客频道 - CSDN.NET http://blog.csdn.net/u012922219/article/details/42869361   错误 : 无改将部署状态从"错误"变成"重新部署"状态. 解决办法: 右击"项目名" –> MyEclipse

django启动服务时报错:RuntimeError: Model class index.models.User doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.

在django框架中用命令启动服务时报如下错误: RuntimeError: Model class index.models.User doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS. 解决方法: 我是这样解决的: 检查setting.py里面的INSTALLED_APPS,发现应用没有注册.把应用注册之后,重启服务就好了 其它解决方法,以后遇到了再补充. django启动服

启动elasticsearch时报错:./elasticsearch-env: 第 81 行: cd: /etc/elasticsearch: 权限不够或其他权限问题

启动elasticsearch时报错:./elasticsearch-env: 第 81 行: cd: /etc/elasticsearch: 权限不够 切换到root下启动也不行 把这个文件夹添加到普通用户组 cd /etc sudo chown -R xuelianchen elasticsearch/ 再启动,又报另一个权限问题的错 再重复一遍添加用户组 cd /var/log sudo chown -R xuelianchen elasticsearch/ 再启动,这就成功了 PS:大概

启动amoeba时报错解决方法

在启动amoeba时报下列错误 [[email protected] ~]# /usr/local/amoeba-mysql-3.0.5-RC/bin/launcherJava HotSpot(TM) 64-Bit Server VM warning: ignoring option PermSize=16m; support was removed in 8.0Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermS

【报错】项目启动部署时报错:java.lang.NoSuchMethodError

报错: ===================================================================================================== 项目启动部署报错: java.lang.NoSuchMethodError: org.springframework.util.ReflectionUtils.doWithLocalFields(Ljava/lang/Class;Lorg/springframework/util/Ref

ifup em2启动网卡时报错:connection activation failed

环境:centos7,重启网络,报以下错误: ifup em2     ##启动em2网卡时报错 Error: Connection activation failed: The connection is not for this device. 解决方法: systemctl stop NetworkManager.service systemctl disable NetworkManager 再启动过em2网卡,就可以了 ifup em2 原文地址:http://blog.51cto.c

项目启动部署时报错:java.lang.NoSuchMethodError

报错: ===================================================================================================== 项目启动部署报错: java.lang.NoSuchMethodError: org.springframework.util.ReflectionUtils.doWithLocalFields(Ljava/lang/Class;Lorg/springframework/util/Ref