diff --git a/pkg/compute/models/secgroups.go b/pkg/compute/models/secgroups.go index a229ba4532..76326a4843 100644 --- a/pkg/compute/models/secgroups.go +++ b/pkg/compute/models/secgroups.go @@ -584,6 +584,9 @@ func totalSecurityGroupCount(scope rbacscope.TRbacScope, ownerId mcclient.IIdent } func (self *SSecurityGroup) PerformSyncstatus(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input *api.SecurityGroupSyncstatusInput) (jsonutils.JSONObject, error) { + if !self.IsManaged() { + return nil, self.SetStatus(ctx, userCred, api.SECGROUP_STATUS_READY, "") + } return nil, self.StartSecurityGroupSyncTask(ctx, userCred, "") }