Project

General

Profile

Bug #10966

mdb cannot show smbsrv sessions

Added by Gordon Ross 9 months ago. Updated 9 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Start date:
2019-05-14
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

After some changes merged from upstream, ::smblist is failing with "inexact match for union au_addr (au_addr)".

History

#1

Updated by Gordon Ross 9 months ago

  • Status changed from New to In Progress
#2

Updated by Gordon Ross 9 months ago

This happens because mdb is being rather strict about unions (until #8024)
and the smbsrv mdb module is assuming we can use any union arm of
the struct smb_inaddr_t and that causes ctf_vread to fail.

As described above mdb_ctf_vread(), the recommended way to read a
union is to use an mdb struct with only the union "arm" appropriate
to the given type instance. That's inconvenient here, so we just
use a local union with only the in6_addr_t union arm (otherwise
identical to smb_inaddr_t) and just cast it to an smb_inaddr_t

#3

Updated by Gordon Ross 9 months ago

Testing: mdb -k -e ::smblist

#4

Updated by Joshua M. Clulow 9 months ago

  • Description updated (diff)
  • Tags deleted (needs-triage)
#5

Updated by Electric Monk 9 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit 3cc23d49ba5cd4f88efdb1edefd25a61de55f098

commit  3cc23d49ba5cd4f88efdb1edefd25a61de55f098
Author: Gordon Ross <gwr@nexenta.com>
Date:   2019-05-18T23:46:45.000Z

    10966 mdb cannot show smbsrv sessions
    Reviewed by: Dan Fields <dan.fields@nexenta.com>
    Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
    Reviewed by: Evan Layton <evan.layton@nexenta.com>
    Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
    Approved by: Joshua M. Clulow <josh@sysmgr.org>

Also available in: Atom PDF