{"record":{"id":"21fe3cf310144809","repo":"nats-io/nats-server","slug":"unknown-signal-q-21fe3c","errorCode":null,"errorMessage":"unknown signal %q","messagePattern":"unknown signal %q","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"server/signal_windows.go","lineNumber":89,"sourceCode":"\t\tcmd svc.Cmd\n\t\tto  svc.State\n\t)\n\n\tswitch command {\n\tcase CommandStop, CommandQuit:\n\t\tcmd = svc.Stop\n\t\tto = svc.Stopped\n\tcase CommandReopen:\n\t\tcmd = reopenLogCmd\n\t\tto = svc.Running\n\tcase CommandReload:\n\t\tcmd = svc.ParamChange\n\t\tto = svc.Running\n\tcase commandLDMode:\n\t\tcmd = ldmCmd\n\t\tto = svc.Running\n\tdefault:\n\t\treturn fmt.Errorf(\"unknown signal %q\", command)\n\t}\n\n\tstatus, err := s.Control(cmd)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"could not send control=%d: %v\", cmd, err)\n\t}\n\n\ttimeout := time.Now().Add(10 * time.Second)\n\tfor status.State != to {\n\t\tif timeout.Before(time.Now()) {\n\t\t\treturn fmt.Errorf(\"timeout waiting for service to go to state=%d\", to)\n\t\t}\n\t\ttime.Sleep(300 * time.Millisecond)\n\t\tstatus, err = s.Query()\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"could not retrieve service status: %v\", err)\n\t\t}\n\t}","sourceCodeStart":71,"sourceCodeEnd":107,"githubUrl":"https://github.com/nats-io/nats-server/blob/3a66a489d262bf89b71a71c955c94920394532f3/server/signal_windows.go#L71-L107","documentation":"Windows ProcessSignal switch over the command (stop/quit, reopen, reload, ldm) hit the default case: the Command value is not one of the recognized Windows service control commands, so no svc.Cmd could be selected. Mirrors the non-Windows 'unknown signal' error; caused by an invalid --signal command.","triggerScenarios":"Thrown at server/signal_windows.go:89 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use a supported command: stop, quit, reopen, reload, ldm","Check the command spelling in the --signal argument"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3a66a489d262bf89b71a71c955c94920394532f3","analyzedAt":"2026-09-02T04:41:54.247Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}