PUBLIC-INBOX-XCPDB(1)
π public-inbox-xcpdb π
okay bestie, you found the page for public-inbox-xcpdb, straight out of the public-inbox user manual β¨ it's the little tool that upgrades your Xapian DB formats, and honestly? it's giving "rare special occasion" energy. let's get into it π«Ά
πΈ NAME πΈ
public-inbox-xcpdb β upgrade Xapian DB formats π
β¨ SYNOPSIS β¨
public-inbox-xcpdb [OPTIONS] INBOX_DIR
public-inbox-xcpdb [OPTIONS] --all
π¦ DESCRIPTION π¦
so, public-inbox-xcpdb is lowkey the cousin of copydatabase(1) β it's here to upgrade you to the latest database format that Xapian supports (think "glass" or "honey" β¨) β but with a glow up: it's designed to tolerate and accept parallel Xapian database modifications coming from public-inbox-watch(1), public-inbox-mda(1), public-inbox-learn(1), and public-inbox-index(1). like, it doesn't freak out when other processes are touching the DB at the same time. main character behavior honestly π
ngl though, this command is rarely used β because Xapian DB formats rarely change. it's the "emergency cute outfit in the back of the closet" of public-inbox tools π
π OPTIONS π
--allβ copies every inbox configured in~/.public-inbox/config. it's the alternative to listing individual inbox directories on the command-line, so you don't have to type them all out like a menace π-c,--compactβ on top of doing the copy operation, it runsxapian-compact(1)on each Xapian shard after copying but before finalizing it. and here's the tea: compared to the cost of copying a Xapian database, compacting one only takes around 5% of the time required to copy. so cheap, so worth it π
compared to public-inbox-compact(1), this option is preferable for gigantic inboxes β because the coarse-grained lock currently required for public-inbox-compact(1) can make the compaction take hours at-a-time π yeah. hours. no cap.
-R N,--reshard=Nβ reshard the Xapian database on a v2 inbox to"N"shards. sincexapian-compact(1)is not suitable for merging, you can rely on this switch to reshard the existing Xapian database(s) to any positive value of"N"π§
this is useful in case the Xapian DB was created with too few or too many shards given the capabilities of the current hardware β aka your hardware changed and the old shard count is not it anymore π
--blocksize,--no-full,--fullerβ these options get passed directly toxapian-compact(1)when used with--compact. handoff, no middleman β¨--no-fsyncβ disablesfsync(2)andfdatasync(2). check--no-fsyncinpublic-inbox-index(1)for the caveats, bestie, there are caveats β οΈ
available in public-inbox 1.6.0+.
--sequential-shardβ copy each shard sequentially, ignoring--jobs. this also affects indexing done at the end of a run. one at a time, patient queen πΈ--batch-size=BYTES,--max-size=BYTESβ seepublic-inbox-index(1)for a description of these options. π
these indexing options affect indexing at the end of a run. public-inbox-xcpdb may run in parallel with public-inbox-index(1), and public-inbox-xcpdb needs to reindex changes made to the old Xapian DBs by public-inbox-index(1) while it was running. so yeah, the parallel stuff is handled, but it's handled deliberately π«Ά
π ENVIRONMENT π
PI_CONFIGβ the default config file, normally~/.public-inbox/config. seepublic-inbox-config(5)XAPIAN_FLUSH_THRESHOLDβ the number of documents to update before committing changes to disk. this environment is handled directly by Xapian, so refer to the Xapian API documentation for more details π
Default: 10000
π UPGRADING π
this tool is intended for admins upgrading Xapian search databases used by public-inbox β NOT users upgrading public-inbox itself. two different quests, bestie, don't mix them up π
in particular, it DOES NOT upgrade the schema used by the PSGI search interface (see public-inbox-index(1)). that's a different job entirely, ok? π
β οΈ LIMITATIONS β οΈ
do NOT usepublic-inbox-purge(1)orpublic-inbox-edit(1)while this is running β old (purged or edited data) may show up. like, the ghost of data past. we do not want that π
normal invocations of public-inbox-index(1) can safely run while this is running, too. however, reindexing via the --reindex in public-inbox-index(1) switch will be a waste of computing resources β it's just burning CPU for no reason, and that's not slay, that's just wasteful π
π CONTACT π
feedback welcome via plain-text mail to <mailto:meta@public-inbox.org> π«Ά
the mail archives are hosted at:
<https://public-inbox.org/meta/><http://4uok3hntl7oi7b4uf4rtfwefqeexfzil2w6kgk2jn5z2f764irre7byd.onion/meta/>
π COPYRIGHT π
Copyright 2019-2021 all contributors <mailto:meta@public-inbox.org>
License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
π₯ SEE ALSO π₯
copydatabase(1), xapian-compact(1), public-inbox-index(1)
and that's the whole page, bestie!! β¨ this one came from public-inbox.git, dated 1993-10-02, and it lives in the manual as PUBLIC-INBOX-XCPDB(1) β so if you ever need to reshard or upgrade your Xapian DB, you know exactly where to look π mwah, go forth and copy responsibly π¦
π¦ where this page comes from
- fedora 43: public-inbox 2.0.0~20230714git590023f-6.fc43 Β· AGPL-3.0-or-later
- fedora 44: public-inbox 2.0.0~20230714git590023f-6.fc43 Β· AGPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms