norgbackup/docs/content/reference/norgbackupweb/usage/inspect-your-backups/index.html

199 lines
10 KiB
HTML
Raw Normal View History

<!DOCTYPE HTML>
<html>
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="https://norgbackup.net/main.css">
<link rel="stylesheet" href="https://norgbackup.net/norg.css">
<link rel="icon" href="https://norgbackup.net/favicon.png">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
<title> Norg | Inspect your Backups </title>
</head>
<body>
<main>
<nav>
<a href="https:&#x2F;&#x2F;norgbackup.net">
<img src="https://norgbackup.net/norg-logo.png" alt="logo"/>
</a>
<a href="javascript:void(0);" onclick="burger()" id="mobile" class="ms-Icon--GlobalNavButton"></a>
<div id="trees">
<input class="tree-toggle" type="checkbox" id="introduction"
/>
<label class="tree-toggle-label"
for="introduction">Introduction</label>
<ul class="subtree">
<li >
<a href="https://norgbackup.net/introduction/about-norg/">About Norg</a>
</li>
<li >
<a href="https://norgbackup.net/introduction/system-compatibility/">System Compatibility</a>
</li>
</ul>
<input class="tree-toggle" type="checkbox" id="reference-guides"
/>
<label class="tree-toggle-label"
for="reference-guides">Reference Guides</label>
<ul class="subtree">
<li >
<a href="https://norgbackup.net/reference/example-configuration/">Example Configuration</a>
</li>
<li >
<a href="https://norgbackup.net/reference/command-line/">Command Line Reference</a>
</li>
</ul>
<input class="tree-toggle" type="checkbox" id="usage"
checked/>
<label class="tree-toggle-label"
for="usage">Usage</label>
<ul class="subtree">
<li >
<a href="https://norgbackup.net/usage/setup/">Setting up Norg</a>
</li>
<li >
<a href="https://norgbackup.net/usage/configuration/">Configuring Norg</a>
</li>
<li >
<a href="https://norgbackup.net/usage/redundancy/">Backup Redundancy</a>
</li>
<li >
<a href="https://norgbackup.net/usage/initialize/">Initialize Repositories</a>
</li>
<li >
<a href="https://norgbackup.net/usage/create-a-backup/">Create a Backup</a>
</li>
<li class="active">
<a href="https://norgbackup.net/usage/inspect-your-backups/">Inspect your Backups</a>
</li>
<li >
<a href="https://norgbackup.net/usage/monitoring-backup-jobs/">Knowing your Backup has Run</a>
</li>
<li >
<a href="https://norgbackup.net/usage/extract-a-backup/">Extract&#x2F;Restore a Backup</a>
</li>
<li >
<a href="https://norgbackup.net/usage/before-and-after-actions/">Before and After Actions</a>
</li>
<li >
<a href="https://norgbackup.net/usage/both-borg-and-restic/">Using both Borg and Restic</a>
</li>
</ul>
<input class="tree-toggle" type="checkbox" id="download"
/>
<label class="tree-toggle-label"
for="download">Download</label>
<ul class="subtree">
<li >
<a href="https://norgbackup.net/download/download-norg/">Download Norg</a>
</li>
</ul>
<input class="tree-toggle" type="checkbox" id="contributing-to-norg"
/>
<label class="tree-toggle-label"
for="contributing-to-norg">Contributing to Norg</label>
<ul class="subtree">
<li >
<a href="https://norgbackup.net/contributing/contributing/">Contributing</a>
</li>
</ul>
</div>
</nav>
<article>
<div id="on_right">
<span id="search-ico" class="ms-Icon--Search"></span>
</div>
<div class="search-container">
<input id="search" type="search" placeholder="Search as you type...">
<div class="search-results">
<div class="search-results__header"></div>
<ul class="search-results__items"></ul>
</div>
</div>
<div id="wrap">
<h1>Inspect your Backups</h1>
<p>The output of a backup will be shown in your terminal if running manually.
You could output this into a log file if you wish, like so:</p>
<pre data-lang="sh" style="background-color:#eff1f5;color:#4f5b66;" class="language-sh "><code class="language-sh" data-lang="sh"><span style="color:#bf616a;">norg -c</span><span> myconfig.toml</span><span style="color:#bf616a;"> --stats </span><span>&gt;&gt; mybackup.log
</span></code></pre>
<p>This is great for letting you know some basic information about your backup.</p>
<h2 id="list-existing-backups">List Existing Backups</h2>
<p>Norg provides command line parameters to allow you to list your backups for all
or specific repositories.</p>
<pre data-lang="sh" style="background-color:#eff1f5;color:#4f5b66;" class="language-sh "><code class="language-sh" data-lang="sh"><span style="color:#a7adba;"># List all archives/snapshots on all repositories
</span><span style="color:#bf616a;">norg -c</span><span> myconfig.toml list
</span><span>
</span><span style="color:#a7adba;"># List all archives/snapshots on a specific repository
</span><span style="color:#bf616a;">norg -c</span><span> myconfig.toml list</span><span style="color:#bf616a;"> -r</span><span> MyRepository
</span></code></pre>
<p>When specifying the <code>-r</code> or <code>--repository</code> parameter, you can specify either
the <code>label</code> or <code>path</code> for the repository defined in the configuration file.</p>
<p>You can also specify further <a href="/usage/both-borg-and-restic#further-args">Borg or Restic command line options</a>
(like <code>--last 3</code> to show the last 3 archives in a Borg repository). It is advised to
<em>always</em> use the <code>-r</code> parameter in these cases as specifc flags for Borg do not
work with Restic and vice-versa.</p>
<h2 id="mount-a-backup">Mount a Backup</h2>
<p>Both Borg and Restic provide the ability to mount an archive (Borg) or repository (Restic) so you can inspect and recover individual files this way. Norg provides the ability to do this via the below command:</p>
<pre data-lang="sh" style="background-color:#eff1f5;color:#4f5b66;" class="language-sh "><code class="language-sh" data-lang="sh"><span style="color:#a7adba;"># For Borg repositories, where we mount an Archive
</span><span style="color:#bf616a;">norg -c</span><span> myconfig.toml mount</span><span style="color:#bf616a;"> -r</span><span> MyBorgRepository</span><span style="color:#bf616a;"> -a</span><span> hostname-date-of-backup /path/to/mount/point
</span><span>
</span><span style="color:#a7adba;"># For Restic repositories, where we mount the entire repository
</span><span style="color:#bf616a;">norg -c</span><span> myconfig.toml mount</span><span style="color:#bf616a;"> -r</span><span> MyResticRepository /path/to/mount/point
</span></code></pre>
<p>It is sensible to always provide the <code>-r</code> parameter as you will not be able to mount multiple archive/repositories to the same location.</p>
<h3 id="unmount-a-backup">Unmount a Backup</h3>
<p>Unmounting a backup is different for both Borg and Restic.<br />
Borg has a <code>umount</code> command which can be run via norg as follows:</p>
<pre data-lang="sh" style="background-color:#eff1f5;color:#4f5b66;" class="language-sh "><code class="language-sh" data-lang="sh"><span style="color:#bf616a;">norg -c</span><span> myconfig.toml umount /path/to/mount/point
</span></code></pre>
<p>Restic however, remains running after a <code>mount</code> command has been issues, and awaits
<code>Ctrl+C</code> keyboard entry to unmount. In short, there is no <code>umount</code> command for Restic.</p>
</div>
<hr />
<h2>Help us improve this documentation.</h2>
<p>If you find an error, or think something could be explained better,
<a href="https://codeberg.org/pswilde/norgbackup/issues">raise an issue</a> to
send your feedback.</p>
<footer>
<p>Norg Backup Utility &copy; 2024 Paul Wilde<br/>
Site created using <a href="https://getzola.org">Zola</a> using the
<a href="https://github.com/codeandmedia/zola_easydocs_theme">easydocs</a> theme.</p>
</footer>
</article>
</main>
<script type="text/javascript" src="https://norgbackup.net/elasticlunr.min.js" defer></script>
<script type="text/javascript" src="https://norgbackup.net/search_index.en.js" defer></script>
<script type="text/javascript" src="https://norgbackup.net/js.js" defer></script>
</body>
</html>