CrashLoopBackOff(在Docker/Kubernetes中为Mongo)-无法在任何兼容版本下启动WiredTiger [英] CrashLoopBackOff (Mongo in Docker/Kubernetes) - Failed to start up WiredTiger under any compatibility version

查看:486
本文介绍了CrashLoopBackOff(在Docker/Kubernetes中为Mongo)-无法在任何兼容版本下启动WiredTiger的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的Kubernetes应用程序突然遇到一些问题(没有任何事件可以解释).该应用程序在一年内一直可以正常运行,但是现在我的状态为CrashLoopBackOff.

I'm suddenly facing some issues in my Kubernetes application (with no event to explain it). The application has been working properly during one year but now I'm getting a CrashLoopBackOff status.

重要更新:

我无法在GKE中更新Mongo复制控制器,因为当我(从GIT)提交mongo.yml中的更改时,除mongo-controller(已关闭)之外的所有工作负载都将更新.

I cannot update the Mongo replication controller in GKE, because when I commit the changes in mongo.yml (from GIT) all workloads update except mongo-controller (which is down).

在工作负载/Mongo-controller/托管窗格中的GKE中,我可以看到创建于"日期是几天前应用启动的时间.其余的Pod正在使用我的提交进行更新.我不想删除Mongo pod,因为我想我们已经丢失了数据库的信息/内容. (创建集群管道的开发人员未安排备份.)

In GKE in Workloads/Mongo-controller/Managed pods I can see that the "Created on" date is some days ago when the app was up. The rest of pods are updating with my commits. I don't want to delete the Mongo pod, because I suppose that we'd lost the database info/content. (The developer who created the cluster pipeline didn't schedule a backup).

数据库:MongoDB(最新,不确定那是什么在正常运行) 操作系统:在Ubuntu 18.04上运行的Pod 集群:Google Cloud Kubernetes引擎(又称GKE)

Database: MongoDB (latest, not sure what was the one running properly) OS: Pod running on Ubuntu 18.04 CLuster: Google Cloud Kubernetes Engines (a.k.a GKE)

Kubectl获取广告连播

mongo-controller-dgkkg 0/1 CrashLoopBackOff 1199 4d6h

Mongo POD日志

自动禁用TLS 1.0,以强制启用TLS 1.0,指定--sslDisabledProtocols'none'

Automatically disabling TLS 1.0, to force-enable TLS 1.0 specify --sslDisabledProtocols 'none'

在NetworkInterface启​​动期间未配置TransportLayer"}

No TransportLayer configured during NetworkInterface startup"}

隐式TCP FastOpen不可用.如果需要TCP FastOpen,请设置tcpFastOpenServer,tcpFastOpenClient和tcpFastOpenQueueSize.

Implicit TCP FastOpen unavailable. If TCP FastOpen is required, set tcpFastOpenServer, tcpFastOpenClient, and tcpFastOpenQueueSize.

MongoDB开始","attr":{"pid":1,"port":27017,"dbPath":"/data/db",体系结构":"64位" ;,主机":"mongo-controller-dgkkg"}

MongoDB starting","attr":{"pid":1,"port":27017,"dbPath":"/data/db","architecture":"64-bit","host":"mongo-controller-dgkkg"}

Build Info","attr":{"buildInfo":{"version":"4.4.1","gitVersion":"ad91a93a5a31e175f5cbf8c69561e788bbc55ce1"和"openSSLVersion": .1 11 Sep 2018 ,"target_arch":"x86_64"}}}

Build Info","attr":{"buildInfo":{"version":"4.4.1","gitVersion":"ad91a93a5a31e175f5cbf8c69561e788bbc55ce1","openSSLVersion":"OpenSSL 1.1.1 11 Sep 2018","modules":[],"allocator":"tcmalloc","environment":{"distmod":"ubuntu1804","distarch":"x86_64","target_arch":"x86_64"}}}

操作系统","attr":{"os":{名称":"Ubuntu",版本":"18.04"}}

Operating System","attr":{"os":{"name":"Ubuntu","version":"18.04"}}

通过命令行设置的选项","attr":{"options":{"net":{"bindIp":"*"}}}

Options set by command line","attr":{"options":{"net":{"bindIp":"*"}}}

要使用的存储引擎由数据文件," attr":{"dbpath":"/data/db","storageEngine":"wiredTiger"}检测到

Storage engine to use detected by data files","attr":{"dbpath":"/data/db","storageEngine":"wiredTiger"}

强烈建议通过WiredTiger存储引擎使用XFS文件系统.参见 http://dochub .mongodb.org/core/prodnotes-filesystem," tags":: [" startupWarnings]

Using the XFS filesystem is strongly recommended with the WiredTiger storage engine. See http://dochub.mongodb.org/core/prodnotes-filesystem","tags":["startupWarnings"]

打开WiredTiger","attr":{"config":"create,cache_size = 1336M,session_max = 33000,eviction =(threads_min = 4,threads_max = 4),config_base = false,statistics =(fast) ),log =(启用= true,存档= true,path = journal,compressor = snappy),file_manager =(close_idle_time = 100000,close_scan_interval = 10,close_handle_minimum = 250),statistics_log =(wait = 0),verbose = [recovery_progress ,checkpoint_progress,compact_progress]

Opening WiredTiger","attr":{"config":"create,cache_size=1336M,session_max=33000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000,close_scan_interval=10,close_handle_minimum=250),statistics_log=(wait=0),verbose=[recovery_progress,checkpoint_progress,compact_progress]

无法在任何兼容版本下启动WiredTiger.这可能是由于不支持的升级或降级.

终止.","attr":{原因":"95:不支持操作"}}

Terminating.","attr":{"reason":"95: Operation not supported"}}

致命断言","attr":{"msgid":28595,"file":"src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp",行":1101}}

Fatal assertion","attr":{"msgid":28595,"file":"src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp","line":1101}}

\ n \ n *** fassert()失败后中止\ n \ n

\n\n***aborting after fassert() failure\n\n

我的Mongo.yml:

apiVersion: v1
kind: Service
metadata:
  name: mongo
  namespace: $KUBE_NAMESPACE-$CI_ENVIRONMENT_SLUG
  labels:
    name: mongo
spec:
  ports:
    - port: 27017
      targetPort: 27017
  selector:
    name: mongo
---
apiVersion: v1
kind: ReplicationController
metadata:
  name: mongo-controller
  namespace: $KUBE_NAMESPACE-$CI_ENVIRONMENT_SLUG
  labels:
    name: mongo
spec:
  replicas: 1
  template:
    metadata:
      labels:
        name: mongo
    spec:
      containers:
      - image: mongo
        name: mongo
        ports:
        - name: mongo
          containerPort: 27017
          hostPort: 27017
        volumeMounts:
            - name: mongo-persistent-storage
              mountPath: /data/db
      volumes:
        - name: mongo-persistent-storage
          gcePersistentDisk:
            pdName: mongo-disk-$CI_ENVIRONMENT_SLUG
            fsType: ext4

PD:也许我应该将ReplicationController更新为Deployment(推荐),但是作为数据库容器,我们总是以这种方式对其进行配置.但是我尝试了一下,没有任何改变.

PD: Maybe I should update my ReplicationController to Deployment (recommended), but being a database container we always configure it in that way. However I tried that, and nothing changed.

推荐答案

我解决了这个问题,可以从Google Cloud Console在线编辑Replication Controller.

I solved this issue editing the Replication Controller online from the Google Cloud Console.

访问:"Kubernetes引擎"; > 工作量" > "mongo-controller" > 受管理的广告连播" > "mongo-controller-XXXXX"

Access to: "Kubernetes Engine" > "Workload" > "mongo-controller" > "Managed pods" > "mongo-controller-XXXXX"

...,然后按EDIT按钮(在顶部导航栏中).您可以实时在线编辑配置.我只是在图像中指定了Mongo版本(4.2.10),一切都按预期运行了.

...and press EDIT button (in the top navbar). You can edit the configuration online in real time. I simply specified the Mongo version (4.2.10) in the image, and everything woked as expected.

    spec:
      replicas: 1
      selector:
        name: mongo
      template:
        metadata:
          creationTimestamp: null
          labels:
            name: mongo
        spec:
          containers:
          - image: mongo: 4.2.10

          (...)

这篇关于CrashLoopBackOff(在Docker/Kubernetes中为Mongo)-无法在任何兼容版本下启动WiredTiger的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆