Skip to content

Commit

Permalink
VERSION 1.4
Browse files Browse the repository at this point in the history
  • Loading branch information
maharmstone committed Aug 31, 2019
1 parent 2b5de83 commit ecd8013
Show file tree
Hide file tree
Showing 6 changed files with 83 additions and 55 deletions.
34 changes: 31 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
WinBtrfs v1.3
WinBtrfs v1.4
-------------

WinBtrfs is a Windows driver for the next-generation Linux filesystem Btrfs.
A reimplementation from scratch, it contains no code from the Linux kernel,
and should work on any version from Windows 7 onwards. It is also included
and should work on any version from Windows Vista onwards. It is also included
as part of the free operating system [ReactOS](https://www.reactos.org/).

If your Btrfs filesystem is on a MD software RAID device created by Linux, you
will also need [WinMD](https://github.com/maharmstone/winmd) to get this to appear
under Windows.

First, a disclaimer:

You use this software at your own risk. I take no responsibility for any damage
Expand Down Expand Up @@ -72,6 +76,8 @@ Todo
----

* Oplocks
* Defragmentation
* Support for Btrfs quotas
* Windows 10 reserved storage

Installation
Expand All @@ -89,7 +95,15 @@ try disabling Secure Boot in your BIOS settings.
Uninstalling
------------

If you want to uninstall, go to Device Manager, find "Btrfs controller" under
If you want to uninstall, from a command prompt run:

```
RUNDLL32.EXE SETUPAPI.DLL,InstallHinfSection DefaultUninstall 132 btrfs.inf
```

You may need to give the full path to btrfs.inf.

You can also go to Device Manager, find "Btrfs controller" under
"Storage volumes", right click and choose "Uninstall". Tick the checkbox to
uninstall the driver as well, and let Windows reboot itself.

Expand Down Expand Up @@ -210,9 +224,23 @@ flag, e.g. `format /fs:ntfs D:`.
Synology seems to use LVM for its block devices. Until somebody writes an LVM driver
for Windows, you're out of luck.

* I can't mount a Thecus NAS

Thecus uses Linux's MD raid for its block devices. You will need to install [WinMD](https://github.com/maharmstone/winmd)
as well.

Changelog
---------

v1.4 (2019-08-31):
* Added fragmentation percentage to property sheet
* Added support for Windows Server 2003 and Windows Vista
* Added pagefile support
* Improved support for file locking
* Added support for booting from Btrfs on Windows Server 2003 (see https://www.youtube.com/watch?v=-5E2CHmHEUs)
* Fixed issue where driver could open same inode twice
* Other miscellaneous bug fixes

v1.3 (2019-06-10):
* Added support for new rename and delete functions introduced to Windows 10
* Added support for Windows 10's flag for case-sensitive directories
Expand Down
8 changes: 4 additions & 4 deletions src/btrfs.rc
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,3,0,0
PRODUCTVERSION 1,3,0,0
FILEVERSION 1,4,0,0
PRODUCTVERSION 1,4,0,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,12 +68,12 @@ BEGIN
BLOCK "080904b0"
BEGIN
VALUE "FileDescription", "WinBtrfs"
VALUE "FileVersion", "1.3"
VALUE "FileVersion", "1.4"
VALUE "InternalName", "btrfs"
VALUE "LegalCopyright", "Copyright (c) Mark Harmstone 2016-19"
VALUE "OriginalFilename", "btrfs.sys"
VALUE "ProductName", "WinBtrfs"
VALUE "ProductVersion", "1.3"
VALUE "ProductVersion", "1.4"
END
END
BLOCK "VarFileInfo"
Expand Down
8 changes: 4 additions & 4 deletions src/mkbtrfs/mkbtrfs.rc
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,3,0,0
PRODUCTVERSION 1,3,0,0
FILEVERSION 1,4,0,0
PRODUCTVERSION 1,4,0,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,12 +68,12 @@ BEGIN
BLOCK "080904b0"
BEGIN
VALUE "FileDescription", "Btrfs formatting utility"
VALUE "FileVersion", "1.3"
VALUE "FileVersion", "1.4"
VALUE "InternalName", "mkbtrfs"
VALUE "LegalCopyright", "Copyright (c) Mark Harmstone 2016-19"
VALUE "OriginalFilename", "mkbtrfs.exe"
VALUE "ProductName", "WinBtrfs"
VALUE "ProductVersion", "1.3"
VALUE "ProductVersion", "1.4"
END
END
BLOCK "VarFileInfo"
Expand Down
2 changes: 1 addition & 1 deletion src/shellext/resource.h
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@
#define IDC_DRIVE_LETTER_COMBO 1074

// Next default values for new objects
//
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 178
Expand Down
78 changes: 39 additions & 39 deletions src/shellext/shellbtrfs.rc
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,18 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_UK
// TEXTINCLUDE
//

1 TEXTINCLUDE
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END

2 TEXTINCLUDE
2 TEXTINCLUDE
BEGIN
"#include ""winres.h""\r\n"
"\0"
END

3 TEXTINCLUDE
3 TEXTINCLUDE
BEGIN
"\r\n"
"\0"
Expand All @@ -61,8 +61,8 @@ IDI_ICON1 ICON "subvol.ico"
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,3,0,0
PRODUCTVERSION 1,3,0,0
FILEVERSION 1,4,0,0
PRODUCTVERSION 1,4,0,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -78,12 +78,12 @@ BEGIN
BLOCK "080904b0"
BEGIN
VALUE "FileDescription", "WinBtrfs shell extension"
VALUE "FileVersion", "1.3"
VALUE "FileVersion", "1.4"
VALUE "InternalName", "btrfs"
VALUE "LegalCopyright", "Copyright (c) Mark Harmstone 2016-19"
VALUE "OriginalFilename", "shellbtrfs.dll"
VALUE "ProductName", "WinBtrfs"
VALUE "ProductVersion", "1.3"
VALUE "ProductVersion", "1.4"
END
END
BLOCK "VarFileInfo"
Expand Down Expand Up @@ -627,9 +627,9 @@ BEGIN
IDS_DEVLIST_READONLY_NO "No"
IDS_DEVLIST_ALLOC "Allocated"
IDS_DEVLIST_ALLOC_PC "%"
IDS_BALANCE_RUNNING_REMOVAL
IDS_BALANCE_RUNNING_REMOVAL
"Currently removing device %llu (%llu out of %llu chunks processed, %1.1f%%)"
IDS_BALANCE_PAUSED_REMOVAL
IDS_BALANCE_PAUSED_REMOVAL
"Removal of device %llu paused (%llu out of %llu chunks processed, %1.1f%%)"
IDS_BALANCE_CANCELLED_REMOVAL "Device removal cancelled."
IDS_BALANCE_COMPLETE_REMOVAL "Device removal completed successfully."
Expand All @@ -640,12 +640,12 @@ END
STRINGTABLE
BEGIN
IDS_CANNOT_REMOVE_RAID "The current RAID levels do not allow this device to be removed. You must do a conversion balance before you will be able to proceed."
IDS_REMOVE_DEVICE_CONFIRMATION
IDS_REMOVE_DEVICE_CONFIRMATION
"Are you sure that you want to remove device %s, %s?"
IDS_CONFIRMATION_TITLE "Confirmation"
IDS_ADD_DEVICE_CONFIRMATION
IDS_ADD_DEVICE_CONFIRMATION
"Are you sure that you want to add this device?"
IDS_ADD_DEVICE_CONFIRMATION_FS
IDS_ADD_DEVICE_CONFIRMATION_FS
"Are you sure that you want to add this device? It already appears to contain a filesystem (%s)."
IDS_BALANCE_FAILED "Balance failed (error %08x, %s)"
IDS_BALANCE_FAILED_REMOVAL "Device removal failed (error %08x, %s)"
Expand All @@ -656,32 +656,32 @@ BEGIN
IDS_SCRUB_FINISHED "Scrub finished."
IDS_SCRUB_PAUSED "Scrub paused (%llu out of %llu chunks processed, %1.1f%%)"
IDS_SCRUB_MSG_STARTED "Scrub started at %s %s."
IDS_SCRUB_MSG_RECOVERABLE_DATA
IDS_SCRUB_MSG_RECOVERABLE_DATA
"Recovered from data checksum error at %llx on device %llx."
IDS_SCRUB_MSG_RECOVERABLE_METADATA
IDS_SCRUB_MSG_RECOVERABLE_METADATA
"Recovered from metadata checksum error at %llx on device %llx."
END

STRINGTABLE
BEGIN
IDS_SCRUB_MSG_UNRECOVERABLE_DATA
IDS_SCRUB_MSG_UNRECOVERABLE_DATA
"Unrecoverable data checksum error at %llx on device %llx (%.*s, offset %llx)"
IDS_SCRUB_MSG_UNRECOVERABLE_DATA_SUBVOL
IDS_SCRUB_MSG_UNRECOVERABLE_DATA_SUBVOL
"Unrecoverable data checksum error at %llx on device %llx (subvol %llx, %.*s, offset %llx)"
IDS_SCRUB_MSG_UNRECOVERABLE_METADATA
IDS_SCRUB_MSG_UNRECOVERABLE_METADATA
"Unrecoverable metadata checksum error at %llx on device %llx (root %llx, level %x)"
IDS_SCRUB_MSG_UNRECOVERABLE_METADATA_FIRSTITEM
IDS_SCRUB_MSG_UNRECOVERABLE_METADATA_FIRSTITEM
"Unrecoverable metadata checksum error at %llx on device %llx (root %llx, level %x, first item %llx,%x,%llx)"
IDS_SCRUB_MSG_FINISHED "Scrub finished at %s %s."
IDS_SCRUB_MSG_SUMMARY "Scrubbed %s in %llu seconds (%s/s)."
IDS_BALANCE_SCRUB_RUNNING "Cannot start balance while scrub running."
IDS_SCRUB_BALANCE_RUNNING "Cannot start scrub while balance running."
IDS_SCRUB_MSG_SUMMARY_ERRORS_RECOVERABLE "Recovered from %llu error(s)."
IDS_SCRUB_MSG_SUMMARY_ERRORS_UNRECOVERABLE
IDS_SCRUB_MSG_SUMMARY_ERRORS_UNRECOVERABLE
"%llu unrecoverable error(s) found."
IDS_SCRUB_FAILED "Scrub failed with error %08x."
IDS_LOCK_FAILED "Unable to lock volume: error %08x. Make sure that there are no files open, and that you have closed any Explorer windows."
IDS_SCRUB_MSG_RECOVERABLE_PARITY
IDS_SCRUB_MSG_RECOVERABLE_PARITY
"Recovered from parity error at %llx on device %llx."
IDS_COMPRESS_ANY "(any)"
IDS_COMPRESS_ZLIB "Zlib"
Expand All @@ -700,12 +700,12 @@ BEGIN
IDS_OUT_OF_MEMORY "Out of memory."
IDS_RECV_UNKNOWN_COMMAND "Unrecognized command %u encountered."
IDS_RECV_CANT_OPEN_PATH "Couldn't open path %s (error %u, %s)."
IDS_RECV_CREATE_SUBVOL_FAILED
IDS_RECV_CREATE_SUBVOL_FAILED
"FSCTL_BTRFS_CREATE_SUBVOL returned %08x (%s)."
IDS_RECV_MISSING_PARAM "%S: could not find %s parameter."
IDS_RECV_SHORT_PARAM "%S: length of parameter %s was %u, expected %u."
IDS_RECV_MKNOD_FAILED "FSCTL_BTRFS_MKNOD returned %08x (%s)."
IDS_RECV_SET_REPARSE_POINT_FAILED
IDS_RECV_SET_REPARSE_POINT_FAILED
"FSCTL_SET_REPARSE_POINT returned %08x (%s)."
END

Expand All @@ -714,17 +714,17 @@ BEGIN
IDS_RECV_MOVEFILE_FAILED "MoveFile (%s -> %s) failed (error %u, %s)."
IDS_RECV_SETFILEPOINTER_FAILED "SetFilePointer failed (error %u, %s)."
IDS_RECV_WRITEFILE_FAILED "WriteFile failed (error %u, %s)."
IDS_RECV_CREATEHARDLINK_FAILED
IDS_RECV_CREATEHARDLINK_FAILED
"CreateHardLink (%s -> %s) failed (error %u, %s)."
IDS_RECV_SETENDOFFILE_FAILED "SetEndOfFile failed (error %u, %s)."
IDS_RECV_CANT_CREATE_FILE "Couldn't create %s (error %u, %s)."
IDS_RECV_SETINODEINFO_FAILED
IDS_RECV_SETINODEINFO_FAILED
"FSCTL_BTRFS_SET_INODE_INFO returned %08x (%s)."
IDS_RECV_SUCCESS "Received 1 subvolume successfully."
IDS_RECV_BUTTON_OK "OK"
IDS_RECV_SETFILEATTRIBUTES_FAILED
IDS_RECV_SETFILEATTRIBUTES_FAILED
"SetFileAttributes failed (error %u, %s)."
IDS_RECV_GETFILEATTRIBUTES_FAILED
IDS_RECV_GETFILEATTRIBUTES_FAILED
"GetFileAttributes failed (error %u, %s)."
IDS_RECV_CSUM_ERROR "Checksum error."
IDS_RECV_NOT_A_SEND_STREAM "File was not a send stream."
Expand All @@ -734,28 +734,28 @@ END

STRINGTABLE
BEGIN
IDS_RECV_RECEIVED_SUBVOL_FAILED
IDS_RECV_RECEIVED_SUBVOL_FAILED
"FSCTL_BTRFS_RECEIVED_SUBVOL returned %08x (%s)."
IDS_RECV_SETSECURITYOBJECT_FAILED
IDS_RECV_SETSECURITYOBJECT_FAILED
"NtSetSecurityObject returned %08x (%s)."
IDS_RECV_SETXATTR_FAILED "FSCTL_BTRFS_SET_XATTR returned %08x (%s)."
IDS_RECV_CREATETHREAD_FAILED "CreateThread failed (error %u, %s)."
IDS_RECV_FILE_TRUNCATED "File was truncated."
IDS_RECV_RESERVE_SUBVOL_FAILED
IDS_RECV_RESERVE_SUBVOL_FAILED
"FSCTL_BTRFS_RESERVE_SUBVOL returned %08x (%s)."
IDS_RECV_CANCELLED "Receiving cancelled."
IDS_RECV_CANT_FIND_PARENT_SUBVOL "Could not find parent subvolume."
IDS_RECV_FIND_SUBVOL_FAILED "FSCTL_BTRFS_FIND_SUBVOL returned %08x (%s)."
IDS_RECV_CREATE_SNAPSHOT_FAILED
IDS_RECV_CREATE_SNAPSHOT_FAILED
"FSCTL_BTRFS_CREATE_SNAPSHOT returned %08x (%s)."
IDS_RECV_GETVOLUMEPATHNAME_FAILED
IDS_RECV_GETVOLUMEPATHNAME_FAILED
"GetVolumePathName failed (error %u, %s)."
IDS_RECV_DELETEFILE_FAILED "DeleteFile failed for %s (error %u, %s)."
IDS_RECV_REMOVEDIRECTORY_FAILED
IDS_RECV_REMOVEDIRECTORY_FAILED
"RemoveDirectory failed for %s (error %u, %s)."
IDS_RECV_CANT_FIND_CLONE_SUBVOL "Could not find clone subvolume."
IDS_RECV_GETFILESIZEEX_FAILED "GetFileSizeEx failed (error %u, %s)."
IDS_RECV_DUPLICATE_EXTENTS_FAILED
IDS_RECV_DUPLICATE_EXTENTS_FAILED
"FSCTL_DUPLICATE_EXTENTS_TO_FILE returned %08x (%s)."
END

Expand All @@ -766,13 +766,13 @@ BEGIN
IDS_SEND_SUBVOL_HELP "Exports a subvolume so that it can be recreated on another volume."
IDS_SEND_CANT_OPEN_FILE "Error opening file %s (error %u, %s)."
IDS_SEND_CANT_OPEN_DIR "Error opening directory %s (error %u, %s)."
IDS_SEND_FSCTL_BTRFS_SEND_SUBVOL_FAILED
IDS_SEND_FSCTL_BTRFS_SEND_SUBVOL_FAILED
"FSCTL_BTRFS_SEND_SUBVOL returned error %08x (%s)."
IDS_SEND_FSCTL_BTRFS_READ_SEND_BUFFER_FAILED
IDS_SEND_FSCTL_BTRFS_READ_SEND_BUFFER_FAILED
"FSCTL_BTRFS_READ_SEND_BUFFER returned error %08x (%s)."
IDS_SEND_SUCCESS "Stream written successfully."
IDS_SEND_WRITEFILE_FAILED "Writing to file failed (error %u, %s)."
IDS_SEND_GET_FILE_INFO_FAILED
IDS_SEND_GET_FILE_INFO_FAILED
"GetFileInformationByHandle failed (error %u, %s)."
IDS_SEND_NOT_READONLY "Subvolume not readonly."
IDS_NOT_SUBVOL "Directory was not a subvolume."
Expand All @@ -788,9 +788,9 @@ BEGIN
IDS_SEND_WRITING "Writing..."
IDS_MISSING "(missing)"
IDS_RESIZE_SUCCESSFUL "Device %llx successfully resized to %s."
IDS_BALANCE_RUNNING_SHRINK
IDS_BALANCE_RUNNING_SHRINK
"Currently shrinking device %llu (%llu out of %llu chunks processed, %1.1f%%)"
IDS_BALANCE_PAUSED_SHRINK
IDS_BALANCE_PAUSED_SHRINK
"Shrinking of device %llu paused (%llu out of %llu chunks processed, %1.1f%%)"
IDS_BALANCE_CANCELLED_SHRINK "Device shrinking cancelled."
IDS_BALANCE_COMPLETE_SHRINK "Device successfully shrunk."
Expand All @@ -799,7 +799,7 @@ BEGIN
IDS_REGCREATEKEY_FAILED "RegCreateKey returned %08x"
IDS_REGSETVALUEEX_FAILED "RegSetValueEx returned %08x"
IDS_REGCLOSEKEY_FAILED "RegCloseKey returned %08x"
IDS_CANT_REFLINK_DIFFERENT_FS
IDS_CANT_REFLINK_DIFFERENT_FS
"Cannot create a reflink between two different filesystems."
END

Expand Down
8 changes: 4 additions & 4 deletions src/ubtrfs/ubtrfs.rc
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,3,0,0
PRODUCTVERSION 1,3,0,0
FILEVERSION 1,4,0,0
PRODUCTVERSION 1,4,0,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,12 +68,12 @@ BEGIN
BLOCK "080904b0"
BEGIN
VALUE "FileDescription", "Btrfs utility DLL"
VALUE "FileVersion", "1.3"
VALUE "FileVersion", "1.4"
VALUE "InternalName", "ubtrfs"
VALUE "LegalCopyright", "Copyright (c) Mark Harmstone 2016-19"
VALUE "OriginalFilename", "ubtrfs.dll"
VALUE "ProductName", "WinBtrfs"
VALUE "ProductVersion", "1.3"
VALUE "ProductVersion", "1.4"
END
END
BLOCK "VarFileInfo"
Expand Down

0 comments on commit ecd8013

Please sign in to comment.