RAMDisk

RAM Disks for faster MIFOS builds and test runs

MySQL on RAM can be incredibly fast for development and testing. It is specially useful because MySQL on ext4 is very slow (compared ot ext3). 

Quick Instructions for Ubuntu

On a fresh install of MySQL on Ubuntu (assuming MySQL is being used for Mifos development only). BE CAREFUL, you can end up messing up your mysql setup. You need to understand that you have enough RAM to have MySQL on RAM. (if you are not doing anything apart from Mifos development then 3GB RAM is enough for MySQL on RAM)

# become root, and be extra careful about the next commands
sudo su
stop mysql
# copy the mysql data directory
cp -rp /var/lib/mysql/ ~/
# allocate 500 MB memory for data directory
mount -t tmpfs -o size=500M tmpfs /var/lib/mysql/
cp -rp ~/mysql/* /var/lib/mysql/
start mysql
# exit root, get back to your previous login mode
exit

Now you are ready for using mysql, but remember, limit of you data directory is 500 MB so don't use tf for loading more data. 
On restart, you would have to reset this, you can also setup a init script (DO that only if you know what you are doing).

Using a RAM Disk as MySQL datadir

mySQL has an http://dev.mysql.com/doc/refman/5.1/en/memory-storage-engine.html, but due to some differences (see e.g. http://dev.mysql.com/tech-resources/articles/storage-engine/part_3.html) that is not suitable for MIFOS. (Michael Vorburger tried converting latest-schema.sql, replacing all "engine=innodb" by "engine=memory", and all BLOB by VARBINARY(250), and all TEXT by VARCHAR(4096). The tests ran, but produced Tests run: 2359, Failures: 28, Errors: 92, which I did not investigate further.)

mySQL can however put it's (InnoDB) datadir on a RAM Disk. This can reduce to half the time needed for database intensive parts of the build (the integration tests).

The space requirements for such a RAM disk for the (just for the mysqldata) seems to be about 300mb-ish for integration tests (mifostest), and around min. 500mb if acceptanceTests run after integration tests. Basically it works with a 2 GB RAM workstation, but may make more sense if you have more RAM available (say 4 GB or more), depending on what else you are running.

On Linux

http://groups.google.com/group/mifosdeveloper/browse_thread/thread/ab164f0560cba5a3?pli=1

http://groups.google.com/group/mifosdeveloper/browse_thread/thread/31f010716c4e992d

On Mac OS X

See convenient scripts on http://github.com/vorburger/mifos-stuff.

RAM disk as per http://osxdaily.com/2007/03/23/create-a-ram-disk-in-mac-os-x/, http://apple.wikia.com/wiki/RAM_disk#Creating_a_RAM_disk, http://snippets.dzone.com/posts/show/1808, http://hints.macworld.com/article.php?story=20020530084607311.

On Windows

TBD, e.g. http://www.mydigitallife.info/2007/05/27/free-ramdisk-for-windows-vista-xp-2000-and-2003-server/ ???

Using a RAM Disk as Maven target build directory

_TBD http://www.google.com/search?q=maven+build+target+directory+ramdisk, e.g. http://stackoverflow.com/questions/1005407/can-i-move-maven2-target-folder-to-another-device_