diff --git a/dm/checker/checker.go b/dm/checker/checker.go index 530e1c5fdf3..55de71b22ed 100644 --- a/dm/checker/checker.go +++ b/dm/checker/checker.go @@ -438,9 +438,6 @@ func (c *Checker) Init(ctx context.Context) (err error) { } // Adjust will raise error when this field is empty, so we set any non empty value here. lCfg.Mydumper.SourceDir = "noop://" - if lightningCheckGroupOnlyTableEmpty(c.checkingItems) { - lCfg.TiDB.PdAddr = "noop:2379" - } err = lCfg.Adjust(ctx) if err != nil { return err @@ -550,16 +547,6 @@ func (c *Checker) Init(ctx context.Context) (err error) { return nil } -func lightningCheckGroupOnlyTableEmpty(checkingItems map[string]string) bool { - for _, item := range config.LightningPrechecks { - if _, ok := checkingItems[item]; ok && item != config.LightningTableEmptyChecking { - return false - } - } - _, ok := checkingItems[config.LightningTableEmptyChecking] - return ok -} - func (c *Checker) fetchSourceTargetDB( ctx context.Context, instance *mysqlInstance,