  We show that every bounded domain in a metric measure space can be
approximated in measure from inside by closed $BV$-extension sets. The
extension sets are obtained by minimizing the sum of the perimeter and the
measure of the difference between the domain and the set. By earlier results,
in PI-spaces the minimizers have open representatives with locally quasiminimal
surface. We give an example in a PI-space showing that the open representative
of the minimizer need not be a $BV$-extension domain nor locally John.
