From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,BAYES_00 shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id DDBD01F466; Mon, 27 Jan 2020 09:46:30 +0000 (UTC) Date: Mon, 27 Jan 2020 09:46:30 +0000 From: Eric Wong To: meta@public-inbox.org Subject: Xapian::DB_NO_SYNC option? Message-ID: <20200127094630.GA16809@dcvr> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline List-Id: Since 1.3.2, Xapian has supports a DB_NO_SYNC flag to disable fsync(). It's available from the new SWIG "Xapian" Perl bindings, but not the old Search::Xapian XS binding, though it's easy enough to define ourselves (0x4) when encountering Xapian 1.3.2+. So I'm wondering if it'd be useful for anybody to provide a switch or command-line option to disable fsync? SQLite also has a PRAGMA to control fsync usage. Personally, I use the "eatmydata" LD_PRELOAD wrapper a lot and have always found public-inbox-index and one-off importer scripts completely unusable without eatmydata. Everything we store in Xapian, (and even SQLite nowadays) is regeneratable, anyways, so no risk of data loss in the worst case.