[PATCH,RFC] tmpfs support in setup-storage

Michael Tautschnig mt at debian.org
Wed May 26 21:26:09 CEST 2010


Hi again,

> Hi,
> 
> The attached patch (code only) adds support for tmpfs in setup-storage.
> 
> /tmp in a tmpfs filesystem is very common nowadays, as are other uses of
> tmpfs filesystems on machines with a lot of memory.
> 
> Currently, unless I missed something, the only way to have tmpfs
> filesystems set up during the installation is to use a hook to add them
> directly to the fstab before mounting partitions.
> 

I first thought we could somehow make it as simple as specifying tmpfs as file
system, but no, that doesn't really work and requires a lot more hacks.

> So I'm proposing this patch to add some support for tmpfs inside
> setup-storage. If it is accepted, I'll resend a patch including
> documentation.
> 
> Config example:
> 
> disk_config tmpfs
> tmpfs   /tmp    1G      defaults
> tmpfs   /foo    30%     defaults
> 
> Here, the percentage is relative to the amount of RAM installed in the
> machine; it's used directly as a parameter for the tmpfs mount
> (size=30%).
> 

Together with the percentage-of-RAM-size patch I'd prefer if RAM:X% was also
used in here. Maybe it should even be invalid without RAM:? Is the first column
good for anything? Could we have anything else than "tmpfs" in there?

> If you specify either of size= or nr_blocks= in the mount options for
> the tmpfs filesystem, the size given in the 3rd column will be silently
> ignored in favour of the size given in the mount options (used
> unchanged).
> 

I think some warning would be nice in those cases.

> 
> Comments?
> 

[...]

See above :-) And well, yes, documentation patches would be appreciated :-)
Honestly, I haven't really reviewed the patch itself. Could you maybe first
comment on my comments or even update the patch (and add documentation)?

Thanks a lot for the work,
Michael

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
Url : http://lists.uni-koeln.de/pipermail/linux-fai-devel/attachments/20100526/d48c6024/attachment.bin 


More information about the linux-fai-devel mailing list