Not getting network lease

Hi,

After upgrading from 5.4 to 5.4 we find that non-oneadmin users fail to get network leases. Below is information for an example user 179 group 103 with network 8. The network part of the template used to instantiate the VM is missing in the template of the running VM.

Any help/pointers would be appreciated.

Regards,
  Gerry

$ oneacl list
ID USER RES_VHNIUTGDCOZSvRMAP RID OPE_UMAC ZONE
0 @1 V–I-T—O-S----P * —c *
1 * ----------Z------ * u— *
2 * --------------MA- * u— *
3 @1 -H--------------- * -m-- #0
4 @1 --N----D--------- * u— #0
5 @100 -H--------------- * -m-- #0
6 @100 --N----D--------- * u— #0
21 @101 V–I-T—O------- * —c *
22 @102 V–I-T—O------- * —c *
23 @103 V–I-T—O------- * —c *
29 @102 -H--------------- * -m-- #0
45 @103 -HN-------------- * -m-- #0

*** User Info ***

179 testresearcher rsearchers core 1 / 16 512M / 10G 0.2 / 8.0

USER 179 INFORMATION
ID : 179
NAME : testresearcher
GROUP : rsearchers
PASSWORD : XXXXXXXXXXXXXXXXX
AUTH_DRIVER : core
ENABLED : Yes

TOKENS

USER TEMPLATE
TOKEN_PASSWORD=“XXXXXXXXXXXXXXXXXXXXXX”

RESOURCE USAGE & QUOTAS

NUMBER OF VMS               MEMORY                  CPU     SYSTEM_DISK_SIZE
  1 /      16      512M /      10G      0.25 /     8.00       10G /        -

DATASTORE ID IMAGES SIZE
107 0 / 20 0M / 40G

NETWORK ID LEASES
8 0 / 16

IMAGE ID          RUNNING VMS
     352         1 /        -

*** Group Info ***

103 rsearchers 1 1 / - 512M / - 0.2 / -

GROUP 103 INFORMATION
ID : 103
NAME : rsearchers

GROUP TEMPLATE
SUNSTONE=[
GROUP_ADMIN_DEFAULT_VIEW=“groupadmin”,
GROUP_ADMIN_VIEWS=“groupadmin” ]

USER ID ADMIN
179

RESOURCE USAGE & QUOTAS

NUMBER OF VMS               MEMORY                  CPU     SYSTEM_DISK_SIZE
  1 /       -      512M /        -      0.25 /        -       10G /        -

DATASTORE ID IMAGES SIZE
102 3 / - 170G / -

NETWORK ID LEASES
8 0 / 10

IMAGE ID          RUNNING VMS
     352         1 /        -

*** Network Quota ***

NETWORK=[
ID=“8”,
LEASES=“16”,
LEASES_USED=“0” ]

*** Network Info ***

VIRTUAL NETWORK 8 INFORMATION
ID : 8
NAME : ResearchNET [routed]
USER : oneadmin
GROUP : rsearchers
LOCK : None
CLUSTERS : 0,100
BRIDGE : br63
VN_MAD : dummy
AUTOMATIC VLAN ID : NO
AUTOMATIC OUTER VLAN ID : NO
USED LEASES : 4

PERMISSIONS
OWNER : uma
GROUP : um-
OTHER : —

VIRTUAL NETWORK TEMPLATE
BRIDGE=“br63”
DESCRIPTION=“Routed network for Research VMs”
GATEWAY=“10.63.255.254”
GUEST_MTU=“1500”
NETWORK_ADDRESS=“10.63.0.0”
PHYDEV=""
SECURITY_GROUPS=“0”
VN_MAD=“dummy”

ADDRESS RANGE POOL
AR 0
SIZE : 65500
LEASES : 4

RANGE FIRST LAST
MAC 02:00:0a:3f:00:0b 02:00:0a:3f:ff:e6
IP 10.63.0.11 10.63.255.230

LEASES
AR OWNER MAC IP IP6
0 V:2234 02:00:0a:3f:00:0b 10.63.0.11 -
0 V:2235 02:00:0a:3f:00:0c 10.63.0.12 -
0 V:2236 02:00:0a:3f:00:0d 10.63.0.13 -
0 V:2237 02:00:0a:3f:00:0e 10.63.0.14 -

VIRTUAL ROUTERS

*** VM and Template Info ***

Here is the template used. The network section get dropped in the running VM. Despite the SCHED_MESSAGE text the VM is actually running.

$ onetemplate show 376
TEMPLATE 376 INFORMATION
ID : 376
NAME : [VM] DebianStretchResearch[v02]
USER : oneadmin
GROUP : rsearchers
LOCK : None
REGISTER TIME : 09/06 12:59:28

PERMISSIONS
OWNER : um-
GROUP : u–
OTHER : —

TEMPLATE CONTENTS
CPU=“0.25”
DISK=[
IMAGE=" [VM] DebianStretch [v02]",
IMAGE_UNAME=“oneadmin” ]
GRAPHICS=[
LISTEN=“0.0.0.0”,
TYPE=“VNC” ]
INPUTS_ORDER=""
MEMORY=“512”
MEMORY_UNIT_COST=“MB”
NIC=[
NETWORK=“ResearchNET [routed]”,
NETWORK_UNAME=“oneadmin” ]
OS=[
ARCH=“x86_64”,
BOOT="" ]
VCPU=“2”

$onevm show 2233
VIRTUAL MACHINE 2233 INFORMATION
ID : 2233
NAME : [VM] DebianStretchResearch[v02]-2233
USER : testresearcher
GROUP : rsearchers
STATE : ACTIVE
LCM_STATE : RUNNING
LOCK : None
RESCHED : No
HOST : host021.scss.tcd.ie
CLUSTER ID : 100
CLUSTER : SCSSnimbus
START TIME : 09/06 16:56:24
END TIME : -
DEPLOY ID : one-2233

VIRTUAL MACHINE MONITORING
CPU : 0.0
MEMORY : 512M
DISKRDBYTES : 155367936
DISKRDIOPS : 60235
DISKWRBYTES : 10850304
DISKWRIOPS : 686

PERMISSIONS
OWNER : um-
GROUP : —
OTHER : —

VM DISKS
ID DATASTORE TARGET IMAGE SIZE TYPE SAVE
0 TeachingOn hda [VM] DebianStretch [v02] 17M/10G file NO

VIRTUAL MACHINE HISTORY
SEQ UID REQ HOST ACTION DS START TIME PROLOG
0 - - host021.scss none 0 09/06 16:56:44 0d 20h51m 0h00m03s

USER TEMPLATE
INPUTS_ORDER=""
MEMORY_UNIT_COST=“MB”
SCHED_MESSAGE=“Thu Sep 6 16:56:46 2018 : Cannot dispatch VM to any Host. Possible reasons: Not enough capacity in Host or System DS, or dispatch limit reached”

VIRTUAL MACHINE TEMPLATE
AUTOMATIC_DS_REQUIREMENTS="(“CLUSTERS/ID” @> 100)"
AUTOMATIC_REQUIREMENTS="(CLUSTER_ID = 100) & !(PUBLIC_CLOUD = YES)"
CPU=“0.25”
GRAPHICS=[
LISTEN=“0.0.0.0”,
PORT=“8133”,
TYPE=“VNC” ]
MEMORY=“512”
OS=[
ARCH=“x86_64”,
BOOT="" ]
TEMPLATE_ID=“376”
VCPU=“2”
VMID=“2233”


Gerry O’Brien

Systems Manager
School of Computer Science and Statistics
Trinity College Dublin
Dublin 2
IRELAND

00 353 1 896 1341


Versions of the related components and OS (frontend, hypervisors, VMs):

Steps to reproduce:

Current results:

Expected results:

Hi,

We have some further details on this problem. The issue appears to relate to Sunstone views. In /etc/one/sunstone-views.yaml we have a custom view as the default. If we put the users.yaml view as the default the problems goes away. This is strange as one would imagine that a view should not be related to how the network is leased in a template instantiate. The obvious place to look is the “Networking.” settings. We tried changing them back individually but could not get it to work.

Below is a diff between users.yaml and our cistom view.

This used to work fine in 5.4. I hope you can help me with this.

Regards,
    Gerry

11,12c11,12
< - oneflow-services-tab
< - vrouters-tab

#- oneflow-services-tab
#- vrouters-tab

15,16c15,16
< - oneflow-templates-tab
< - vrouter-templates-tab

#- oneflow-templates-tab
#- vrouter-templates-tab

18c18
< - datastores-tab

#- datastores-tab

25,26c25,26
< - vnets-topology-tab
< - secgroups-tab

#- vnets-topology-tab
#- secgroups-tab

48c48,50
< # True to hide the CPU setting in the VM creation dialog

# True to hide the CPU setting in the VM creation dialog. The CPU setting
# will be set to the same value as VCPU, that will still be visible for the
# end users

51c53
< # False to not scale the CPU. Number to scale from VCPU

# False to not scale the CPU. Number [0, 1] to scale from VCPU

57,68d58
< # True to show the datastore datatable to instantiate VM
< show_ds_instantiate: false
<
< # True to show the vmgroup datatable to instantiate VM
< show_vmgroup_instantiate: true
<
< # True to show the vnet datatable to instantiate VM
< show_vnet_instantiate: true
<
< # True to show the host datatable to instantiate VM
< show_host_instantiate: false
<
72,85d61
<
< # True to show the monitoring info (VM & VRouters)
< show_monitoring_info: true
<
< # True to show the attributes info (VM & VRouters)
< show_attributes_info: true
<
< # If it is set to true, the host capacity will be checked. This will only affect oneadmin requests,
< # regular users resize requests will always be enforced
< resize_enforce: false
<
< deploy_enforce: false
<
< migrate_enforce: false
138,147c114,123
< User.create_dialog: true
< User.update_password: true
< User.login_token: true
< User.quotas_dialog: true
< User.groups_dialog: true
< User.chgrp: true
< User.change_authentication: true
< User.delete: true
< User.edit_labels: true
< User.menu_labels: true

        User.create_dialog: false
        User.update_password: false
        User.login_token: false
        User.quotas_dialog: false
        User.groups_dialog: false
        User.chgrp: false
        User.change_authentication: false
        User.delete: false
        User.edit_labels: false
        User.menu_labels: false

166,172c142,148
< Group.create_dialog: true
< Group.update_dialog: true
< Group.quotas_dialog: true
< Group.delete: true
< Group.edit_admins: true
< Group.edit_labels: true
< Group.menu_labels: true

        Group.create_dialog: false
        Group.update_dialog: false
        Group.quotas_dialog: false
        Group.delete: false
        Group.edit_admins: false
        Group.edit_labels: false
        Group.menu_labels: false

230c206
< Template.import_dialog: false

        Template.import_dialog: true

236c212
< Template.chmod: true

        Template.chmod: flase

241,242c217,218
< Template.edit_labels: true
< Template.menu_labels: true

        Template.edit_labels: false
        Template.menu_labels: false

251d226
< actions: true
343,345c318,320
< #- 6 # Used CPU
< #- 7 # Used Memory
< - 8 # Host

        - 6       # Used CPU
        - 7       # Used Memory
        #- 8       # Host

358c333
< VM.chmod: true

        VM.chmod: false

393,394c368,369
< VM.edit_labels: true
< VM.menu_labels: true

        VM.edit_labels: false
        VM.menu_labels: false

467,476c442,451
< VirtualRouter.create_dialog: true
< VirtualRouter.rename: true
< VirtualRouter.chown: true
< VirtualRouter.chgrp: true
< VirtualRouter.chmod: true
< VirtualRouter.delete: true
< VirtualRouter.attachnic: true
< VirtualRouter.detachnic: true
< VirtualRouter.edit_labels: true
< VirtualRouter.menu_labels: true

        VirtualRouter.create_dialog: false
        VirtualRouter.rename: false
        VirtualRouter.chown: false
        VirtualRouter.chgrp: false
        VirtualRouter.chmod: false
        VirtualRouter.delete: false
        VirtualRouter.attachnic: false
        VirtualRouter.detachnic: flase
        VirtualRouter.edit_labels: false
        VirtualRouter.menu_labels: false

496,501c471,476
< Cluster.create_dialog: true
< Cluster.update_dialog: true
< Cluster.delete: true
< Cluster.rename: true
< Cluster.edit_labels: true
< Cluster.menu_labels: true

        Cluster.create_dialog: false
        Cluster.update_dialog: false
        Cluster.delete: false
        Cluster.rename: false
        Cluster.edit_labels: false
        Cluster.menu_labels: false

582c557
< Datastore.rename: true

        Datastore.rename: false

585c560
< Datastore.chmod: true

        Datastore.chmod: false

589,590c564,565
< Datastore.edit_labels: true
< Datastore.menu_labels: true

        Datastore.edit_labels: false
        Datastore.menu_labels: false

615c590
< Image.import_dialog: false

        Image.import_dialog: true

681,689c656,664
< MarketPlace.create_dialog: true
< MarketPlace.update_dialog: true
< MarketPlace.rename: true
< MarketPlace.chown: true
< MarketPlace.chgrp: true
< MarketPlace.chmod: true
< MarketPlace.delete: true
< MarketPlace.edit_labels: true
< MarketPlace.menu_labels: true

        MarketPlace.create_dialog: false
        MarketPlace.update_dialog: false
        MarketPlace.rename: false
        MarketPlace.chown: false
        MarketPlace.chgrp: false
        MarketPlace.chmod: false
        MarketPlace.delete: false
        MarketPlace.edit_labels: false
        MarketPlace.menu_labels: false

711c686
< MarketPlaceApp.create_dialog: true

        MarketPlaceApp.create_dialog: false

714,722c689,697
< MarketPlaceApp.rename: true
< MarketPlaceApp.chown: true
< MarketPlaceApp.chgrp: true
< MarketPlaceApp.chmod: true
< MarketPlaceApp.enable: true
< MarketPlaceApp.disable: true
< MarketPlaceApp.delete: true
< MarketPlaceApp.edit_labels: true
< MarketPlaceApp.menu_labels: true

        MarketPlaceApp.rename: false
        MarketPlaceApp.chown: false
        MarketPlaceApp.chgrp: false
        MarketPlaceApp.chmod: false
        MarketPlaceApp.enable: false
        MarketPlaceApp.disable: false
        MarketPlaceApp.delete: false
        MarketPlaceApp.edit_labels: false
        MarketPlaceApp.menu_labels: false

751c726
< Network.update_dialog: true

        Network.update_dialog: false

754c729
< Network.rename: true

        Network.rename: false

757,758c732,733
< Network.chmod: true
< Network.delete: true

        Network.chmod: false
        Network.delete: false

762,765c737,740
< Network.remove_ar: true
< Network.update_ar: true
< Network.edit_labels: true
< Network.menu_labels: true

        Network.remove_ar: false
        Network.update_ar: false
        Network.edit_labels: false
        Network.menu_labels: false

787,797c762,772
< SecurityGroup.create_dialog: true
< SecurityGroup.update_dialog: true
< SecurityGroup.rename: true
< SecurityGroup.chown: true
< SecurityGroup.chgrp: true
< SecurityGroup.chmod: true
< SecurityGroup.clone_dialog: true
< SecurityGroup.commit_dialog: true
< SecurityGroup.delete: true
< SecurityGroup.edit_labels: true
< SecurityGroup.menu_labels: true

        SecurityGroup.create_dialog: false
        SecurityGroup.update_dialog: false
        SecurityGroup.rename: false
        SecurityGroup.chown: false
        SecurityGroup.chgrp: false
        SecurityGroup.chmod: false
        SecurityGroup.clone_dialog: false
        SecurityGroup.commit_dialog: false
        SecurityGroup.delete: false
        SecurityGroup.edit_labels: false
        SecurityGroup.menu_labels: false

852c827
< VMGroup.chgrp: true
\ No newline at end of file

       VMGroup.chgrp: true