docker elasticsearch 이상 Failed to create node environment 시작(해결)

elasticsearch를 시작하기 위해 docker-compose 파일을 직접 작성했습니다. docker-compose 파일은 다음과 같습니다.
version: '2'
services:
    hdback-elasticsearch:
        #     elasticsearch  ik     
        image: ***/elasticsearch-with-ik:6.4.3
        environment:
            - bootstrap.memory_lock=true
            - "ES_JAVA_OPTS=-Xms1024m -Xmx1024m"
        ulimits:
           memlock:
              soft: -1
              hard: -1
           nofile:
              soft: 65536
              hard: 65536
        volumes:
            - ./es/es-with-ik-data/:/usr/share/elasticsearch/data/
        ports:
            - 9200:9200
            - 9300:9300

elasticsearch 통합 IK 분사기 상세 설명:https://blog.csdn.net/s1078229131/article/details/90036289
시작할 때 elasticsearch는 다음과 같은 이상을 던집니다.
hdback-elasticsearch_1  | 	org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: Failed to create node environment
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:140) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:127) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:124) ~[elasticsearch-cli-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.cli.Command.main(Command.java:90) ~[elasticsearch-cli-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:93) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:86) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | Caused by: java.lang.IllegalStateException: Failed to create node environment
hdback-elasticsearch_1  | 	at org.elasticsearch.node.Node.(Node.java:277) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.node.Node.(Node.java:256) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap$5.(Bootstrap.java:213) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:213) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:326) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:136) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	... 6 more
hdback-elasticsearch_1  | Caused by: java.nio.file.AccessDeniedException: /usr/share/elasticsearch/data/nodes
hdback-elasticsearch_1  | 	at sun.nio.fs.UnixException.translateToIOException(UnixException.java:90) ~[?:?]
hdback-elasticsearch_1  | 	at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111) ~[?:?]
hdback-elasticsearch_1  | 	at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116) ~[?:?]
hdback-elasticsearch_1  | 	at sun.nio.fs.UnixFileSystemProvider.createDirectory(UnixFileSystemProvider.java:385) ~[?:?]
hdback-elasticsearch_1  | 	at java.nio.file.Files.createDirectory(Files.java:682) ~[?:?]
hdback-elasticsearch_1  | 	at java.nio.file.Files.createAndCheckIsDirectory(Files.java:789) ~[?:?]
hdback-elasticsearch_1  | 	at java.nio.file.Files.createDirectories(Files.java:775) ~[?:?]
hdback-elasticsearch_1  | 	at org.elasticsearch.env.NodeEnvironment.(NodeEnvironment.java:207) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.node.Node.(Node.java:274) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.node.Node.(Node.java:256) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap$5.(Bootstrap.java:213) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:213) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:326) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:136) ~[elasticsearch-6.4.3.jar:6.4.3]
hdback-elasticsearch_1  | 	... 6 more

이상은 노드 환경을 만드는 데 실패했습니다./usr/share/elasticsearch/data/nodes의 IO 오류입니다. 이 디렉터리에 읽기와 쓰기 권한을 추가하려고 시도한 후에도 ** 쓸모가 없습니다. 디렉터리를 마운트할 수 있는 권한이 없어서 그런 것입니까?
chmod 777 마운트 디렉토리 경로
예: chmod 777 es/es-with-ik-data
다시 docker-compose 시작, OK!!!!문제 해결☺
 
마지막으로 관래파 혜택!
아리운 서버 대금권과 할인 무료 수령:https://promotion.aliyun.com/ntms/yunparter/invite.html?userCode=ypbt9nme
성능 수준 호스트 20% 할인:https://promotion.aliyun.com/ntms/act/enterprise-discount.html?userCode=ypbt9nme
신규 사용자 클라우드 커뮤니케이션은 20% 할인:https://www.aliyun.com/acts/alicomcloud/new-discount?userCode=ypbt9nme
신구 사용자 클라우드 호스트 40% 할인 전문 주소:https://promotion.aliyun.com/ntms/act/qwbk.html?userCode=ypbt9nme
680위안이면 상표 전문 주소를 등록할 수 있다.https://tm.aliyun.com/?userCode=ypbt9nme
17위안/월 클라우드 호스트:https://promotion.aliyun.com/ntms/act/qwbk.html?spm=5176.11533447.1097531.13.22805cfaiTv7SN&userCode=ypbt9nme

좋은 웹페이지 즐겨찾기