简体   繁体   English

Cloud Foundry bosh错误100:找不到网络

[英]Cloud Foundry bosh Error 100: Can't find network

I'm attempting to setup a service broker to add postgres to our Cloud Foundry installation. 我正在尝试设置服务代理以将postgres添加到我们的Cloud Foundry安装中。 We're running our system on vmWare. 我们正在vmWare上运行我们的系统。 I'm using this release in order to do that: 我正在使用此发行版来做到这一点:

cf-services-contrib-release cf-services-contrib-release

I need to setup the networks: section in the manifest, and what I'm setting there isn't working. 我需要在清单中设置“ networks:”部分,而我在其中设置的内容无效。

This is what my networks look like in the vmWare vCenter UI: 这是我的网络在vmWare vCenter UI中的外观:

vmWare vCenter网络

And this is what my clusters and resource pools look like in the vCenter UI: 这就是我的群集和资源池在vCenter UI中的外观:

vmWare Vcenter群集和资源池

I tried both with and without quotes, around the 'name' of the network. 我在网络的“名称”周围尝试使用带引号和不带引号。 But I'm now getting an error saying that bosh can't find the network: 但是我现在收到一个错误消息,说波什找不到网络:

 Failed compiling packages > rootfs_lucid64/9b3f611b46e076b94b37645c98f9100e7bcef5dd: Can't find network: VLAN1130_LB_100.114.130.0 (00:00:01)
   Failed compiling packages > postgresql93/06163819b694f8d9836586d024f64c11efe30180: Can't find network: VLAN1130_LB_100.114.130.0 (00:00:01)
   Failed compiling packages > postgresql92/2867893e714aae6e6b76bd06e7aa30d47023c46e: Can't find network: VLAN1130_LB_100.114.130.0 (00:00:01)

Error 100: Can't find network: VLAN1130_LB_100.114.130.0

Task 2430 error

This was my latest configuration attempt: 这是我最新的配置尝试:

networks:
- name: default
  type: manual
  subnets:
  - range: 100.114.130.0/24
    gateway: 100.114.130.1
    cloud_properties:
      name: VLAN1130_LB_100.114.130.0

I also tried using single quotes as below. 我还尝试使用单引号,如下所示。 But I got the same error as above! 但是我遇到了与上面相同的错误!

networks:
- name: default
  type: manual
  subnets:
  - range: 100.114.130.0/24
    gateway: 100.114.130.1
    cloud_properties:
      name: 'VLAN1130_LB_100.114.130.0'

Our network that we're on is this one: 100.114.130.0/24 我们所处的网络就是这个:100.114.130.0/24

So it makes sense to select VLAN1130_LB_100.114.130.0 in the config. 因此,在配置中选择VLAN1130_LB_100.114.130.0是有意义的。

I've tried setting all of these options in the yaml file with no quotes. 我已经尝试在yaml文件中设置所有这些选项,且不使用引号。 And none of them seem to work! 而且它们似乎都不起作用!

 <ul> <li>USH_UCS_CLOUD_FOUNDRY: <a href="https://gist.github.com/bluethundr/18ac490e96a5e02fad65">postgres_2432_debug.txt</li> <li>USH_UCS_CLOUD_FOUNDRY_DVS: <a href="https://gist.github.com/bluethundr/4b02c7359b6415bde97f">postgres_2433_debug.txt</a></li> <li>USH_UCS_CLOUD_FO-DVUplinks-435272: <a href="https://gist.github.com/bluethundr/e357ad872a40ac85b9ca">postgres_2434_debug.txt</a> </li> <li>VLAN1129_LB_100.114.129.0: <a href="https://gist.github.com/bluethundr/ebd88c27cab3cd2b6804">postgres_2435_debug.txt</a></li> <li>VLAN1130_LB_100.114.130.0: <a href="https://gist.github.com/bluethundr/b7eeb43e3d96f1a85578">postgres_2436_debug.txt</a></li> <li>VLAN14-ESXI_MGMT-3.156.14.0: <a href="https://gist.github.com/bluethundr/dbde624e63842721a133">postgres_2437_debug.txt</li> </ul> 

I wouldn't expect VLAN1129_LB_100.114.129.0 to work, but I tried it anyway, just to be complete. 我不希望VLAN1129_LB_100.114.129.0能够正常工作,但无论如何我还是尝试了一下,只是为了完整起见。

I've supplied debug dumps of each failed attempt next to each setting you see above. 我在上面看到的每个设置旁边都提供了每次失败尝试的调试转储。 Surely one of them must work! 当然其中之一必须工作! But as you can see none of them did. 但是正如您所看到的,它们都没有。

Here's my complete yaml file that I deployed with the 'bosh deploy' command: 这是我使用“ bosh deploy”命令部署的完整yaml文件:

name: cf-22b9f4d62bb6f0563b71 
director_uuid: fd713790-b1bc-401a-8ea1-b8209f1cc90c 

releases:
  - name: cf-services-contrib
    version: 6 

compilation:
  workers: 3
  network: default
  reuse_compilation_vms: true
  cloud_properties:
    ram: 5120 
    disk: 10240 
    cpu: 2

update:
  canaries: 1
  canary_watch_time: 30000-60000
  update_watch_time: 30000-60000
  max_in_flight: 4

networks:
- name: default
  type: manual 
  subnets:
  - range: 100.114.130.0/24
    gateway: 100.114.130.1
    cloud_properties:
      name: VLAN1130_LB_100.114.130.0 

resource_pools:
- name: 'USH_UCS_CLOUD_FOUNDRY_NONPROD_01_RP' 
  network: default
  stemcell:
    name: bosh-vsphere-esxi-ubuntu-trusty-go_agent
    version: '2865.1' 
  cloud_properties:
    cpu: 2
    ram: 4096 
    disk: 10240
    datacenters:
    - name: 'Universal City' 
      clusters:
      - USH_UCS_CLOUD_FOUNDRY_NONPROD_01: {resource_pool: 'USH_UCS_CLOUD_FOUNDRY_NONPROD_01_RP'}

jobs:
  - name: gateways
    release: cf-services-contrib
    templates:
    - name: postgresql_gateway_ng
    instances: 1
    resource_pool: 'USH_UCS_CLOUD_FOUNDRY_NONPROD_01_RP' 
    networks:
      - name: default
        default: [dns, gateway]
    properties:
      # Service credentials
      uaa_client_id: "cf"
      uaa_endpoint: http://uaa.devcloudwest.example.com
      uaa_client_auth_credentials:
        username: admin
        password: secret 


  - name: postgresql_service_node
    release: cf-services-contrib
    template: postgresql_node_ng
    instances: 1
    resource_pool: 'USH_UCS_CLOUD_FOUNDRY_NONPROD_01_RP' 
    persistent_disk: 10000
    properties:
      postgresql_node:
        plan: default
    networks:
      - name: default
        default: [dns, gateway]

properties:
  networks:
    apps: default
    management: default

  cc:
    srv_api_uri: http://api.devcloudwest.example.com

  nats:
    address: 100.114.130.11 
    port: 25555 
    user: nats #CHANGE
    password: secret 
    authorization_timeout: 5

  service_plans:
    postgresql:
      default:
        description: "Developer, 250MB storage, 10 connections"
        free: true
        job_management:
          high_water: 230
          low_water: 20
        configuration:
          capacity: 125
          max_clients: 10
          quota_files: 4
          quota_data_size: 240
          enable_journaling: true
          backup:
            enable: false
          lifecycle:
            enable: false
            serialization: enable
            snapshot:
              quota: 1

  postgresql_gateway:
    token: f75df200-4daf-45b5-b92a-cb7fa1a25660
    default_plan: default
    supported_versions: ["9.3"]
    version_aliases:
      current: "9.3"
    cc_api_version: v2
  postgresql_node:
    supported_versions: ["9.3"]
    default_version: "9.3"
    max_tmp: 900
    password: secret 

How can we get past this issue? 我们如何克服这个问题?

From Amit's comment : 阿米特的评论

The name used in Cloud Properties must include any nested sub-folders. “云属性”中使用的名称必须包括任何嵌套的子文件夹。 In the provided configuration the network is nested under USH_UCS_CLOUD_FOUNDRY, so the value for name should reflect that, ie USH_UCS_CLOUD_FOUNDRY/VLAN1130_LB_100.114.130.0 no quotes are required. 在提供的配置中,网络嵌套在USH_UCS_CLOUD_FOUNDRY下,因此name的值应反映出来,即USH_UCS_CLOUD_FOUNDRY/VLAN1130_LB_100.114.130.0不需要引号。

networks:
- name: default
  type: manual
  subnets:
  - range: 100.114.130.0/24
    gateway: 100.114.130.1
    cloud_properties:
      name: USH_UCS_CLOUD_FOUNDRY/VLAN1130_LB_100.114.130.0

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM