search for: commit_transact

Displaying 20 results from an estimated 24 matches for "commit_transact".

2005 Sep 09
7
[PATCH 0/6] jbd cleanup
The following 6 patches cleanup the jbd code and kill about 200 lines. First of 4 patches can apply to 2.6.13-git8 and 2.6.13-mm2. The rest of them can apply to 2.6.13-mm2. fs/jbd/checkpoint.c | 179 +++++++++++-------------------------------- fs/jbd/commit.c | 101 ++++++++++-------------- fs/jbd/journal.c | 11 +- fs/jbd/revoke.c | 158
2010 Aug 04
6
[PATCH -v2 0/3] jbd2 scalability patches
This version fixes three bugs in the 2nd patch of this series that caused kernel BUG when the system was under race. We weren't accounting with t_oustanding_credits correctly, and there were race conditions caused by the fact the I had overlooked the fact that __jbd2_log_wait_for_space() and jbd2_get_transaction() requires j_state_lock to be write locked. Theodore Ts'o (3): jbd2: Use
2008 Aug 21
2
How to speed up indexing ?
...many thanks if anyone replies. I did a release build from xapian-core-1.0.7 with VS2008 by using Charlie Hull's makefiles. I'm trying to test-index my dataset -- some 200'000 docs, each document being (on average) 50 bytes long and having 6 words. I tried (a) not to use stemmer, (b) commit_transaction() on every 50/100/etc. docs, (c) not to use transactions at all -- but in all scenarios indexing goes at ~10 doc/sec or 500 bytes per second. This should probably be ~400 times faster, I'm clearly doing something wrong. Can anyone give me a hint or direct me to a source on the net to do som...
2004 May 05
1
buffered tables, sessions, and transactions
...flag * if "in_transaction" is set, we ignore explicit flushes and don't autoflush * cancel_transaction closes and reopens the Btree table (or calls a new method of Btree which has this effect but without all the file descriptor and memory allocation releasing and reobtaining) * commit_transaction flushes any pending changes and clears the "in_transaction" flag That's a lot of flushing though - the currently specified API makes transaction inherently inefficient I think. If we *just* want to provide a way to specify an atomic grouping, we could modify the API to allow s...
2006 Jul 07
0
acts_as_ferret transactions
...end true end + + def at_start_transaction(name = nil) + @defer_for_transaction = true + end + + def at_abort_transaction(name = nil) + @defer_for_transaction = false + @ferret_reindex = false + end + + def at_commit_transaction(name = nil) + @defer_for_transaction = false + ferret_create + @ferret_reindex = false + end # convert instance to ferret document def to_doc @@ -786,4 +806,28 @@ end end +module Transaction + module Simple + alias :start_transaction_...
2008 Mar 19
5
object_transactions plugin w/2.x disables AR session store
All, Win XP Rails 2.0.2 object_transactions plugin (http://code.bitsweat.net/svn/object_transactions/) transaction-simple gem 1.4 (required by object_transactions plugin) AR SQL Server Adapter 1.0 SQL Server 2000 Using the object_transactions plugin with Rails 2.0.2 (and I assume based on what I''m seeing that this goes for Rails 2.x) disables the ability to save to an ActiveRecord based
2013 Jun 19
2
Compact databases and removing stale records at the same time
...atches.begin() ; i != matches.end() ; ++i) { Xapian::Document doc = i.get_document(); std::string cyrusid = doc.get_value(SLOT_CYRUSID); if (cb(cyrusid.c_str(), rock)) { destdb->add_document(doc); count++; /* commit occasionally */ if (count % 1024 == 0) { destdb->commit_transaction(); destdb->begin_transaction(); } } } /* commit all the remaining transactions */ destdb->commit_transaction(); delete destdb; delete srcdb; } catch (const Xapian::Error &err) { syslog(LOG_ERR, "IOERROR: Xapian: caught exception: %s: %s", er...
2012 Aug 24
4
[PATCH] Btrfs: pass lockdep rwsem metadata to async commit transaction
...ntainer_of(work, struct btrfs_async_commit, work.work); + /* + * We''ve got freeze protection passed with the transaction. + * Tell lockdep about it. + */ + rwsem_acquire_read( + &ac->root->fs_info->sb->s_writers.lock_map[SB_FREEZE_FS-1], + 0, 1, _THIS_IP_); + btrfs_commit_transaction(ac->newtrans, ac->root); kfree(ac); } @@ -1257,6 +1265,14 @@ int btrfs_commit_transaction_async(struct btrfs_trans_handle *trans, atomic_inc(&cur_trans->use_count); btrfs_end_transaction(trans, root); + + /* + * Tell lockdep we''ve released the freeze rwsem, since...
2009 Nov 10
12
[RFC] big fat transaction ioctl
Hi all, This is an alternative approach to atomic user transactions for btrfs. The old start/end ioctls suffer from some basic limitations, namely - We can''t properly reserve space ahead of time to avoid ENOSPC part way through the transaction, and - The process may die (seg fault, SIGKILL) part way through the transaction. Currently when that happens the partial transaction will
2002 May 31
2
PATCH for filesys corruption in ext3 with data=journal
...63,13 @@ * there's no point in keeping a checkpoint record for * it. */ bh = jh2bh(jh); - if (buffer_jdirty(bh)) { + if (buffer_jdirty(bh) && !__buffer_state(bh, Freed)) { JBUFFER_TRACE(jh, "add to new checkpointing trans"); __journal_insert_checkpoint(jh, commit_transaction); JBUFFER_TRACE(jh, "refile for checkpoint writeback"); __journal_refile_buffer(jh); } else { + clear_bit(BH_Freed, &bh->b_state); J_ASSERT_BH(bh, !buffer_dirty(bh)); J_ASSERT_JH(jh, jh->b_next_transaction == NULL); __journal_unfile_buffer(jh); --- ./...
2012 Nov 01
0
[PATCH 1/5] Btrfs: fix joining the same transaction handler more than 2 times
If we flush inodes with pending delalloc in a transaction, we may join the same transaction handler more than 2 times. The reason is: Task use_count of trans handle commit_transaction 1 |-> btrfs_start_delalloc_inodes 1 |-> run_delalloc_nocow 1 |-> join_transaction 2 |-> cow_file_range 2 |-> join_transaction 3 In fact, cow_file_range needn''t join the transaction again because the caller have joined the transaction, so we fix this...
2011 Jan 26
0
[PATCH 2/3] jbd2: Remove barrier feature conditional flag (or: always issue flushes)
...mp; JBD2_BARRIER && - !JBD2_HAS_INCOMPAT_FEATURE(journal, + if (!JBD2_HAS_INCOMPAT_FEATURE(journal, JBD2_FEATURE_INCOMPAT_ASYNC_COMMIT)) ret = submit_bh(WRITE_SYNC_PLUG | WRITE_FLUSH_FUA, bh); else @@ -686,8 +685,7 @@ start_journal_io: * the commit record */ if (commit_transaction->t_flushed_data_blocks && - (journal->j_fs_dev != journal->j_dev) && - (journal->j_flags & JBD2_BARRIER)) + (journal->j_fs_dev != journal->j_dev)) blkdev_issue_flush(journal->j_fs_dev, GFP_KERNEL, NULL); /* Done it all: now write the co...
2023 Mar 27
1
manual flushing thresholds for deletes?
On Mon, Mar 27, 2023 at 11:22:09AM +0000, Eric Wong wrote: > Olly Betts <olly at survex.com> wrote: > > 10 seems too long. You want the mean word length weighted by frequency > > of occurrence. For English that's typically around 5 characters, which > > is 5 bytes. If we go for +1 that's: > > Actually, 10 may be too short in my case since there's a
2018 Mar 30
2
sorting large msets
...t;add_boolean_term('T' . 'mail'); $xdb->add_document($doc); $doc = Search::Xapian::Document->new; $doc->add_value(0, $num); $doc->set_data("$i $j"); $doc->add_boolean_term('T' . 'ghost'); $xdb->add_document($doc); } $xdb->commit_transaction; } my $enquire = Search::Xapian::Enquire->new($xdb); my $mail_query = Search::Xapian::Query->new('T' . 'mail'); $enquire->set_query($mail_query); $enquire->set_sort_by_value_then_relevance(0, 1); my $offset = 0; my $limit = 200; my $t0 = clock_gettime(CLOCK_MONOTONIC)...
2023 May 03
1
manual flushing thresholds for deletes?
...s me 6.00067, so rounding to 6 seems fine either way. My Perl deletion code is something like: my $EST_LEN = 6; ... for my $docid (@docids) { $TXN_BYTES -= $xdb->get_doclength($docid) * $EST_LEN; $xdb->delete_document($docid); if ($TXN_BYTES < 0) { # flush within txn $xdb->commit_transaction; $TXN_BYTES = 8000000; $xdb->begin_transaction; } } > > (that awk bit should be overflow-free) <snip> > Or use a language which supports arbitrary precision > numbers. Actually, I just used gawk instead of mawk for GMP support :>
2002 Jul 18
0
Fwd: oops with 2.4.18 and preempt patch, on SMP + ext3 machine
...18:29:33 localhost kernel: APIC error on CPU1: 02(08) Jul 4 18:29:37 localhost kernel: APIC error on CPU1: 08(08) Jul 4 18:32:52 localhost kernel: APIC error on CPU1: 08(08) Jul 4 18:34:31 localhost kernel: APIC error on CPU1: 08(02) Jul 4 20:53:12 localhost kernel: Assertion failure in journal_commit_transaction() at commit.c:79: "commit_transaction->t_state == T_RUNNING" Jul 4 20:53:12 localhost kernel: invalid operand: 0000 Jul 4 20:53:12 localhost kernel: CPU: 0 Jul 4 20:53:12 localhost kernel: EIP: 0010:[journal_commit_transaction+234/3970] Tainted: P Jul 4 20:53:12 localh...
2005 Jan 04
0
[PATCH] BUG on error handlings in Ext3 under I/O failure condition
...2.6.10-bk6/fs/jbd/commit.c 2004-12-25 06:35:27.000000000 +0900 +++ linux-2.6.10-bk6_fix/fs/jbd/commit.c 2005-01-04 19:58:48.000000000 +0900 @@ -341,6 +341,9 @@ } spin_unlock(&journal->j_list_lock); + if (err) + __journal_abort_hard(journal); + journal_write_revoke_records(journal, commit_transaction); jbd_debug(3, "JBD: commit phase 2\n"); diff -Nru linux-2.6.10-bk6/include/linux/fs.h linux-2.6.10-bk6_fix/include/linux/fs.h --- linux-2.6.10-bk6/include/linux/fs.h 2004-12-25 06:34:27.000000000 +0900 +++ linux-2.6.10-bk6_fix/include/linux/fs.h 2005-01-04 19:58:48.000000000 +090...
2005 Aug 04
0
[PATCH 6/11] Xenstore watch rework
...f (!copy_dir(dir, transaction->divert)) { + send_error(conn, errno); + return; + } talloc_steal(conn, transaction); conn->transaction = transaction; - return send_ack(transaction->conn, XS_TRANSACTION_START); + send_ack(transaction->conn, XS_TRANSACTION_START); } static bool commit_transaction(struct transaction *trans) { char *tmp, *dir; - struct changed_node *i; /* Move: orig -> .old, repl -> orig. Cleanup deletes .old. */ dir = node_dir_outside_transaction(trans->node); @@ -294,39 +300,44 @@ trans->divert, dir); trans->divert = tmp; - - /* Fire off...
2010 Mar 22
5
[PATCH 0/5] asynchronous commit, snapshot ponies
...milar to what I was doing before (using the ''flushoncommit'' mount option and tiggering a sync_fs to flush data). The only difference is the old snapshots stick around for a bit longer before I delete them and the references get dropped. The first patch introduces a generic btrfs_commit_transaction_async() helper, which starts btrfs_commit_transaction asynchronously and returns either when the commit starts (blocked=1) or when it has done it''s dirty work (blocked=0). The second patch adds ioctls that let you start and wait for an asynchronous commit. The third introduces a SNAP_...
2011 Dec 09
10
[PATCH 0/3] Btrfs: add IO error device stats
The goal is to detect when drives start to get an increased error rate, when drives should be replaced soon. Therefore statistic counters are added that count IO errors (read, write and flush). Additionally, the software detected errors like checksum errors and corrupted blocks are counted. An ioctl interface is added to get the device statistic counters. A second ioctl is added to atomically get