Giter Site home page Giter Site logo

azure-kubernetes-demo's People

Contributors

colemickens avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

azure-kubernetes-demo's Issues

Issue with mounting vhd

Hi,

I tried having a look at the multiple tickets regardind using mounting vhd volumes, but was unable to understand if the issue is fixed.

I can't see to replicate this demo:

I'm using the following yml replication controller:

apiVersion: v1
kind: Service
metadata:
  name: sayt
  labels:
    run: sayt
spec:
  type: NodePort
  ports:
  - port: 8081
    targetPort: 8081
    protocol: TCP
    name: http
  selector:
    run: sayt

---
apiVersion: v1
kind: ReplicationController
metadata:
  name: sayt
spec:
  replicas: 3
  template:
    metadata:
      labels:
        run: sayt
        uses: elas
    spec:
      containers:
      - name: sayt
        imagePullPolicy: Always
        image: essearch/sayt:dev1
        env:
        - name: SPIFFY_ENV
          value: "azuredev1"
        - name: ES_CLIENT
          value: "10.0.57.114:9200"
        ports:
        - containerPort: 8081
        volumeMounts:
          - name: disk0
            mountPath: "/mnt/disk0"
          - name: disk1
            mountPath: "/mnt/disk1"
          - name: disk2
            mountPath: "/mnt/disk2"
      volumes:
        - name: disk0
          azureDisk:
            diskName: sayt-dev1-node0-osdisk.vhd
            diskURI: https://saytdev1.blob.core.windows.net/strgsayt-dev1/sayt-dev1-node0-osdisk.vhd
        - name: disk1
          azureDisk:
            diskName: sayt-dev1-node1-osdisk.vhd
            diskURI: https://saytdev1.blob.core.windows.net/strgsayt-dev1/sayt-dev1-node1-osdisk.vhd
        - name: disk2
          azureDisk:
            diskName: sayt-dev1-node2-osdisk.vhd
            diskURI: https://saytdev1.blob.core.windows.net/strgsayt-dev1/sayt-dev1-node2-osdisk.vhd
      imagePullSecrets:
      - name: a_key

My pods stop in ContainerCreating status, with the following message:

FailedSync Error syncing pod, skipping: timeout expired waiting for volumes to attach/mount for pod "sayt-j8uwl"/"default". list of unattached/unmounted volumes=[disk0 disk1 disk2]

Here are the logs for kubernetes-controller pod:

E1102 00:48:45.810937       1 nestedpendingoperations.go:253] Operation for "\"kubernetes.io/azure-disk/sayt-dev1-node2-osdisk.vhd\"" failed. No retries permitted until 2016-11-02 00:49:01.810922747 +0000 UTC (durationBeforeRetry 16s). Error: AttachVolume.Attach failed for volume "kubernetes.io/azure-disk/sayt-dev1-node2-osdisk.vhd" (spec.Name: "disk2") from node "sayt-dev1-node-2" with: Attach volume "sayt-dev1-node2-osdisk.vhd" to instance "sayt-dev1-node-2" failed with compute.VirtualMachinesClient#CreateOrUpdate: Failure sending request: StatusCode=200 -- Original Error: Long running operation terminated with status 'Failed': Code="AcquireDiskLeaseFailed" Message="Failed to acquire lease while creating disk 'sayt-dev1-node2-osdisk.vhd' using blob with URI https://saytdev1.blob.core.windows.net/strgsayt-dev1/sayt-dev1-node2-osdisk.vhd. Blob is already in use."
I1102 00:49:01.847372       1 reconciler.go:170] Started AttachVolume for volume "kubernetes.io/azure-disk/sayt-dev1-node2-osdisk.vhd" to node "sayt-dev1-node-1"

I'm not sure I understand the error as I'm not attaching the volume anywhere else.

By the way I'm using a recent version of kubernetes-anywhere, and kubectl version shows:

Client Version: version.Info{Major:"1", Minor:"3", GitVersion:"v1.3.4", GitCommit:"dd6b458ef8dbf24aff55795baa68f83383c9b3a9", GitTreeState:"clean", BuildDate:"2016-08-01T16:45:16Z", GoVersion:"go1.6.2", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"4+", GitVersion:"v1.4.0-alpha.3", GitCommit:"b44b716965db2d54c8c7dfcdbcb1d54792ab8559", GitTreeState:"clean", BuildDate:"2016-08-25T18:31:09Z", GoVersion:"go1.6.3", Compiler:"gc", Platform:"linux/amd64"}

Azure persistent disk not mounted

I've tried your demo, to test both the native loadbalancers and the Azure Disks, and the disks don't seem to mount. FTR I'm using Kubernetes 1.4 and setup the cluster with kubernetes-anywhere with your pr-updates branch.

After creating the VHD with your script and deploying test-azure-disk, I get an IP from the load-balancer but nothing regarding the azure disk:

kubectl --kubeconfig kubeconfig.json describe pod test-azure-disk-349925749-3l7y5
...
Volumes:
  volume-azuredisk:
    Type:   EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:

I don't see anything related to the azure disk in the controller manager logs, besides the startup message:

kubectl --kubeconfig kubeconfig.json logs --namespace=kube-system kube-controller-manager-kubeanywhere-master |grep azure-disk
I0928 10:45:51.286094       1 plugins.go:352] Loaded volume plugin "kubernetes.io/azure-disk"
I0928 14:59:00.714628       1 servicecontroller.go:285] Ensuring LB for service default/test-azure-disk
I0928 14:59:00.714804       1 azure_loadbalancer.go:67] ensure(default/test-azure-disk): START clusterName="kubeanywhere" lbName="kubeanywhere"
I0928 14:59:00.963850       1 replica_set.go:482] Too few "default"/"test-azure-disk-349925749" replicas, need 1, creating 1
I0928 14:59:00.968646       1 event.go:217] Event(api.ObjectReference{Kind:"Deployment", Namespace:"default", Name:"test-azure-disk", UID:"1703a90e-858c-11e6-8cc1-000d3a20f494", APIVersion:"extensions", ResourceVersion:"30919", FieldPath:""}): type: 'Normal' reason: 'ScalingReplicaSet' Scaled up replica set test-azure-disk-349925749 to 1
I0928 14:59:00.992948       1 event.go:217] Event(api.ObjectReference{Kind:"ReplicaSet", Namespace:"default", Name:"test-azure-disk-349925749", UID:"17046208-858c-11e6-8cc1-000d3a20f494", APIVersion:"extensions", ResourceVersion:"30920", FieldPath:""}): type: 'Normal' reason: 'SuccessfulCreate' Created pod: test-azure-disk-349925749-3l7y5
I0928 14:59:00.997306       1 deployment_controller.go:465] Error syncing deployment default/test-azure-disk: Operation cannot be fulfilled on deployments.extensions "test-azure-disk": the object has been modified; please apply your changes to the latest version and try again
I0928 14:59:01.026695       1 deployment_controller.go:465] Error syncing deployment default/test-azure-disk: Operation cannot be fulfilled on deployments.extensions "test-azure-disk": the object has been modified; please apply your changes to the latest version and try again
I0928 15:01:02.211146       1 azure_loadbalancer.go:135] ensure(test-azure-disk): FINISH - xxx.xxx.xxx.xxx

Is this related to persistent volume claims? Do we need to create the Azure storage class first?

phase1.azure.use_ephemeral_drive not found

I'm sorry if this repo shouldn't be used, but I had no luck using other methods for deploying k8s on Azure.

Following instructions as is, fails to deploy the master node because it seems to be missing the value phase1.azure.use_ephemeral_drive.

Adding it to the phase1/azure/Kconfig file (in the dev container) seems to fix the problem, and I was able to deploy a cluster.

Also you have to choose the cluster name to be globally unique, since it gets used to name a storage account.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.