Skip to content

Commit

Permalink
PSMDB-810 log more info during hot backup
Browse files Browse the repository at this point in the history
  • Loading branch information
igorsol committed Feb 16, 2021
1 parent bec98c3 commit 3dd2a6e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2064,11 +2064,20 @@ Status WiredTigerKVEngine::hotBackup(OperationContext* opCtx, const std::string&
std::set<fs::path> existDirs{destPath};

// Do copy files
int fcCtr = 0;
for (auto&& file : filesList) {
fs::path srcFile{std::get<0>(file)};
fs::path destFile{std::get<1>(file)};
auto fsize{std::get<2>(file)};

log() << "Beginning copy of {}/{} files in backup snapshot: {}, {} bytes"_format(
++fcCtr, filesList.size(), srcFile.string(), fsize);
if (!fs::exists(srcFile)) {
log() << "Source file does not exist: {}"_format(srcFile.string());
} else {
log() << "Source file size is: {} bytes"_format(fs::file_size(srcFile));
}

try {
// Try creating destination directories if needed.
const fs::path destDir(destFile.parent_path());
Expand Down

0 comments on commit 3dd2a6e

Please sign in to comment.