FREE_LIMIT="0.2"
+# Whether snapshot numbers should be all-time unique. If set to yes, snapshot
+# numbers are not reused even after snapshots are deleted.
+UNIQUE_NUMBERS="yes"
+
+
# users and groups allowed to work with config
ALLOW_USERS=""
ALLOW_GROUPS=""
<refentry id='snapper-configs5'>
<refentryinfo>
- <date>2022-07-12</date>
+ <date>2026-06-16</date>
</refentryinfo>
<refmeta>
<refentrytitle>snapper-configs</refentrytitle>
<manvolnum>5</manvolnum>
- <refmiscinfo class='date'>2022-07-12</refmiscinfo>
+ <refmiscinfo class='date'>2026-06-16</refmiscinfo>
<refmiscinfo class='version'>@VERSION@</refmiscinfo>
<refmiscinfo class='manual'>Filesystem Snapshot Management</refmiscinfo>
</refmeta>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><option>UNIQUE_NUMBERS=<replaceable>boolean</replaceable></option></term>
+ <listitem>
+ <para>Whether snapshot numbers should be all-time unique. If set to
+ yes, snapshot numbers are not reused even after snapshots are deleted.</para>
+ <para>Default value is "yes".</para>
+ <para>New in version 0.13.2.</para>
+ </listitem>
+ </varlistentry>
+
<varlistentry>
<term><option>ALLOW_USERS=<replaceable>users</replaceable></option></term>
<listitem>
As a consequence there can temporarily be empty directories in the
infos directories.
+
+This behavior can be disabled by setting UNIQUE_NUMBERS="no" in the
+configuration.
+-------------------------------------------------------------------
+Tue Jun 16 10:40:03 CEST 2026 - Arvin Schnell <aschnell@suse.com>
+
+- allow to disable all-time unique snapshot numbers (see
+ bsc#1268225)
+
-------------------------------------------------------------------
Fri Jun 12 09:47:19 CEST 2026 - Arvin Schnell <aschnell@suse.com>
if (info_dir.unlink("info.xml") < 0)
y2err("unlink 'info.xml' failed errno: " << errno << " (" << stringerror(errno) << ")");
- // We want all-time unique snapshot numbers. So keep directory of snapshot with
+ // If want all-time unique snapshot numbers keep directory of snapshot with
// highest number.
- if (snapshot->num != entries.rbegin()->num)
+ bool unique_numbers = true;
+ snapper->getConfigInfo().get_value("UNIQUE_NUMBERS", unique_numbers);
+
+ if (!unique_numbers || snapshot->num != entries.rbegin()->num)
{
SDir infos_dir = snapper->openInfosDir();
if (infos_dir.rmdir(decString(snapshot->getNum())) < 0)