parseBaseCname() may be error. eg:www.ucloud.cn.ucloud.com.cn func parseBaseCname(url string) (string, error) { extract, err := tldextract.New(TldCachePath, false) if err != nil { return "", err } res := extract.Extract(url) rootDomain := res.Root + "." + res.Tld return rootDomain, nil }