diff --git a/v4/export/dump.go b/v4/export/dump.go index f953ad96..c746ea9b 100755 --- a/v4/export/dump.go +++ b/v4/export/dump.go @@ -116,6 +116,7 @@ func (d *Dumper) Dump() (dumpErr error) { if err != nil { return err } + defer metaConn.Close() m.recordStartTime(time.Now()) // for consistency lock, we can write snapshot info after all tables are locked. // the binlog pos may changed because there is still possible write between we lock tables and write master status.