Skip to content

[BUG] Job 'topo' aborted due to plugin failure (cause=ValueError('A string literal cannot contain NUL (0x00) characters.')) #2479

@oh01

Description

@oh01

Hello,
we have encoutered the same error on our Aruba 6200F as in ticket #2176 which was closed due to the lack of feedback. Whole tracelog follows below.
I have turned on debug logs as suggested in previous ticket and I've found the issue is in one PC that is sending name of the PC instead of MAC address in LLDP entry:

LLDPNeighbor(ifindex=129, chassis_id=local('\x00\x00\x00\x00\x00\x00'), port_id=local('port-001'), port_desc='', sysname='PC-NAME'),

Output from switch for command 'show lldp neighbor-info' is:

LOCAL-PORT  CHASSIS-ID         PORT-ID                      PORT-DESC                    TTL      SYS-NAME
-----------------------------------------------------------------------------------------------------------
3/1/1       pc-name      port-001                                                  20       PC-NAME

For now I have disabled LLDP for this port which allows topology to complete the query without crashing.
Please let me know if I can debug this further.

Thank you!

Tracebacks

Traceback (most recent call last):
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/internet/defer.py", line 501, in errback
    self._startRunCallbacks(fail)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/internet/defer.py", line 568, in _startRunCallbacks
    self._runCallbacks()
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/internet/defer.py", line 654, in _runCallbacks
    current.result = callback(current.result, *args, **kw)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/internet/defer.py", line 1475, in gotResult
    _inlineCallbacks(r, g, status)
--- <exception caught here> ---
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/internet/defer.py", line 1416, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/python/failure.py", line 512, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/plugins/lldp.py", line 85, in handle
    yield run_in_thread(self._process_remote)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/python/threadpool.py", line 250, in inContext
    result = inContext.theWork()
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/python/threadpool.py", line 266, in <lambda>
    inContext.theWork = lambda: context.call(ctx, func, *args, **kw)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/opt/venvs/nav/lib/python3.7/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/db.py", line 107, in _reset
    return func(*args, **kwargs)
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/plugins/lldp.py", line 156, in _process_remote
    neighbors = [LLDPNeighbor(lldp) for lldp in self.remote]
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/plugins/lldp.py", line 156, in <listcomp>
    neighbors = [LLDPNeighbor(lldp) for lldp in self.remote]
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/neighbor.py", line 126, in __init__
    self.identify()
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/neighbor.py", line 129, in identify
    self.netbox = self._identify_netbox()
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/plugins/lldp.py", line 230, in _identify_netbox
    netbox = lookup(str(chassid))
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/plugins/lldp.py", line 242, in _netbox_from_local
    info_set__value=str(chassid),
  File "/opt/venvs/nav/lib/python3.7/site-packages/nav/ipdevpoll/neighbor.py", line 203, in _netbox_query
    netbox = manage.Netbox.objects.values('id', 'sysname').get(query)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/query.py", line 431, in get
    num = len(clone)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/query.py", line 262, in __len__
    self._fetch_all()
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/query.py", line 1324, in _fetch_all
    self._result_cache = list(self._iterable_class(self))
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/query.py", line 109, in __iter__
    for row in compiler.results_iter(chunked_fetch=self.chunked_fetch, chunk_size=self.chunk_size):
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/sql/compiler.py", line 1130, in results_iter
    results = self.execute_sql(MULTI, chunked_fetch=chunked_fetch, chunk_size=chunk_size)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/models/sql/compiler.py", line 1175, in execute_sql
    cursor.execute(sql, params)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/backends/utils.py", line 66, in execute
    return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/backends/utils.py", line 75, in _execute_with_wrappers
    return executor(sql, params, many, context)
  File "/opt/venvs/nav/lib/python3.7/site-packages/django/db/backends/utils.py", line 84, in _execute
    return self.cursor.execute(sql, params)
builtins.ValueError: A string literal cannot contain NUL (0x00) characters.

Environment:

  • NAV 5.4.0
  • Debian 10
  • used pre-packaged OVF from NAV 4.X

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions