Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
  1. Manual mount volume
    Persistence: manually add the volume part in deployment, NFS mode
    Code Block
    titleManual mount volume
  2. spec:
  3.  containers:
  4.  
  5. - image: hub.baidubce.com/duanshuaixing/tools:v3
  6.  
  7. imagePullPolicy: IfNotPresent
  8.  
  9. name: test-volume 
  10. resources: {}
  11.  
  12. terminationMessagePath: /dev/termination-log
  13.  terminationMessagePolicy: File
  14.  volumeMounts: 
  15. - mountPath: /root/ 
  16. name: nfs-test
  17.  
  18. dnsPolicy: ClusterFirst
  19.  restartPolicy: Always
  20.  
  21. schedulerName: default-scheduler 
  22. securityContext: {}
  23.  
  24. terminationGracePeriodSeconds: 30
  25.  
  26. volumes: 
  27. - name: nfs-test 
  28. nfs: 
  29. path: /dockerdata-nfs/test-volume/
  30.  
  31. server: 10.0.0.7


  32. Restart the node to check the nfs automount

    Restart node and see whether nfs client auto-mounts nfs or not, if not, you should munually mount it.

    df -Th |grep nfs

    sudo mount $MASTER_IP:/dockerdata-nfs /dockerdata-nfs/

  33. Reinstall One ProjectÂ