summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2010-12-09 16:36:29 -0500
committerChris Mason <chris.mason@oracle.com>2011-10-25 09:18:31 -0400
commitb4382217f18a27be16f9a960ac3b1327c87297e7 (patch)
tree0827570ecbaebaf234026bcec1e6885d0b373d95 /Makefile
parentfe7caa7c4a3bb738d3eb3ac6edaa24c8b38ec95f (diff)
Btrfs-progs: add a btrfs-select-super command to overwrite the super
Btrfs stores multiple copies of the superblock, and for common power-failure crashes where barriers were not in use, one of the super copies is often valid while the first copy is not. This adds a btrfs-select-super -s N /dev/xxx command, which can overwrite all the super blocks with a copy that you have already determined is valid with btrfsck -s Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 6e6f6c68..d65f6a22 100644
--- a/Makefile
+++ b/Makefile
@@ -62,6 +62,9 @@ btrfs-debug-tree: $(objects) debug-tree.o
btrfs-zero-log: $(objects) btrfs-zero-log.o
gcc $(CFLAGS) -o btrfs-zero-log $(objects) btrfs-zero-log.o $(LDFLAGS) $(LIBS)
+btrfs-select-super: $(objects) btrfs-select-super.o
+ gcc $(CFLAGS) -o btrfs-select-super $(objects) btrfs-select-super.o $(LDFLAGS) $(LIBS)
+
btrfstune: $(objects) btrfstune.o
gcc $(CFLAGS) -o btrfstune $(objects) btrfstune.o $(LDFLAGS) $(LIBS)