Commit Graph

262 Commits

Author SHA1 Message Date
Chris Mason
712c1dea5e Rev the disk format for compression and root pointer generation fields
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2008-10-29 14:09:40 -04:00
Yan Zheng
38702ea7c6 Add root tree pointer transaction ids
This patch adds transaction IDs to root tree pointers.
Transaction IDs in tree pointers are compared with the
generation numbers in block headers when reading root
blocks of trees. This can detect some types of IO errors.

Signed-off-by: Yan Zheng <zheng.yan@oracle.com>
2008-10-29 14:07:47 -04:00
Chris Mason
c830821ddf Add disk format elements for compression
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2008-10-29 14:37:41 -04:00
Chris Mason
b431f25ec7 Rev the disk format for the new back reference format
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2008-10-09 13:40:23 -04:00
Yan Zheng
9559e0b09e Count space allocated to file in bytes
This patch updates btrfs-progs for counting space
allocated to file in bytes.

Signed-off-by: Yan Zheng <zheng.yan@oracle.com>
2008-10-09 11:55:26 -04:00
Yan Zheng
5986faaf47 Remove offset field from struct btrfs_extent_ref
The offset field in struct btrfs_extent_ref records the position
inside file that file extent is referenced by. In the new back
reference system, tree leaves holding reference to file extent
are recorded explicitly. We can quickly scan these tree leaves, so the
offset field is not required.

This patch also makes the back reference system check the objectid
when extents are being deleted

Signed-off-by: Yan Zheng <zheng.yan@oracle.com>
2008-10-09 11:55:30 -04:00
Zheng Yan
09ab0365ff update mkfs.btrfs for the new space balancing code
The new space balancing code needs a subvol to store the
temporary inode for data extent relocation.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
2008-09-26 10:26:53 -04:00
Zheng Yan
428b7fa630 Full back reference support
This patch makes the back reference system to explicit record the
location of parent node for all types of extents. The location of
parent node is placed into the offset field of backref key. Every
time a tree block is balanced, the back references for the affected
lower level extents are updated.
2008-09-23 12:29:10 -04:00
Chris Mason
cea88ec1d7 Disk format changes required for write ahead tree log 2008-09-05 16:15:58 -04:00
Chris Mason
2f2f9ef77a Rev the disk format 2008-08-21 15:49:34 -04:00
David Woodhouse
a2ec48bb6b Switch btrfs_name_hash() to crc32c
Date: Tue, 19 Aug 2008 19:21:22 +0100
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-20 20:11:23 -04:00
David Woodhouse
be8c87e176 Use git for version number too
Date: Tue, 19 Aug 2008 18:57:17 +0100
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-20 20:11:22 -04:00
Eric Sandeen
e7e7bb1727 fix btrfs-progs version script
btrfs-progs-0.16.tar.bz2 seems to be distributed w/o an .hg,
which make the version.sh script go bonk.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
2008-08-06 12:17:01 -04:00
Chris Mason
3c6e5b165d Added tag v0.16 for changeset 2b26e4f8c71e 2008-08-04 15:46:36 -04:00
Chris Mason
324f6ca04f Update version.sh to v0.16 2008-08-04 15:46:31 -04:00
Radoslaw Szkodzinski
33d7977a95 btrfs-convert: Iterate correctly using libext2fs functions
This patch corrects open-coded inode_map iteration, which happens to be
illegal in new libext2fs due to inode_map being private, causing warning,
which becomes a compile error.
2008-07-30 17:02:57 -04:00
email.ahmedkamal@googlemail.com
e9fa78e2ec Cleanup btrfsctl help message
Many options were not mentioned in the usage message, fix that and
cleaning up the brackets

Signed-Off-By: Ahmed Kamal <email.ahmedkamal@googlemail.com>
2008-07-30 13:29:28 -04:00
Ahmed
26641e8d32 Fix: btrfsctl arguments handling
btrfsctl -A
in the current -unstable branch, does not result in the error message
designated for it, namely "-A requires an arg\n"
2008-07-30 09:17:21 -04:00
Yan
48c2290d4c btrfs-convert new dir index support
This patch updates btrfs-convert for the new dir index format.
2008-07-30 09:16:42 -04:00
Josef Bacik
0045e0dd70 btrfs-progs: add orphan support to print-tree
This adds orphan support to print-tree so when debug_tree hits an orphan item it
will print out "orphan item" under it so you know what it is
2008-07-30 09:15:02 -04:00
Chris Mason
e74b89d675 Rev the disk format 2008-07-24 13:52:04 -04:00
Josef Bacik
059c20b384 btrfs-progs new dir index support 2008-07-24 12:13:32 -04:00
Chris Mason
9864c90760 Print the version string in a few programs 2008-07-24 12:13:30 -04:00
Chris Mason
cbfe93f68f Add version strings 2008-07-23 12:12:13 -04:00
Chris Mason
a9629e709a Add .hgignore file to ignore verison.h 2008-07-23 11:36:13 -04:00
Chris Mason
969c548acb Add sync and transaction ioctl defs
btrfsctl -c forces a single FS sync

The transaction ioctls are unsafe for general use because they can lead
to deadlocks if the application is not very careful.  But, ceph is
experimenting with btrfs as a backing store, and these ioctls are required
for testing.
2008-06-10 10:09:18 -04:00
Linda Knippers
d8d4df9474 btrfsctl: print usage when called with bad args 2008-06-09 22:23:13 -04:00
Chris Mason
e19357b687 Added tag v0.15 for changeset e6571e2ce0c8 2008-05-29 10:32:09 -04:00
Chris Mason
351d17fca2 Verify parent generation number on btree reads 2008-05-13 13:48:58 -04:00
Chris Mason
9a9bdd6047 Pass down the expected generation number when reading tree blocks 2008-05-12 13:51:24 -04:00
Chris Mason
d160150c8b Fix the pretty print code for num_bytes == 0 2008-05-12 13:01:57 -04:00
Chris Mason
a62332eeb2 Add a readonly flag open_ctree to force RO opens 2008-05-05 09:45:26 -04:00
Chris Mason
aaf38b3ebd bcp updates for single file copies 2008-05-02 16:12:02 -04:00
Chris Mason
a94b1455aa Add bcp to test the clone file ioctl 2008-05-02 15:08:08 -04:00
Chris Mason
9a73efb7d1 Fix compiler warning in volumes.c 2008-05-02 15:05:11 -04:00
Chris Mason
bacbad41a0 Add the clone ioctl number 2008-05-02 11:05:21 -04:00
Chris Mason
f86e8be3f8 Fix uninitialized variables, and use -O so gcc starts checking for them
Gcc only sends warnings for uninitialized variables when you compile with -O,
and there were a couple of bugs sprinkled in the code.  The biggest was the
alloc_start variable for mkfs, which can cause strange things to happen.

(thanks to Gabor Micsko for helping to find this)
2008-05-01 10:22:47 -04:00
Chris Mason
9a34051c51 Added tag v0.14 for changeset 969099968b60 2008-04-29 14:29:18 -04:00
Zhu
fb0a5d3766 Fix btrfs-convert's large file support.
This patch add ext2_inode.i_size_high into account when calculating regular
file's size in btrfs-convert,  which makes it deal with large files bigger than
4GB properly.
2008-04-28 16:45:11 -04:00
Chris Mason
b327761ead Add btrfs-vol command to balance, add and (eventually) remove devices 2008-04-28 16:44:22 -04:00
Chris Mason
083faf794f Add mkfs.btrfs -A offset to control allocation start on devices
This is a utility option for the resizer, it makes sure to allocate
at offset bytes in the disk or higher.  It ensures the resizer will have
something to move when testing it.
2008-04-25 16:55:21 -04:00
Yan Zheng
4415143185 Speed improvement and bug fixes for ext3 converter
This patch improves converter's allocator and fixes a bug in data relocation
function. The new allocator caches free blocks as Btrfs's default allocator.
In testing here, the user CPU time reduced to half of the original when
checksum and small file packing was disabled. This patch also enlarges the
size of block groups created by the converter.
2008-04-24 14:57:50 -04:00
Chris Mason
309ce6768b Fix balance_level to free the middle block if there is room in the left one
balance level starts by trying to empty the middle block, and then
pushes from the right to the middle.  This might empty the right block
and leave a small number of pointers in the middle.
2008-04-24 14:46:15 -04:00
Chris Mason
8057a6c3e7 Don't empty the middle buffer in push_nodes_for_insert 2008-04-24 10:54:32 -04:00
Chris Mason
d8ecd9205a Keep more pointers free in the nodes for double splits 2008-04-24 10:18:25 -04:00
Chris Mason
3ce9579503 Drop quick-test from the list of programs built by default 2008-04-22 14:30:52 -04:00
Chris Mason
8bfbb6b6f8 Update the Ext3 converter
The main changes in this patch are adding chunk handing and data relocation
ability. In the last step of conversion, the converter relocates data in system
chunk and move chunk tree into system chunk. In the rollback process, the
converter remove chunk tree from system chunk and copy data back.

Regards
YZ
---
2008-04-22 14:06:56 -04:00
Chris Mason
358564890a Add a command to show all of the btrfs filesystems on the box (btrfs-show) 2008-04-22 14:06:31 -04:00
Chris Mason
b569dafbf2 Fix chunk allocation when some devices don't have enough room for the stripe 2008-04-18 11:56:21 -04:00
Chris Mason
0e08036ee4 Add checks to avoid adding the same device twice during mkfs 2008-04-18 10:45:17 -04:00