Got it

Error Message "IllegalConfigurationException: Error while parsing YAML configuration file: security.cookie" Is Displayed When a Command Is Executed on

656 0 0 0 0

Versions

V100R002C70SPC20*

V100R002C80SPC20*

Symptom

After a client is successfully installed, an error message "IllegalConfigurationException: Error while parsing YAML configuration file:"security.cookie" is displayed when you run a command (for example, yarn-session.sh) on the client.

[root@xxx-xxx-xxx-10 bin]# yarn-session.sh
2018-10-24 15:34,788 | ERROR | [main] | Error while trying to split key and value in configuration file /opt/flinkclient/Flink/flink/conf/flink-conf.yaml:77: "security.cookie: " | org.apache.flink.configuration.GlobalConfiguration (GlobalConfiguration.java:160)
Exception in thread "main" org.apache.flink.configuration.IllegalConfigurationException: Error while parsing YAML configuration file :77: "security.cookie: "
        at org.apache.flink.configuration.GlobalConfiguration.loadYAMLResource(GlobalConfiguration.java:161)
        at org.apache.flink.configuration.GlobalConfiguration.loadConfiguration(GlobalConfiguration.java:112)
        at org.apache.flink.configuration.GlobalConfiguration.loadConfiguration(GlobalConfiguration.java:79)
        at org.apache.flink.yarn.cli.FlinkYarnSessionCli.main(FlinkYarnSessionCli.java:482)
[root@xxx-xxx-xxx-10 bin]#

Possible Causes

In a secure cluster environment, Flink requires security authentication. The security authentication is not configured on the current client.

Fault Locating

  1. Flink uses following authentication modes:
    • Kerberos authentication: Is used between Flink YARN client and YARN ResourceManager, JobManager and ZooKeeper, JobManager and HDFS, TaskManager and HDFS, Kafka and TaskManager, as well as TaskManager and ZooKeeper.
    • Security cookie authentication: Is used between Flink YARN client and JobManager, JobManager and TaskManager, as well as TaskManager and TaskManager.
    • Internal authentication mechanism of YARN: Is used between YARN Resource Manager and Application Master (AM).
  2. If a secure mode is used, you must configure the Kerberos authentication and security cookie authentication. As shown in the logs, it is found that the security.cookie configuration in the configuration file is incorrect andthe security configuration is not performed.

Solution

  1. Invoke the generate_keystore.sh script provided by FusionInsight to generate Security Cookieflink.keystore, and flink.truststore.

2. Enable Security Cookie, and set security.enable to true. Then, check whether security cookie is successfully configured, as shown in the following figure

Comment

You need to log in to comment to the post Login | Register
Comment

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.