在iframe中显示hadoop hdfs(filebrowser)

h79rfbju  于 2021-05-31  发布在  Hadoop
关注(0)|答案(0)|浏览(515)

我正试图通过在iframe中嵌入页面来将hadoop hdfs浏览器显示到我的网站上。
我在core-site.xml中添加了一些参数,如下所示。

<configuration>
  <property>
    <name>fs.defaultFS</name>
    <value>hdfs://hadoop0:portnum</value>
  </property>

  <property>
    <name>hadoop.http.filter.initializers</name>
  <value>org.apache.hadoop.http.lib.StaticUserWebFilter,org.apache.hadoop.security.HttpCrossOriginFilterInitializer,org.apache.hadoop.security.AuthenticationFilterInitializer</value>

  </property>

  <property>
    <name>hadoop.http.cross-origin.enabled</name>
    <value>true</value>
  </property>

  <property>
    <name>hadoop.http.cross-origin.allowed-origins</name>
    <value>*</value>
  </property>

  <property>
    <name>hadoop.http.cross-origin.allowed-methods</name>
    <value>GET,POST,HEAD,DELETE,OPTIONS</value>
  </property>

  <property>
    <name>hadoop.http.cross-origin.allowed-headers</name>
    <value>X-Requested-With,Content-Type,Accept,Origin</value>
  </property>

  <property>
    <name>hadoop.http.cross-origin.max-age</name>
    <value>1800</value>
  </property>

 <property>
    <name>hadoop.http.authentication.type</name>
    <value>simple</value>
  </property>

  <property>
    <name>hadoop.http.authentication.token.validity</name>
    <value>36000</value>
  </property>

  <property>
    <name>hadoop.http.authentication.token.max-inactive-interval</name>
    <value>-1</value>
  </property>

  <property>
    <name>hadoop.http.authentication.signature.secret.file</name>
    <value>$user.home/hadoop-http-auth-signature-secret</value>
  </property>

  <property>
    <name>hadoop.http.authentication.cookie.persistent</name>
    <value>false</value>
  </property>

  <property>
    <name>hadoop.http.authentication.simple.anonymous.allowed</name>
    <value>true</value>
  </property>
</configuration>

我还在hdfs-site.xml中添加了一些参数

<property>
    <name>dfs.permissions</name>
    <value>false</value>
  </property>

但不知什么原因,我得到了这样的错误信息。”拒绝显示'http://myhdfs url'因为它将'x-frame-options'设置为'sameorigin'
有人能帮我吗?

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题