Thursday 27 May 2021

NetBSD - System Information

NetBSD

A member of the open source family of Berkeley Software Distribution (BSD) UNIX-like operating systems, along with FreeBSD and OpenBSD, NetBSD is available for a wide range of hardware platforms (Platforms supported by NetBSD), including support for many vintage systems.

System Note

The sample results below are taken from a NetBSD system running in a VirtualBox VM on a Intel i7-860 system running MS Windows 10. So some of the hardware information will look a little different from the results running on actual hardware. For example the the processor identification and the number of cores won't match.

Operating System

Commands and files used to obtain information about the operating system:

uname

Operating system name, version, release and platform.

# uname -a
NetBSD netbsd9.home 9.2 NetBSD 9.2 (GENERIC) #0: Wed May 12 13:15:55 UTC 2021  mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC amd64

That is NetBSD version 9.2, release "NetBSD 9.2 (GENERIC) #0: Wed May 12 13:15:55 UTC 2021 mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC", on an amd64 system named "netbsd9.home".

/etc/release

The /etc/release file contains details of the release.

# cat /etc/release
NetBSD 9.2/amd64
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
    2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017,
    2018, 2019, 2020 The NetBSD Foundation, Inc.  All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
    The Regents of the University of California.  All rights reserved.
Build information:
          Build date   Wed May 12 13:15:55 UTC 2021
            Built by   builder@localhost.NetBSD.org
            Build ID   202105121714Z
Build settings:
          DISTRIBVER = '9.2'
  EXTERNAL_TOOLCHAIN = (undefined)
            HAVE_GCC = '7'
            HAVE_GDB = '830'
           HAVE_LLVM = (undefined)
            HAVE_PCC = (undefined)
     INSTALLWORLDDIR = (undefined)
             MACHINE = 'amd64'
        MACHINE_ARCH = 'x86_64'
            MKARZERO = 'yes'
               MKATF = 'yes'
          MKBINUTILS = 'yes'
           MKBSDGREP = 'no'
            MKBSDTAR = 'yes'
          MKCATPAGES = 'no'
       MKCOMPATTESTS = 'no'
         MKCOMPATX11 = 'no'
           MKCOMPLEX = 'yes'
               MKCTF = 'yes'
               MKCVS = 'yes'
               MKCXX = 'yes'
             MKDEBUG = 'yes'
          MKDEBUGLIB = 'no'
               MKDOC = 'yes'
               MKDTC = 'yes'
            MKDTRACE = 'yes'
       MKDYNAMICROOT = 'yes'
            MKEXTSRC = 'no'
          MKFIRMWARE = 'yes'
               MKGCC = 'yes'
           MKGCCCMDS = 'yes'
               MKGDB = 'yes'
             MKGROFF = 'yes'
      MKGROFFHTMLDOC = 'no'
            MKHESIOD = 'yes'
              MKHTML = 'yes'
            MKIEEEFP = 'yes'
             MKINET6 = 'yes'
              MKINFO = 'yes'
          MKIPFILTER = 'yes'
             MKISCSI = 'yes'
          MKKERBEROS = 'yes'
              MKKMOD = 'yes'
              MKKYUA = 'no'
              MKLDAP = 'yes'
            MKLIBCXX = 'no'
         MKLIBSTDCXX = 'yes'
           MKLINKLIB = 'yes'
              MKLINT = 'no'
               MKLLD = 'no'
              MKLLDB = 'no'
              MKLLVM = 'no'
            MKLLVMRT = 'yes'
               MKLVM = 'yes'
         MKMAKEMANDB = 'yes'
               MKMAN = 'yes'
            MKMANDOC = 'yes'
              MKMANZ = 'no'
          MKMCLINKER = 'no'
              MKMDNS = 'yes'
               MKNLS = 'yes'
   MKNOUVEAUFIRMWARE = 'yes'
               MKNPF = 'yes'
               MKNSD = 'no'
               MKOBJ = 'yes'
           MKOBJDIRS = 'yes'
               MKPAM = 'yes'
               MKPCC = 'no'
           MKPERFUSE = 'yes'
                MKPF = 'yes'
               MKPIC = 'yes'
        MKPICINSTALL = 'no'
            MKPICLIB = 'yes'
          MKPIGZGZIP = 'no'
           MKPOSTFIX = 'yes'
           MKPROFILE = 'yes'
    MKRADEONFIRMWARE = 'yes'
             MKREPRO = 'yes'
              MKRUMP = 'yes'
             MKSHARE = 'yes'
              MKSKEY = 'yes'
             MKSLJIT = 'yes'
         MKSOFTFLOAT = 'no'
         MKSTATICLIB = 'yes'
        MKSTRIPIDENT = 'no'
     MKTEGRAFIRMWARE = 'no'
               MKTPM = 'no'
           MKUNBOUND = 'yes'
          MKUNPRIVED = 'yes'
            MKUPDATE = 'no'
               MKX11 = 'yes'
          MKX11FONTS = 'yes'
          MKX11MOTIF = 'no'
       MKXORG_SERVER = 'yes'
                MKYP = 'yes'
               MKZFS = 'yes'
NETBSD_OFFICIAL_RELEASE = 'yes'
          NOCLEANDIR = (undefined)
       NODISTRIBDIRS = (undefined)
          NOINCLUDES = (undefined)
   TOOLCHAIN_MISSING = 'no'
            USETOOLS = 'yes'
          USE_HESIOD = 'yes'
           USE_INET6 = 'yes'
        USE_JEMALLOC = 'yes'
        USE_KERBEROS = 'yes'
            USE_LDAP = 'yes'
             USE_PAM = 'yes'
            USE_SKEY = 'no'
              USE_YP = 'yes'

A lot of stuff here should there be a need to rebuild.

Hardware

dmesg

The system messages from the boot process are typically available using dmesg, if enough system messages have been generated to fill the system message buffer, have a look in /var/run/dmesg.boot to see the boot time messages.

netbsd9# dmesg
[     1.000000] Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
[     1.000000]     2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017,
[     1.000000]     2018, 2019, 2020 The NetBSD Foundation, Inc.  All rights reserved.
[     1.000000] Copyright (c) 1982, 1986, 1989, 1991, 1993
[     1.000000]     The Regents of the University of California.  All rights reserved.
[     1.000000] NetBSD 9.2 (GENERIC) #0: Wed May 12 13:15:55 UTC 2021
[     1.000000]         mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC
[     1.000000] total memory = 4095 MB
[     1.000000] avail memory = 3952 MB
[     1.000000] rnd: seeded with 256 bits
[     1.000000] timecounter: Timecounters tick every 10.000 msec
[     1.000000] Kernelized RAIDframe activated
[     1.000000] running cgd selftest aes-xts-256 aes-xts-512 done
[     1.000000] timecounter: Timecounter "i8254" frequency 1193182 Hz quality 100
[     1.000003] innotek GmbH VirtualBox (1.2)
[     1.000003] mainbus0 (root)
[     1.000003] ACPI: RSDP 0x00000000000E0000 000024 (v02 VBOX  )
[     1.000003] ACPI: XSDT 0x00000000DFFF0030 00003C (v01 VBOX   VBOXXSDT 00000001 ASL  00000061)
[     1.000003] ACPI: FACP 0x00000000DFFF00F0 0000F4 (v04 VBOX   VBOXFACP 00000001 ASL  00000061)
[     1.000003] ACPI: DSDT 0x00000000DFFF0470 002325 (v02 VBOX   VBOXBIOS 00000002 INTL 20100528)
[     1.000003] ACPI: FACS 0x00000000DFFF0200 000040
[     1.000003] ACPI: APIC 0x00000000DFFF0240 00005C (v02 VBOX   VBOXAPIC 00000001 ASL  00000061)
[     1.000003] ACPI: SSDT 0x00000000DFFF02A0 0001CC (v01 VBOX   VBOXCPUT 00000002 INTL 20100528)
[     1.000003] ACPI: 2 ACPI AML tables successfully acquired and loaded
[     1.000003] ioapic0 at mainbus0 apid 2: pa 0xfec00000, version 0x20, 24 pins
[     1.000003] cpu0 at mainbus0 apid 0
[     1.000003] cpu0: Intel(R) Core(TM) i7 CPU         860  @ 2.80GHz, id 0x106e5
[     1.000003] cpu0: package 0, core 0, smt 0
[     1.000003] cpu1 at mainbus0 apid 1
[     1.000003] cpu1: Intel(R) Core(TM) i7 CPU         860  @ 2.80GHz, id 0x106e5
[     1.000003] cpu1: package 0, core 1, smt 0
[     1.000003] acpi0 at mainbus0: Intel ACPICA 20190405
[     1.000003] acpi0: X/RSDT: OemId <VBOX  ,VBOXXSDT,00000001>, AslId <ASL ,00000061>
[     1.000003] acpi0: SCI interrupting at int 9
[     1.000003] acpi0: fixed power button present
[     1.000003] acpi0: fixed sleep button present
[     1.000003] timecounter: Timecounter "ACPI-Safe" frequency 3579545 Hz quality 900
[     1.051382] pckbc1 at acpi0 (PS2K, PNP0303) (kbd port): io 0x60,0x64 irq 1
[     1.051382] pckbc2 at acpi0 (PS2M, PNP0F03) (aux port): irq 12
[     1.051382] attimer1 at acpi0 (TIMR, PNP0100): io 0x40-0x43,0x50-0x53
[     1.051382] SRL0 (PNP0501) at acpi0 not configured
[     1.051382] acpivga0 at acpi0 (GFX0): ACPI Display Adapter
[     1.051382] acpiout0 at acpivga0 (VGA, 0x0100): ACPI Display Output Device
[     1.051382] acpivga0: connected output devices:
[     1.051382] acpivga0:   0x0100 (acpiout0): VGA Analog Monitor, index 0, port 0, head 0
[     1.051382] acpiacad0 at acpi0 (AC, ACPI0003-0): ACPI AC Adapter
[     1.051382] ACPI: Enabled 2 GPEs in block 00 to 07
[     1.051382] pckbd0 at pckbc1 (kbd slot)
[     1.051382] pckbc1: using irq 1 for kbd slot
[     1.051382] wskbd0 at pckbd0: console keyboard
[     1.051382] pms0 at pckbc1 (aux slot)
[     1.051382] pckbc1: using irq 12 for aux slot
[     1.051382] wsmouse0 at pms0 mux 0
[     1.051382] pci0 at mainbus0 bus 0: configuration mode 1
[     1.051382] pci0: This pci host supports neither MSI nor MSI-X.
[     1.051382] pci0: i/o space, memory space enabled, rd/line, rd/mult, wr/inv ok
[     1.051382] pchb0 at pci0 dev 0 function 0: vendor 8086 product 1237 (rev. 0x02)
[     1.051382] pcib0 at pci0 dev 1 function 0: vendor 8086 product 7000 (rev. 0x00)
[     1.051382] piixide0 at pci0 dev 1 function 1: Intel 82371AB IDE controller (PIIX4) (rev. 0x01)
[     1.051382] piixide0: bus-master DMA support present
[     1.051382] piixide0: primary channel configured to compatibility mode
[     1.051382] piixide0: primary channel interrupting at ioapic0 pin 14
[     1.051382] atabus0 at piixide0 channel 0
[     1.051382] piixide0: secondary channel configured to compatibility mode
[     1.051382] piixide0: secondary channel interrupting at ioapic0 pin 15
[     1.051382] atabus1 at piixide0 channel 1
[     1.051382] vga0 at pci0 dev 2 function 0: vendor 15ad product 0405 (rev. 0x00)
[     1.051382] wsdisplay0 at vga0 kbdmux 1: console (80x25, vt100 emulation), using wskbd0
[     1.051382] wsmux1: connecting to wsdisplay0
[     1.051382] drm at vga0 not configured
[     1.051382] wm0 at pci0 dev 3 function 0: Intel i82540EM 1000BASE-T Ethernet (rev. 0x02)
[     1.051382] wm0: interrupting at ioapic0 pin 19
[     1.051382] wm0: 32-bit 33MHz PCI bus
[     1.051382] wm0: 64 words (6 address bits) MicroWire EEPROM
[     1.051382] wm0: Ethernet address 08:00:27:c8:18:c6
[     1.051382] wm0: 0x402<LOCK_EECD,IOH_VALID>
[     1.051382] makphy0 at wm0 phy 1: Marvell 88E1011 Gigabit PHY, rev. 4
[     1.051382] makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
[     1.051382] vendor 80ee product cafe (miscellaneous system) at pci0 dev 4 function 0 not configured
[     1.051382] auich0 at pci0 dev 5 function 0: i82801AA (ICH) AC-97 Audio
[     1.051382] auich0: interrupting at ioapic0 pin 21
[     1.051382] auich0: ac97: SigmaTel STAC9700 codec; no 3D stereo
[     1.051382] auich0: ac97: ext id 0x809<AC97_23,VRM,VRA>
[     1.051382] ohci0 at pci0 dev 6 function 0: vendor 106b product 003f (rev. 0x00)
[     1.051382] ohci0: interrupting at ioapic0 pin 22
[     1.051382] ohci0: OHCI version 1.0
[     1.051382] usb0 at ohci0: USB revision 1.0
[     1.051382] piixpm0 at pci0 dev 7 function 0: vendor 8086 product 7113 (rev. 0x08)
[     1.051382] piixpm0: interrupting at ioapic0 pin 23
[     1.051382] iic0 at piixpm0 port 0: I2C bus
[     1.051382] ehci0 at pci0 dev 11 function 0: vendor 8086 product 265c (rev. 0x00)
[     1.051382] ehci0: interrupting at ioapic0 pin 19
[     1.051382] ehci0: EHCI version 1.0
[     1.051382] usb1 at ehci0: USB revision 2.0
[     1.051382] isa0 at pcib0
[     1.051382] com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
[     1.051382] pcppi0 at isa0 port 0x61
[     1.051382] spkr0 at pcppi0: PC Speaker
[     1.051382] wsbell at spkr0 not configured
[     1.051382] midi0 at pcppi0: PC speaker
[     1.051382] sysbeep0 at pcppi0
[     1.051382] attimer1: attached to pcppi0
[     1.051382] acpicpu0 at cpu0: ACPI CPU
[     1.051382] acpicpu0: C1: HLT, lat   0 us, pow     0 mW
[     1.051382] acpicpu1 at cpu1: ACPI CPU
[     1.051382] timecounter: Timecounter "clockinterrupt" frequency 100 Hz quality 0
[     1.335022] timecounter: Timecounter "TSC" frequency 2809031330 Hz quality 3000
[     1.335043] acpiacad0: AC adapter online.
[     1.915491] auich0: measured ac97 link rate at 39998 Hz, will use 48000 Hz
[     1.915491] audio0 at auich0: playback, capture, full duplex, independent
[     2.268357] audio0: slinear_le:16 2ch 48000Hz, blk 1920 bytes (10ms) for playback
[     2.268357] audio0: slinear_le:16 2ch 48000Hz, blk 1920 bytes (10ms) for recording
[     2.268357] spkr1 at audio0: PC Speaker (synthesized)
[     2.268357] wsbell at spkr1 not configured
[     2.286202] uhub0 at usb0: NetBSD (0000) OHCI root hub (0000), class 9/0, rev 1.00/1.00, addr 1
[     2.286202] uhub0: 12 ports with 12 removable, self powered
[     2.286202] uhub1 at usb1: NetBSD (0000) EHCI root hub (0000), class 9/0, rev 2.00/1.00, addr 1
[     2.286202] uhub1: 12 ports with 12 removable, self powered
[     2.286202] IPsec: Initialized Security Association Processing.
[     6.479970] wd0 at atabus0 drive 0
[     6.479970] wd0: <VBOX HARDDISK>
[     6.539749] wd0: drive supports 128-sector PIO transfers, LBA addressing
[     6.539749] wd0: 41150 MB, 83607 cyl, 16 head, 63 sec, 512 bytes/sect x 84276224 sectors
[     6.539749] wd0: GPT GUID: c6bbd56c-4899-4558-9d1d-6abca8e955c4
[     6.539749] dk0 at wd0: "2cb86f5b-9247-4145-b249-64fcf1460b87", 75887549 blocks at 64, type: ffs
[     6.550475] dk1 at wd0: "29f2bd47-2e4a-49a4-91b3-5a674ebaabeb", 8388575 blocks at 75887616, type: swap
[     6.550475] wd0: 32-bit data port
[     6.550475] wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 6 (Ultra/133)
[     6.550475] wd0(piixide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
[     6.550475] atapibus0 at atabus1: 2 targets
[     6.550475] cd0 at atapibus0 drive 0: <VBOX CD-ROM, VB2-01700376, 1.0> cdrom removable
[     6.559365] cd0: 32-bit data port
[     6.559365] cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 6 (Ultra/133)
[     6.559365] cd0(piixide0:1:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
[     6.559365] boot device: wd0
[     6.559365] root on dk0 dumps on dk1
[     6.569370] root file system type: ffs
[     6.569370] kern.module.path=/stand/amd64/9.2/modules
[    17.878763] wsdisplay0: screen 1 added (80x25, vt100 emulation)
[    17.878763] wsdisplay0: screen 2 added (80x25, vt100 emulation)
[    17.878763] wsdisplay0: screen 3 added (80x25, vt100 emulation)
[    17.888775] wsdisplay0: screen 4 added (80x25, vt100 emulation)

Lots and lots of stuff about the system here... highlights include:

  • System memory reporting the 4 GiB allocated to the VM
  • Lots of items with the name VBOX or VirtualBox
  • System CPU: Intel i7-860, reporting the 2 virtual cores allocated to the VM rather than all 8 (4 cores + hyperthreading)
  • IDE bus and disks
  • Network controller

With the device names.

sysctl

A tool to manipulate system information variables in the kernel. Here I've limited the output to only the hardware related items.

# sysctl -a | grep '^hw'
hw.machine = amd64
hw.model = Intel 686-class
hw.ncpu = 2
hw.byteorder = 1234
hw.physmem = -462848
hw.usermem = -16752640
hw.pagesize = 4096
hw.disknames = wd0 dk0 dk1 cd0
hw.machine_arch = x86_64
hw.alignbytes = 7
hw.cnmagic =
hw.physmem64 = 4294504448
hw.usermem64 = 4278214656
hw.iostatnames = wd0 dk0 dk1 cd0
hw.ncpuonline = 2
hw.acpi.sleep.beep = 0
hw.acpi.sleep.vbios = 2
hw.acpi.sleep.state = 0
hw.acpi.sleep.states = S0 S5
hw.acpi.root = 917504
hw.acpi.stat.gpe = 0
hw.acpi.stat.sci = 0
hw.acpi.stat.fixed = 0
hw.acpi.stat.method = 148
hw.acpi.acpivga0.bios_switch = 1
hw.acpi.cpu.dynamic = 1
hw.acpi.cpu.passive = 1
hw.ipw.accept_eula = 0
hw.iwi.accept_eula = 0
hw.uhso.autoswitch = 1
hw.fwohci.nocyclemaster = 0
hw.fwohci.phydma_enable = 1
hw.ieee1394if.try_bmr = 1
hw.ieee1394if.hold_count = 0
hw.ieee1394if.ieee1394_debug = 0
hw.fwmem.eui64_hi = 0
hw.fwmem.eui64_lo = 0
hw.fwmem.speed = 2
hw.fwmem.fwmem_debug = 0
hw.fwip.rx_queue_len = 256
hw.fwip.if_fwip_debug = 0
hw.sbp.auto_login = 1
hw.sbp.max_speed = -1
hw.sbp.exclusive_login = 1
hw.sbp.login_delay = 1000
hw.sbp.scan_delay = 500
hw.sbp.use_doorbell = 0
hw.sbp.tags = 0
hw.sbp.sbp_debug = 0
hw.ath.dwell = 200
hw.ath.calibrate = 30
hw.ath.outdoor = 1
hw.ath.countrycode = 0
hw.ath.regdomain = 0
hw.ath.debug = 0
hw.ath.rxbuf = 40
hw.ath.txbuf = 200
hw.ath.hal.dma_brt = 2
hw.ath.hal.sw_brt = 10
hw.ath.hal.swba_backoff = 0
hw.rtw.rfprog_fallback = 0
hw.rtw.host_rfio = 0
hw.wsevent.default_version = 1
hw.firmware.path = /libdata/firmware:/usr/libdata/firmware:/usr/pkg/libdata/firmware:/usr/pkg/libdata
hw.ubsec.maxbatch = 1
hw.ubsec.maxaggr = 1
hw.drm2.dp_aux_i2c_transfer_size = 16
hw.drm2.dp_aux_i2c_speed_khz = 10
hw.drm2.drm_debug = 0
hw.drm2.edid_fixup = 6
hw.drm2.drm_fbdev_emulation = 1
hw.drm2.drm_timestamp_monotonic = 1
hw.drm2.drm_timestamp_precision = 20
hw.drm2.drm_vblank_offdelay = 5000
hw.drm2.drm_kms_helper_poll = 1
hw.drm2.i915.guc_log_level = -1
hw.drm2.i915.enable_guc_submission = 0
hw.drm2.i915.edp_vswing = 0
hw.drm2.i915.nuclear_pageflip = 0
hw.drm2.i915.verbose_state_checks = 1
hw.drm2.i915.mmio_debug = 0
hw.drm2.i915.use_mmio_flip = 0
hw.drm2.i915.enable_cmd_parser = 1
hw.drm2.i915.disable_vtd_wa = 0
hw.drm2.i915.disable_display = 0
hw.drm2.i915.invert_brightness = 0
hw.drm2.i915.load_detect_test = 0
hw.drm2.i915.prefault_disable = 0
hw.drm2.i915.fastboot = 0
hw.drm2.i915.enable_ips = 1
hw.drm2.i915.disable_power_well = -1
hw.drm2.i915.preliminary_hw_support = 0
hw.drm2.i915.enable_psr = 0
hw.drm2.i915.enable_execlists = -1
hw.drm2.i915.enable_ppgtt = -1
hw.drm2.i915.enable_hangcheck = 1
hw.drm2.i915.reset = 1
hw.drm2.i915.vbt_sdvo_panel_type = -1
hw.drm2.i915.panel_use_ssc = -1
hw.drm2.i915.lvds_channel_mode = 0
hw.drm2.i915.enable_fbc = -1
hw.drm2.i915.enable_rc6 = -1
hw.drm2.i915.semaphores = -1
hw.drm2.i915.panel_ignore_lid = 1
hw.drm2.i915.modeset = -1
hw.drm2.radeon_mst = 0
hw.drm2.radeon_auxch = -1
hw.drm2.radeon_backlight = -1
hw.drm2.radeon_bapm = -1
hw.drm2.radeon_use_pflipirq = 2
hw.drm2.radeon_deep_color = 0
hw.drm2.radeon_vm_block_size = -1
hw.drm2.radeon_vm_size = 8
hw.drm2.radeon_hard_reset = 0
hw.drm2.radeon_runtime_pm = -1
hw.drm2.radeon_aspm = -1
hw.drm2.radeon_dpm = -1
hw.drm2.radeon_fastfb = 0
hw.drm2.radeon_lockup_timeout = 10000
hw.drm2.radeon_msi = -1
hw.drm2.radeon_pcie_gen2 = -1
hw.drm2.radeon_hw_i2c = 0
hw.drm2.radeon_disp_priority = 0
hw.drm2.radeon_audio = -1
hw.drm2.radeon_tv = 1
hw.drm2.radeon_connector_table = 0
hw.drm2.radeon_testing = 0
hw.drm2.radeon_benchmarking = 0
hw.drm2.radeon_gart_size = -1
hw.drm2.radeon_agpmode = 0
hw.drm2.radeon_vram_limit = 0
hw.drm2.radeon_r4xx_atom = 0
hw.drm2.radeon_dynclks = -1
hw.drm2.radeon_modeset = -1
hw.drm2.radeon_no_wb = 0
hw.drm2.nouveau_tv_norm =
hw.drm2.nouveau_vram_pushbuf = 0
hw.drm2.nouveau_duallink = 1
hw.drm2.nouveau_tv_disable = 0
hw.drm2.nouveau_runtime_pm = -1
hw.drm2.nouveau_modeset = -1
hw.drm2.nouveau_noaccel = 0
hw.drm2.nouveau_debug =
hw.drm2.nouveau_config =
hw.wm0.txrx_workqueue = 0
hw.auich0.ac97rate = 48000
hw.audio0.blk_ms = 10
hw.audio0.multiuser = 0
hw.wd0.use_ncq = 1
hw.wd0.use_ncq_prio = 0

Again lots of stuff, with a lot of overlap with what we saw in dmesg. As well as the hw category, the machdep section also has some hardware information:

# sysctl -a | grep '^machdep'
machdep.biosbasemem = 639
machdep.biosextmem = 3668992
machdep.booted_kernel = netbsd
machdep.diskinfo: 80:84276224(1024/255/63),2  dk0 dk1 wd0:80
machdep.fpu_present = 1
machdep.osfxsr = 1
machdep.sse = 1
machdep.sse2 = 1
machdep.fpu_save = 1
machdep.fpu_save_size = 512
machdep.xsave_features = 0
machdep.dmi.system-vendor = innotek GmbH
machdep.dmi.system-product = VirtualBox
machdep.dmi.system-version = 1.2
machdep.dmi.system-serial = 0
machdep.dmi.system-uuid = aa52f87b-c91e-447e-843c-acbd63d88eb8
machdep.dmi.bios-vendor = innotek GmbH
machdep.dmi.bios-version = VirtualBox
machdep.dmi.bios-date = 20061201
machdep.dmi.board-vendor = Oracle Corporation
machdep.dmi.board-product = VirtualBox
machdep.dmi.board-version = 1.2
machdep.dmi.board-serial = 0
machdep.dmi.chassis-vendor = Oracle Corporation
machdep.dmi.chassis-type = Oracle Corporation
machdep.bootmethod = BIOS
machdep.cpu_brand = Intel(R) Core(TM) i7 CPU         860  @ 2.80GHz
machdep.sparse_dump = 1
machdep.tsc_freq = 2809031330
machdep.pae = 1
machdep.tsc_user_enable = 1
machdep.hypervisor = generic
machdep.svs.enabled = 1
machdep.svs.pcid = 0
machdep.spectre_v1.mitigated = 0
machdep.spectre_v2.hwmitigated = 0
machdep.spectre_v2.swmitigated = 1
machdep.spectre_v2.method = [GCC retpoline]
machdep.spectre_v4.mitigated = 0
machdep.spectre_v4.method = (none)
machdep.mds.mitigated = 0
machdep.mds.method = (none)
machdep.taa.mitigated = 1
machdep.taa.method = [TAA_NO]
machdep.fpu_eager = 1
machdep.idle-mechanism = acpi

This include the processor and machine identification strings.

Devices

pcictl

Information about the PCI bus.

# pcictl pci0 list
000:00:0: Intel 82441FX (PMC) PCI and Memory Controller (host bridge, revision 0x02)
000:01:0: Intel 82371SB (PIIX3) PCI-ISA Bridge (ISA bridge)
000:01:1: Intel 82371AB (PIIX4) IDE Controller (IDE mass storage, interface 0x8a, revision 0x01)
000:02:0: VMware Virtual SVGA II (VGA display)
000:03:0: Intel i82540EM 1000baseT Ethernet (ethernet network, revision 0x02)
000:04:0: VirtualBox Guest Service (miscellaneous system)
000:05:0: Intel 82801AA AC-97 Audio Controller (audio multimedia, revision 0x01)
000:06:0: Apple Computer Intrepid USB Controller (USB serial bus, OHCI)
000:07:0: Intel 82371AB (PIIX4) Power Management Controller (miscellaneous bridge, revision 0x08)
000:11:0: Intel 82801FB/FR USB EHCI Controller (USB serial bus, EHCI)

Most devices are on the PCI bus, but VirtualBox is masking the real hardware here. Note that the graphics card is an emulated device using a specification from VMware. Also kind of interesting that VirtualBox uses an Apple USB controller.

Storage

The storage devices are listed in the hw.disknames variable from sysctl:

# sysctl hw.disknames
hw.disknames = wd0 dk0 dk1 cd0

To find out a bit more about these we need to turn to other commands...

atactl

The wd0 disk is an ATA device (see NetBSD man wd), so the atactl command (NetBSD man atactl) can be used to find out more:

# atactl wd0 identify
Model: VBOX HARDDISK, Rev: 1.0, Serial #: VB36acbb5b-9e97ffdc
Device type: ATA, fixed
Capacity 43 Gbytes, 84276224 sectors, 512 bytes/sector
Cylinders: 16383, heads: 16, sec/track: 63
Device capabilities:
        DMA
        LBA
        IORDY operation
Device supports following standards:
ATA-1 ATA-2 ATA-3 ATA-4 ATA-5 ATA-6
Command set support:
        Look-ahead (enabled)
        Write cache (enabled)
        Power Management feature set (enabled)
        FLUSH CACHE command (enabled)

So lots of information about this disk. What about the CD-ROM device cd0 (see NetBSD man cd):

# atactl cd0 identify
Model: , Rev: , Serial #:
Device type: ATA, removable
Capacity 0 bytes, 0 sectors, 512 bytes/sector
Cylinders: 0, heads: 0, sec/track: 0
Device capabilities:

Hmmm that looks a little odd, for one thing were is the device name?

scsictl

When looking at SCSI disks (see NetBSD man sd) use the scsictl command (NetBSD man scsictl) in place of atactl. Since the CD-ROM device also acts as a SCSI device, let's see what their view looks like:

# scsictl cd0 identify
/dev/rcd0: scsibus0 target 0 lun 0 <VBOX, CD-ROM, 1.0>

Ah that's where the device name is, and this shows the identification information for a SCSI drive.

dkctl

The dk disks (see NetBSD man dk) represent the partitions of the disk, known as disk wedges, so the dkctl command (NetBSD man dkctl) can be used to find out a bit more:

# dkctl dk0 getwedgeinfo
dk0 at wd0: 2cb86f5b-9247-4145-b249-64fcf1460b87
dk0: 75887549 blocks at 64, type: ffs

The identifier here is used in /etc/fstab to mount the wedge,

usbdevs

To get information about any USB devices connected to the system use usbdevs (NetBSD man usbdevs):

# usbdevs -dv
Controller /dev/usb0:
addr 1: full speed, self powered, config 1, OHCI root hub(0x0000), NetBSD(0x0000), rev 1.00(0x0100)
  uhub0
 port 1 powered
 port 2 powered
 port 3 powered
 port 4 powered
 port 5 powered
 port 6 powered
 port 7 powered
 port 8 powered
 port 9 powered
 port 10 powered
 port 11 powered
 port 12 powered
Controller /dev/usb1:
addr 1: high speed, self powered, config 1, EHCI root hub(0x0000), NetBSD(0x0000), rev 1.00(0x0100)
  uhub1
 port 1 powered
 port 2 powered
 port 3 powered
 port 4 powered
 port 5 powered
 port 6 powered
 port 7 powered
 port 8 powered
 port 9 powered
 port 10 powered
 port 11 powered
 port 12 powered

At the moment the system only has the default USB root hubs, so not a lot of information here... even with the -d and -v options to get information about the driver attached to the device and a some more details of the device.

Software Packages

pkg_info

To get a list of the installed pkgsrc packages use pkg_info (NetBSD man pkg_info):

# pkg_info -a
pkg_install-20210308 Package management and administration tools for pkgsrc
pkgin-20.12.1       Apt / yum like tool for managing pkgsrc binary packages

This is a freshly installed system, so not much here yet.

pkgin

The binary package manager pkgin has its own inventory:

# pkgin list
at-spi2-atk-2.38.0   Assistive Technology Service Provider Interface A11y Toolkit
at-spi2-core-2.38.0  Assistive Technology Service Provider Interface Core
atk-2.36.0           Set of interfaces for accessibility
avahi-0.8nb4         Facilitate service discovery on a local network
bash-5.1.4           The GNU Bourne Again Shell
cairo-1.16.0nb2      Vector graphics library with cross-device output support
cairo-gobject-1.16.0nb5 Vector graphics library with cross-device output support
cmocka-1.1.5         Unit testing framework for C supporting mock objects
dbus-1.12.20         Message bus system
dbus-glib-0.110nb1   GLib bindings for the D-BUS message bus system
desktop-file-utils-0.26 Utilities to manage desktop entries
enca-1.15            Extremely Naive Charset Analyser
ffmpeg4-4.3.2nb1     Decoding, encoding and streaming software (v4.x)
firefox-86.0.1       Web browser with support for extensions (version 86)
fribidi-1.0.10       Free Implementation of the Unicode Bidirectional Algorithm
gdbm-1.19            The GNU database manager
gdk-pixbuf2-2.40.0nb1 Library for image loading and manipulation
gettext-lib-0.21     Internationalized Message Handling Library (libintl)
giflib-5.2.1nb4      GIF image format library
glib2-2.66.8nb1      Some useful routines for C programming (glib2)
gmp-6.2.1            Library for arbitrary precision arithmetic
gnutls-3.7.1         Transport Layer Security library
gobject-introspection-1.68.0 GObject Introspection
graphite2-1.3.14     Cross-platform rendering for complex writing systems
gtk2+-2.24.33        GIMP Toolkit v2 - libraries for building X11 user interfaces
gtk3+-3.24.27        GIMP Toolkit v3 - libraries for building X11 user interfaces
harfbuzz-2.7.4       OpenType text shaping engine
hicolor-icon-theme-0.17nb1 Standard icon theme called hicolor
icu-68.2             Robust and full-featured Unicode services
jansson-2.13.1       C library for encoding, decoding and manipulating JSON data
jbigkit-2.1nb1       JBIG-KIT lossless image compression library
jpeg-9d              IJG's jpeg compression utilities
lame-3.100nb2        Fast, high quality MP3 encoder
ldb-2.2.1            LDAP-like embedded database
libIDL-0.8.14nb5     CORBA Interface Definition Language parser
libaom-1.0.0nb3      Library for using AV1, video coding format
libass-0.15.0        Portable subtitle renderer for the ASS/SSA subtitle format
libbluray-1.2.1nb1   Library for Blu-Ray Discs playback for media players
libcfg+-0.7.0        Command line and configuration file parsing library
libcups-2.3.3op2     Common UNIX Printing System library
libdaemon-0.14nb2    C library that eases the writing of UNIX daemons
libffi-3.3nb4        Foreign function interface
libgcrypt-1.9.2      GNU cryptographic library
libgpg-error-1.41    Definitions of common error values for all GnuPG components
libiconv-1.14nb3     Character set conversion library
libogg-1.3.4nb1      Ogg project codecs library
libopus-1.3.1        Totally open, royalty-free, highly versatile audio codec library
libpaper-1.1.28      Paper size handling library
libtasn1-4.16.0      ASN.1 structure parser library
libtheora-1.1.1nb2   Video codec for Ogg multimedia streaming
libunistring-0.9.10  Unicode string library
libuuid-2.32.1       Generate unique identifiers for objects
libv4l-1.20.0        Video4Linux userspace library
libva-2.6.1          Video Acceleration API
libvorbis-1.3.7      Library for the Ogg Vorbis audio encoding format
libvpx-1.9.0nb1      On2 VP8 library from Google
libwebp-1.2.0        WebP image format library and tools
libxkbcommon-1.1.0   Library to handle keyboard descriptions
libxml2-2.9.10nb3    XML parser library from the GNOME project
libxslt-1.1.34nb4    XSLT parser library from the GNOME project
lmdb-0.9.29          Symas Lightning Memory-Mapped Database
lzo-2.10             Portable lossless data compression library
mozilla-rootcerts-1.0.20201204 Root CA certificates from the Mozilla Project
nettle-3.7.2         Cryptographic library
nspr-4.29            Platform-neutral API for system level and libc like functions
nss-3.62             Libraries to support development of security-enabled applications
p11-kit-0.23.22nb1   PKCS#11 module manager
p5-Parse-Yapp-1.21nb3 Perl5 LALR parser
pango-1.48.3         Library for layout and rendering of text
pcre-8.44            Perl Compatible Regular Expressions library
perl-5.32.1          Practical Extraction and Report Language
png-1.6.37           Library for manipulating PNG images
popt-1.18            Command line option parsing library
py38-cElementTree-3.8.8 C implementation of Python ElementTree API
py38-cryptodome-3.10.1 Cryptographic and hash functions for Python
py38-dns-1.16.0nb1   Python DNS toolkit
py38-ecdsa-0.16.1    Easy-to-use implementation of ECDSA cryptography
py38-expat-3.8.8     Python interface to expat
py38-idna-2.10       Python module for Internationalized Domain Names in Applications (IDNA)
py38-iso8601-0.1.14  Simple Python module to parse ISO 8601 dates
py38-setuptools-51.3.3 New Python packaging system
py38-six-1.15.0      Python 2 and 3 compatibility utilities
python38-3.8.8       Interpreted, interactive, object-oriented programming language
readline-8.1         GNU library that can recall and edit previous input
samba-4.13.7         SMB/CIFS protocol server suite
shared-mime-info-1.10nb3 Core database of common types
speex-1.2.0          Open-source, patent-free voice codec
talloc-2.3.2         Hierarchical pool based memory allocator with destructors
tcsh-6.22.02nb1      Extended C-shell with many useful features
tdb-1.4.3nb1         Small database system which uses files to store data
tevent-0.10.2nb1     Event system based on the talloc
tiff-4.2.0           Library and tools for reading and writing TIFF data files
wayland-1.18.0nb2    Display server protocol - development libraries
wayland-protocols-1.20 Additional wayland functionality
x264-devel-20191217nb1 GPL licensed H.264 encoder
x265-3.4             High Efficiency Video Coding (HEVC)
xmlcatmgr-2.2nb1     XML and SGML catalog manager
xvidcore-1.3.7       ISO MPEG-4 compliant video codec

A lot of packages here.

sys_info

For the system installed component packages the sys_info command (NetBSD man sys_info) can be used:

# sys_info
awk-20121220
bind-9.14.7
bozohttpd-20210227
bzip2-1.0.8
calendar-20160601
dhcpcd-8.1.9
dtc-1.4.4
ftpd-20180428
g++-7.5.0
gcc-7.5.0
grep-2.5.1anb1
gzip-20170803
libc-12.213
libcurses-8.2
libdrm-3.4
libm-0.12
libresolv-3.0
libssh-34.0
libstdc++-9.0
libterminfo-1.0
libutil-7.24
libX11-7.0
libXaw7-10.0
libXfont-3.0
libXft-3.0
libXrandr-3.2
libXt-7.0
NetBSD-9.2
netpgp-3.99.17
netpgpverify-20170201
ntp-4.2.8pl11
openssh-8.0
opensshd-8.0
openssl-1.1.1k
libpcap-1.9.0-PRE-GIT
pkg_install-20201218
sh-20181212-20210512131555Z
sqlite3-3.26.0
sys_info-20170928
tcpdump-4.9.2
tcsh-6.22.02
tzdata-2021a
unbound-1.9.6
userland-NetBSD-9.2/amd64
wpa_supplicant-2.7
xz-5.2.4
yacc-1.9

So we now know what versions the system components are.


No comments: