diff --git a/pkg/hostman/host_services.go b/pkg/hostman/host_services.go index fe23bc98c0f..df6f50c1cec 100644 --- a/pkg/hostman/host_services.go +++ b/pkg/hostman/host_services.go @@ -17,6 +17,7 @@ package hostman import ( execlient "yunion.io/x/executor/client" "yunion.io/x/log" + "yunion.io/x/pkg/util/signalutils" "yunion.io/x/onecloud/pkg/appsrv" app_common "yunion.io/x/onecloud/pkg/cloudcommon/app" @@ -156,6 +157,10 @@ func (host *SHostService) initHandlers(app *appsrv.Application) { } func StartService() { + // register dump stack signal handler at first + signalutils.SetDumpStackSignal() + signalutils.StartTrap() + var srv = &SHostService{} srv.SServiceBase = &service.SServiceBase{ Service: srv,