Nitin Gupta | e98419c | 2010-08-09 22:56:56 +0530 | [diff] [blame] | 1 | What: /sys/block/zram<id>/disksize |
| 2 | Date: August 2010 |
| 3 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 4 | Description: |
| 5 | The disksize file is read-write and specifies the disk size |
| 6 | which represents the limit on the *uncompressed* worth of data |
| 7 | that can be stored in this disk. |
Bernhard M. Wiedemann | 51d8a7b | 2013-08-26 14:55:44 -0700 | [diff] [blame^] | 8 | Unit: bytes |
Nitin Gupta | e98419c | 2010-08-09 22:56:56 +0530 | [diff] [blame] | 9 | |
| 10 | What: /sys/block/zram<id>/initstate |
| 11 | Date: August 2010 |
| 12 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 13 | Description: |
Bernhard M. Wiedemann | 51d8a7b | 2013-08-26 14:55:44 -0700 | [diff] [blame^] | 14 | The initstate file is read-only and shows the initialization |
Nitin Gupta | e98419c | 2010-08-09 22:56:56 +0530 | [diff] [blame] | 15 | state of the device. |
| 16 | |
| 17 | What: /sys/block/zram<id>/reset |
| 18 | Date: August 2010 |
| 19 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 20 | Description: |
Bernhard M. Wiedemann | 51d8a7b | 2013-08-26 14:55:44 -0700 | [diff] [blame^] | 21 | The reset file is write-only and allows resetting the |
| 22 | device. The reset operation frees all the memory associated |
Nitin Gupta | e98419c | 2010-08-09 22:56:56 +0530 | [diff] [blame] | 23 | with this device. |
| 24 | |
| 25 | What: /sys/block/zram<id>/num_reads |
| 26 | Date: August 2010 |
| 27 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 28 | Description: |
| 29 | The num_reads file is read-only and specifies the number of |
| 30 | reads (failed or successful) done on this device. |
| 31 | |
| 32 | What: /sys/block/zram<id>/num_writes |
| 33 | Date: August 2010 |
| 34 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 35 | Description: |
| 36 | The num_writes file is read-only and specifies the number of |
| 37 | writes (failed or successful) done on this device. |
| 38 | |
| 39 | What: /sys/block/zram<id>/invalid_io |
| 40 | Date: August 2010 |
| 41 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 42 | Description: |
| 43 | The invalid_io file is read-only and specifies the number of |
| 44 | non-page-size-aligned I/O requests issued to this device. |
| 45 | |
| 46 | What: /sys/block/zram<id>/notify_free |
| 47 | Date: August 2010 |
| 48 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 49 | Description: |
| 50 | The notify_free file is read-only and specifies the number of |
| 51 | swap slot free notifications received by this device. These |
Bernhard M. Wiedemann | 51d8a7b | 2013-08-26 14:55:44 -0700 | [diff] [blame^] | 52 | notifications are sent to a swap block device when a swap slot |
Nitin Gupta | e98419c | 2010-08-09 22:56:56 +0530 | [diff] [blame] | 53 | is freed. This statistic is applicable only when this disk is |
| 54 | being used as a swap disk. |
| 55 | |
| 56 | What: /sys/block/zram<id>/discard |
| 57 | Date: August 2010 |
| 58 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 59 | Description: |
| 60 | The discard file is read-only and specifies the number of |
| 61 | discard requests received by this device. These requests |
| 62 | provide information to block device regarding blocks which are |
| 63 | no longer used by filesystem. |
| 64 | |
| 65 | What: /sys/block/zram<id>/zero_pages |
| 66 | Date: August 2010 |
| 67 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 68 | Description: |
| 69 | The zero_pages file is read-only and specifies number of zero |
| 70 | filled pages written to this disk. No memory is allocated for |
| 71 | such pages. |
| 72 | |
| 73 | What: /sys/block/zram<id>/orig_data_size |
| 74 | Date: August 2010 |
| 75 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 76 | Description: |
| 77 | The orig_data_size file is read-only and specifies uncompressed |
| 78 | size of data stored in this disk. This excludes zero-filled |
| 79 | pages (zero_pages) since no memory is allocated for them. |
| 80 | Unit: bytes |
| 81 | |
| 82 | What: /sys/block/zram<id>/compr_data_size |
| 83 | Date: August 2010 |
| 84 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 85 | Description: |
| 86 | The compr_data_size file is read-only and specifies compressed |
| 87 | size of data stored in this disk. So, compression ratio can be |
| 88 | calculated using orig_data_size and this statistic. |
| 89 | Unit: bytes |
| 90 | |
| 91 | What: /sys/block/zram<id>/mem_used_total |
| 92 | Date: August 2010 |
| 93 | Contact: Nitin Gupta <ngupta@vflare.org> |
| 94 | Description: |
| 95 | The mem_used_total file is read-only and specifies the amount |
| 96 | of memory, including allocator fragmentation and metadata |
| 97 | overhead, allocated for this disk. So, allocator space |
| 98 | efficiency can be calculated using compr_data_size and this |
| 99 | statistic. |
Jesper Juhl | f902831 | 2012-07-20 22:35:17 +0200 | [diff] [blame] | 100 | Unit: bytes |