snap-pac/faq.html
2021-05-09 20:52:34 +00:00

159 lines
No EOL
5.5 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" />
<title>FAQ &#8212; snap-pac documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" />
<link rel="stylesheet" type="text/css" href="_static/alabaster.css" />
<script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script>
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/doctools.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="prev" title="Troubleshooting" href="troubleshooting.html" />
<link rel="stylesheet" href="_static/custom.css" type="text/css" />
<meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />
</head><body>
<div class="document">
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<h1 class="logo"><a href="index.html">snap-pac</a></h1>
<p class="blurb">pacman hooks that use snapper to create pre/post btrfs snapshots</p>
<p>
<iframe src="https://ghbtns.com/github-btn.html?user=wesbarnett&repo=snap-pac&type=star&count=true&size=large&v=2"
allowtransparency="true" frameborder="0" scrolling="0" width="200px" height="35px"></iframe>
</p>
<h3>Navigation</h3>
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="installation.html">Installation</a></li>
<li class="toctree-l1"><a class="reference internal" href="configuration.html">Configuration</a></li>
<li class="toctree-l1"><a class="reference internal" href="configuration.html#environment-variables">Environment Variables</a></li>
<li class="toctree-l1"><a class="reference internal" href="examples.html">Example</a></li>
<li class="toctree-l1"><a class="reference internal" href="troubleshooting.html">Troubleshooting</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="#">FAQ</a></li>
</ul>
<div class="relations">
<h3>Related Topics</h3>
<ul>
<li><a href="index.html">Documentation overview</a><ul>
<li>Previous: <a href="troubleshooting.html" title="previous chapter">Troubleshooting</a></li>
</ul></li>
</ul>
</div>
<div id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" />
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>$('#searchbox').show(0);</script>
</div>
</div>
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<section id="faq">
<h1>FAQ<a class="headerlink" href="#faq" title="Permalink to this headline"></a></h1>
<div class="toctree-wrapper compound">
</div>
<p><strong>Does snap-pac backup non-btrfs /boot partitions?</strong></p>
<p>No, but you can add a hook that does it for you. It would be something like the following:</p>
<div class="highlight-none notranslate"><div class="highlight"><pre><span></span>[Trigger]
Operation = Upgrade
Operation = Install
Operation = Remove
Type = Package
Target = linux
[Action]
Description = Backing up /boot...
When = PreTransaction
Exec = /usr/bin/rsync -avzq --delete /boot /.bootbackup
</pre></div>
</div>
<p>Note that you will probably want to name the file with a numbered prefix less than
<code class="docutils literal notranslate"><span class="pre">05</span></code> so that it is run before the snap-pac pre snapshot takes place. That will ensure
that the snapshot taken will have the boot partition back-up corresponding with the
state of the system. For example, you could name it <code class="docutils literal notranslate"><span class="pre">04-backupboot.hook</span></code>.</p>
<p><strong>How do I link old kernel modules automatically when the kernel is upgraded?</strong></p>
<p>This behavior is no longer a part of this package. Use a pacman hook like the following:</p>
<div class="highlight-none notranslate"><div class="highlight"><pre><span></span>[Trigger]
Operation = Upgrade
Operation = Install
Operation = Remove
Type = Package
Target = linux
[Action]
Description = Symlinking old kernel modules...
When = PostTransaction
Exec = /usr/bin/bash -c &quot;find /usr/lib/modules -xtype l -delete; ln -sv /.snapshots/$(snapper -c root list | awk &#39;END{print $1}&#39;)/snapshot/usr/lib/modules/$(uname -r) /usr/lib/modules/&quot;
</pre></div>
</div>
</section>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer">
&copy;2021, Wes Barnett, PhD.
|
Powered by <a href="http://sphinx-doc.org/">Sphinx 4.0.0</a>
&amp; <a href="https://github.com/bitprophet/alabaster">Alabaster 0.7.12</a>
|
<a href="_sources/faq.rst.txt"
rel="nofollow">Page source</a>
</div>
<a href="https://github.com/wesbarnett/snap-pac" class="github">
<img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png" alt="Fork me on GitHub" class="github"/>
</a>
</body>
</html>