From 48eef9e6eb78532d6708a1dd0724ee7c5b0d4368 Mon Sep 17 00:00:00 2001 From: Andrew Lytvynov Date: Wed, 13 Mar 2024 15:55:24 -0700 Subject: [PATCH] clientupdate: do not allow msiexec to reboot the OS (#11409) According to https://learn.microsoft.com/en-us/windows/win32/msi/standard-installer-command-line-options#promptrestart, `/promptrestart` is ignored with `/quiet` is set, so msiexec.exe can sometimes silently trigger a reboot. The best we can do to reduce unexpected disruption is to just prevent restarts, until the user chooses to do it. Restarts aren't normally needed for Tailscale updates, but there seem to be some situations where it's triggered. Updates #18254 Signed-off-by: Andrew Lytvynov --- clientupdate/clientupdate.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clientupdate/clientupdate.go b/clientupdate/clientupdate.go index 565544e7f..2a08d6638 100644 --- a/clientupdate/clientupdate.go +++ b/clientupdate/clientupdate.go @@ -836,7 +836,7 @@ func (up *Updater) switchOutputToFile() (io.Closer, error) { func (up *Updater) installMSI(msi string) error { var err error for tries := 0; tries < 2; tries++ { - cmd := exec.Command("msiexec.exe", "/i", filepath.Base(msi), "/quiet", "/promptrestart", "/qn") + cmd := exec.Command("msiexec.exe", "/i", filepath.Base(msi), "/quiet", "/norestart", "/qn") cmd.Dir = filepath.Dir(msi) cmd.Stdout = up.Stdout cmd.Stderr = up.Stderr