Today, we don't create the sparse file "with the required size" when it
is first opened.   We could try seeking to maximum size of the device
and writing a single byte, and seeing whether or not that fails, and if
it fails, *assume* that this was caused by the target file system not
supporting such a large file.   There are other reasons why the write
might fail (for example, the system administrator or some supervisor
program might have set a file size limit via the setrlimit(3) systme
call or the /etc/security/limits.h file.

Also note not there is no supported way for a userspace program to query
the kernel to find the maximum file size supported by a particular file
system.  It will depend on the file system type, the file system block
size, and potentially, file system features that might be enabled on a
particular file system.

I agree that it would be nice to print a more user-friendly error
message, and right away, as opposed after writing up to 16TB of image
file.   We just want to make sure if the system administrator has set a
maximum file size of say, 2 GiB, and we print a message that it's a file
system limitation, that will be confusing and will result in my getting
angry bug reports.   :-)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2063369

Title:
  e2image reports invalid argument when used with big partitions

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/e2fsprogs/+bug/2063369/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to