Git Clone
Flashcache:
git clone
https://github.com/facebook/flashcache.git Install and Configure
Flashcache (Note: Please remember to change the versions to match your
uname -r output!)
cd flashcache/
make KERNEL_TREE=/usr/src/kernels/2.6.32-042stab075.10
make install KERNEL_TREE=/usr/src/kernels/2.6.32-042stab075.10
modprobe flashcache Make sure
its running:
dmesg | tail
Making /vz
flashcached:
umount /vz
Find your UUID for /vz:
grep "/vz" /etc/fstab
flashcache_create -
p back vz_cached /dev/sdb /dev/disk/by-uuid/replace-with-your-
uuid Comment out vz in
fstab: nano /etc/fstab
Configuring
Flashcache Copy the config file:
cp /tmp/
flashcache/
utils/
flashcache /etc/
init.d
Change the permissions: chmod 755 /etc/
init.d/
flashcache nano /
etc/
init.d/
flashcache Change the following information:
SSD_DISK=/dev/sdb
BACKEND_DISK=/dev/disk/by-uuid/replace-with-your-
uuid CACHEDEV_NAME=vz_cached
MOUNTPOINT=/vz
FLASHCACHE_NAME=vz_cached
CTRL +X and save it.
Turn on
Flashcache at boot:
chkconfig flashcache on
Reboot the Server: reboot -n
Make sure everything looks good and run
df-h.
Do a DD test to make sure
flashcache is working.
First do a DD test in the root directory:
cd /
dd if=/dev/zero of=test bs=64k count=16k conv=fdatasync; unlink test
Note the output
Now do a DD test in the /vz directory.
cd /vz
dd if=/dev/zero of=test bs=64k count=16k conv=fdatasync; unlink test
Note awesomeness.
Everything is now setup as far as the base system with SolusVM OpenVZ and
Flashcache!
---------------------------------------------------------------------------------------------------------
0 comments:
Post a Comment