As soon as a cowdevice is activated, status information can be read
from the file
n is the number of the cowdevice
$ cat /proc/cow/5
cowloop version: 2.14
number of opens: 1
pid of thread: 2533
read-only file: /dev/sda2
copy-on-write file: /tmp/myfs1.cow
state cowfile: dirty
bitmap-blocks: 32 (of 1024 bytes)
cowblocks in use: 762 (of 1024 bytes)
Most relevant values are:
Version of the current cowloop driver.
number of opens
Number of times that the cowdevice is currently open.
The cowdevice can only be deactivated when this value is 0.
Name of the file specified as read-only file for this cowdevice.
Number of read-requests issued on the read-only file since it has been
Name of the file specified as cowfile for this cowdevice.
Current state of the cowfile. The state 'dirty' means that
the bitmap in memory has been modified but not yet flushed to
the cowfile. The bitmap is automatically flushed when the cowdevice
With the command
a flush of the bitmap can be forced without deactivating the cowdevices.
After that the state 'clean' is shown until the driver modifies
the in-memory bitmap for that cowdevice again.
Number of blocks (1 Kbytes) used for the bitmap.
cowblocks in use
Number of modified blocks (1 Kbytes) in use in the cowfile.
This value can be used to determine the filling-degree of
the sparse copy-on-write file.
Number of read-requests issued on the copy-on-write file since it has been
Number of write-requests issued on the copy-on-write file since it has been
Note: from version 3.3. on the use of the
/proc file system
has been discontinued, and the debugfs has taken its place.
The debugfs is usually mounted under
This change was required by general kernel driver policy.