Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

Windows MSI: Change/Modify cannot add the optional Netdata Driver (netdata_driver.sys) to an existing install

Ouverte
#23,286 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 1 jour

Personne n'a encore pris cette issue.

Évaluation

Difficulté
3/5
Temps estimé
1-2 jours
Accessibilité débutants
72/100
Type d'issue
Bug
Clarté
Clairement spécifiée
Activité
Calme
Stack technique
xml
Domaine
build-system

Piste de recherche

Commencez dans packaging/windows/netdata.wxs.in, en vous concentrant sur MaintenanceTypeDlg, VerifyReadyDlg, NDConfigDialog et NDComponentSelection autour des lignes 376–406 et 511. Générez le Windows MSI et testez le flux Change avec une installation existante. C’est terminé lorsque le flux atteint la case à cocher du pilote et peut ajouter netdata_driver.sys et netdata_driver.inf sans désinstaller.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

Description

The Windows MSI installer's "Change" (Modify) maintenance flow cannot be used to add the optional Netdata Driver (netdata_driver.sys, required for cpu.temperature/GetHardwareInfo) to an already-installed Netdata. The only way to add the driver today is to fully uninstall and reinstall Netdata.

Root cause

In packaging/windows/netdata.wxs.in:

  • The driver files are gated by a file-level condition: Condition="NDDRVINST=1" on netdata_driver.sys/netdata_driver.inf (lines 282, 284), inside FeatureGroup Id="NetdataDriver" referenced from the single top-level Feature Id="Main".
  • The checkbox that sets NDDRVINST (NDDriverCBX, line 511) lives on the NDComponentSelection dialog, which is reachable only via ViewLicenseDlg → NDComponentSelection, itself reachable only via WelcomeDlg.Next, gated by Condition="NOT Installed" (line 376) — i.e. only on a fresh install.
  • During a maintenance run, MaintenanceTypeDlg's ChangeButton is published straight to VerifyReadyDlg (line 403), bypassing the feature dialogs entirely. Compare with upstream WiX's stock WixUI_FeatureTree.wxs, where ChangeButton routes directly to CustomizeDlg (the feature-tree/customize screen).
  • The one theoretical way back into the feature dialogs — VerifyReadyDlg's Back button routing to NDConfigDialog when WixUI_InstallMode = "Change" (line 399, inherited verbatim from the upstream pattern) — never fires, because nothing in this custom UI fragment ever sets the WixUI_InstallMode property (it appears exactly once in the whole file, only as a read in that one Condition).

Net effect: clicking Change in the maintenance dialog goes straight to a "ready to modify" confirmation screen with no way to reach the checkbox, and Back from there only loops to the maintenance type selector.

Impact

A user who installed Netdata without the driver, and later wants CPU temperature monitoring, cannot enable it via the installer's Modify/Change option — they must uninstall and reinstall Netdata from scratch. This is non-obvious and easy to miss (no error is shown; the checkbox visually just isn't there in Change mode).

Suggested fix (one of)

  1. Set WixUI_InstallMode to "Change" on MaintenanceTypeDlg's ChangeButton (mirroring the upstream WixUI_FeatureTree.wxs pattern), so the existing VerifyReadyDlg.Back → NDConfigDialog condition (line 399) actually fires.
  2. Or route ChangeButton directly to NDConfigDialog/NDComponentSelection, matching how upstream routes ChangeButton straight to CustomizeDlg.

Possible command-line workaround (untested, worth verifying)

msiexec /i netdata-x64.msi NDDRVINST=1 REINSTALL=ALL REINSTALLMODE=amus (or similar REINSTALLMODE flags) may force Windows Installer to re-evaluate the file-level condition and add the driver files to an existing install without a full uninstall, since Windows Installer conditions are re-evaluated on CostFinalize using the properties passed on that invocation. This wasn't tested against this specific package (no Windows box available) — worth confirming on real hardware before recommending it to users. Note that ADDLOCAL=NetdataDriver alone will not work: NetdataDriver is a WiX FeatureGroup, not a real MSI Feature — the compiled MSI's Feature table only contains Main.

Evidence

  • packaging/windows/netdata.wxs.in:181-186 — DRIVERDIR/INFDIR resolve to %SystemRoot%\system32\drivers\ and %SystemRoot%\INF\, matching the path src/collectors/windows.plugin/GetHardwareInfo.c:9 checks.
  • packaging/windows/netdata.wxs.in:281-286 — driver file conditions.
  • packaging/windows/netdata.wxs.in:376-406 — dialog navigation chain.
  • packaging/windows/netdata.wxs.in:511 — NDDriverCBX checkbox on NDComponentSelection.
  • src/collectors/windows.plugin/GetHardwareInfo.c:88-231 — the actual SCM CreateServiceA/StartServiceA calls run inside the collector at Agent startup, not as an MSI custom action, so file presence on disk is the only thing the installer needs to get right.

Surfaced while reviewing/fixing PR #23200.

Langage dominant
Go
Étoiles
81k
Forks
6.7k
Merge moyen
19 h 32 min
PR mergées (30 j)
340

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de netdata/netdata

Toutes les issues de netdata/netdata

Issues similaires

Plus d'issues Go

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.