On Mon, Jan 07, 2013 at 05:52:28PM +0300, Maksim Melnikau wrote: > On Mon, Jan 7, 2013 at 3:42 PM, Karel Zak <kzak@xxxxxxxxxx> wrote: > > Is it designed for anything other than swaparea? > Yes, zram is kind-of "compressed" block device in memory, any block > device operations could be done on top of it. Some people initialize > ext4 partitions "in memory" for temporary operations. > So, I still think fstab is correct place for describing fs/swap even > for zram. Questions are: 1) what is correct place for mkfs/mkswap zram > devices, at startup? 2) What is correct place for setting size for > zram block device? (right now I use systemd's tmpfiles.d) I see two independent operations 1/ initialize zram device 2/ create on-device filesystem/swap in our previous emails we have talked about 2/ for swap (call mkswap). I'm not sure if 1/ belongs to swapon/mount. It seems better to create a special udev rule for this purpose (we use the same solution for example for raw devices) or systemd unit. Note that the ideal solution is to have a special daemon for block devices management where you can configure complex scenarios and ask for usable device/filesystem.... but something like this is not implemented yet. These things are too complicated to hide it into mount/swapon. Karel -- Karel Zak <kzak@xxxxxxxxxx> http://karelzak.blogspot.com -- To unsubscribe from this list: send the line "unsubscribe util-linux" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html