On 2003.05.29 17:29, Danny Tholen wrote:
hmm.. did you already got an answer? whats wrong with:
mke2fs -i 1024 /dev/ram0 4096 mount -n -t ext2 -o defaults, nocheck /dev/ram0 /mnt/ram
you might want to think abit about decent checks on the size, the amount of memory available and whether there already is a ramdisk, etc Ofcourse, is it really a good idea to let an rpm do this? Why not the startup
script of the program?
Also, I think that any app that needs tmp space to be on a ramdisk should consider not using tmp files at all for that data (ie: its a bug).
COOL! An answer! :-)
Actually, I changed my mind... I don't want a ramdisk.
The problem is: jack is a realtime app. It stores a lot of small stuff in /tmp/jack, and it works great on ext2fs, but not ext3fs or reiserfs (haven't tested XFS).
So I was going to try to mount /tmp/jack as an ext2 ramdisk, but I think tmpfs would be a better option. Why? It's memory use is auto-limiting, the overflow goes to disk, and it's all cleard on reboot/remount/whatever. Also, you can mount it on TOP of the existing mountpoints without error.
So now my problem is changed... I just need a safe and easy way to mount /tmp/jack as a tmpfs.
Just add a line to /etc/fstab should do it, right? Also a mount command in %post so it's available without reboot.
What's a safe way to add/remove a line to fstab? Perl?
Jack is in main now, so I hope it's okay for a 'main' app to play with fstab.
Austin
--
Austin Acton Hon.B.Sc.
Synthetic Organic Chemist, Teaching Assistant
Department of Chemistry, York University, Toronto
MandrakeClub Volunteer (www.mandrakeclub.com)
homepage: www.groundstate.ca