Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] configuration enable not working for eve-ng CLI #167

Open
UchihaItachiSama opened this issue Jul 7, 2022 · 0 comments
Open

[BUG] configuration enable not working for eve-ng CLI #167

UchihaItachiSama opened this issue Jul 7, 2022 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@UchihaItachiSama
Copy link

Describe the bug

Python 3.9.1
eve-ng, version 0.2.7

When using eve-ng CLI app to create topology the configuration enable is not working.

To Reproduce

following is the topology definition file:

---
  name: AVD_LAB_TESTING
  description: EVPN AVD_LAB_TESTING
  path: "/himanshu/"
  author: "himanshu"
  nodes:
    - name: DC1_SPINE1
      template: veos
      image: veos-4.28.1F
      node_type: qemu
      left: 405
      top: 216
      cpu: 2
      ram: 3072
      configuration:
        file: configs/DC1_SPINE1.cfg
    - name: JumpBox
      template: veos
      image: veos-4.28.1F
      node_type: qemu
      left: 702
      top: 51
      cpu: 2
      ram: 2048
      ethernet: 11
  networks:
    - name: Net
      network_type: pnet0
      visibility: 1
      top: 36
      left: 243
  links:
    network:
      - {"src": "JumpBox", "src_label": "Mgmt1", "dst": "Net"}
    node:
      - {"src": "DC1_SPINE1", "src_label": "Mgmt1", "dst": "JumpBox", "dst_label": "Eth1", "media": "ethernet"}
(source .env && eve-ng lab create-from-topology -t templates/evpn-a-a-mh.yml)

[21:43:12] Lab created: /himanshu//AVD_LAB_TESTING.unl                                                                                                             commands.py:452
[21:43:13] node DC1_SPINE1 completed                                                                                                                               commands.py:202
           node JumpBox completed                                                                                                                                  commands.py:202
           network Net completed. ID: 1                                                                                                                            commands.py:226
[21:43:14] link JumpBox:Mgmt1 -> Net completed                                                                                                                     commands.py:146
[21:43:15] link DC1_SPINE1:Mgmt1 <-> JumpBox:Eth1 completed                                                                                                        commands.py:166

Expected behavior

We can see the config is uploaded,

(source .env && eve-ng node config --node-id 2 --path himanshu/AVD_LAB_TESTING.unl)

!RANCID-CONTENT-TYPE: arista
!
vlan internal order ascending range 1006 1199
!
transceiver qsfp default-mode 4x10G
!
service routing protocols model multi-agent
!
hostname DC1_SPINE1
<snipped>

but seems the enable_node_config is not getting invoked:

(source .env && eve-ng node read --node-id 2 --path himanshu/AVD_LAB_TESTING.unl)

{
  "console": "telnet",
  "config": "0",
  "delay": 0,
  "left": 405,
  "icon": "AristaSW.png",
  "image": "veos-4.28.1F",
  "name": "DC1_SPINE1",
  "status": 0,
  "template": "veos",
  "type": "qemu",
  "top": 216,
  "url": "telnet://<snipped>:33538",
  "cpulimit": 1,
  "cpu": 2,
  "ethernet": 9,
  "ram": 3072,
  "uuid": "fc459b6c-7f18-4c04-8049-97fc2133fa62",
  "qemu_options": "-machine type=pc,accel=kvm -serial mon:stdio -nographic -display none -no-user-config -rtc base=utc -boot order=d",
  "qemu_version": "4.1.0",
  "qemu_arch": "x86_64",
  "qemu_nic": ""
}

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context

It seems there was a previous issue logged for this where the fix #98 was added to devel branch

but in the master we can see the function is different:

 190# configure node
 191if resp["status"] == "success" and config:
 192node_id = resp["data"]["id"]
 193resp = client.api.upload_node_config(path, node_id, config)
 194if resp["status"] == "success":
 195if config := topology.get_node_config(node["name"]):
 196node_id = resp["data"]["id"]
 197resp = client.api.upload_node_config(topology.path, node_id, config)
 198if resp["status"] == "success":
 199client.api.enable_node_config(topology.path, node_id)
@ttafsir ttafsir self-assigned this Jul 8, 2022
@ttafsir ttafsir added the bug Something isn't working label Jul 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants