Anyone running RAM Disk?
#1
Finances are tight right now, but I've been considering running my xbmc root folder off of a ramdisk.

http://www.cyberciti.biz/faq/howto-creat...ilesystem/.

I did some initial testing and it seems to fly, however I only have 1GB of ram right now so the largest I could make the disk was 256M (which quickly got filled).

I was going to have a script to sync the hard disk /home/xbmc to the ramdisk on boot and sync it back on sleep, shutdown and once a day when I wouldn't be home.

R/W speeds on RAM blow SSD out of the water so everything should load near instantly.

Just wondering if I was the only one with this thought or if anyone else out there had thought of it or had something implemented.
Reply
#2
are you running the whole live installation there with all of the cache folders?
Reply
#3
Yes - just did this, and boy does it fly !

ramdisk size is 1.1Gig and even in single channel hdparm reports 500MB/s Smile

To keep everything in sync with the hard drive I use inotify/inosync with a 30 second delay ignoring the temp folder.

I have this one liner in an init file which sets everything up at boot.... Might do a detailed howto if people are interested

Code:
/sbin/mke2fs -m 0 /dev/ram0 && /bin/mount /dev/ram0 /mnt/ramdisk && /usr/bin/rsync -av /home/media/.xbmc-master /mnt/ramdisk/ && /bin/mkdir -p /mnt/ramdisk/usr/share && /bin/mkdir -p /mnt/ramdisk/usr/lib && /usr/bin/rsync -av /usr/share/xbmc /mnt/ramdisk/usr/share/ && /usr/bin/rsync -av /usr/lib/xbmc /mnt/ramdisk/usr/lib/ && inosync &

EDIT:

Oh forgot to add

cp /usr/bin/xbmc /usr/bin/xbmc-ramdisk and make the following modification as we want to run the binaries from RAM too Wink

Code:
root@media:/usr/bin# diff xbmc-ramdisk xbmc
22c22
< prefix="/mnt/ramdisk/usr"
---
> prefix="/usr"

EDIT: Just some notes for myself

Here's an old discussion about it.
http://forum.xbmc.org/showthread.php?tid=53856

Vertex 3 for the lazy
Reply
#4
a detailed howto would be awesome! Nod
Current setup:
Amlogic M3/MX + Linux + BOXiK Skin + Pioneer vsx520 + Dali Lektor 6

Previous setup:
Revo 3700 + flirc + OpenElec nightlies + Quartz + Pioneer vsx520 + Dali Lektor 6
atv1 + Crystalbuntu + XBMC nightly + xperience1080
Reply
#5
Ilia Wrote:a detailed howto would be awesome! Nod

I second that. A noob friendly howto would be muchly appreciated!
Reply
#6
Ilia Wrote:a detailed howto would be awesome! Nod

kaczor47 Wrote:I second that. A noob friendly howto would be muchly appreciated!

Will do very soon, when I get a chance Cool
Reply
#7
Very timely! Another member suggested I try ramdisk. What folders are you running from ramdisk? Is this the software you used? http://memory.dataram.com/products-and-s...re/ramdisk
Reply
#8
tboooe Wrote:Very timely! Another member suggested I try ramdisk. What folders are you running from ramdisk? Is this the software you used? http://memory.dataram.com/products-and-s...re/ramdisk

Hold your horses champion ... I've done this on Linux only - I'll try it out on windows when I can Wink

Folders - All of the install
Userdata - eg C:\Users\User ID\AppData\Roaming\XBMC\userdata

Fancy cache seems to work for some people but it wasn't happy with me this morning - Not sure why ...

http://forums.overclockers.co.uk/showthr...t=18243823
Reply
#9
Ilia Wrote:a detailed howto would be awesome! Nod

+1
Reply
#10
I think I'm going to try this out. Any other pointers? On my Revo I have 2 gigs of ram but 512meg of it is for video, so leaves me with about 1.5gig. So I could essentially use about a gig of it for a ramdisk, correct?

Also, I use DDS compression for my fanart which increases the size. I have about 600 movies. Just checked and my thumbnail folder is over a gig:

Code:
xbmc@xbmc01:~/.xbmc/userdata/Thumbnails$ du -sh
1.4G

Anyone care to work on a detailed how-to guide?
Reply
#11
SA (or anyone else), would you mind walking through these commands? It'd be much appreciated.

Code:
/sbin/mke2fs -m 0 /dev/ram0
/bin/mount /dev/ram0 /mnt/ramdisk
/usr/bin/rsync -av /home/media/.xbmc-master /mnt/ramdisk/
/bin/mkdir -p /mnt/ramdisk/usr/share
/bin/mkdir -p /mnt/ramdisk/usr/lib
/usr/bin/rsync -av /usr/share/xbmc /mnt/ramdisk/usr/share/
/usr/bin/rsync -av /usr/lib/xbmc /mnt/ramdisk/usr/lib/
inosync
cp /usr/bin/xbmc /usr/bin/xbmc-ramdisk
cd /usr/bin
diff xbmc-ramdisk xbmc

I'm not clear on this part:

22c22
< prefix="/mnt/ramdisk/usr"
---
> prefix="/usr"
Reply
#12
has anyone found a tutorial for this? I would really like to try this out.
Reply
#13
I made a step by step howto
http://forum.xbmc.org/showthread.php?p=8...post807379

Did not have time to add any explainaton. Probably not a good idea to do it any way if you need a more detailed guide anway. Quite possible to mess it up!
Reply
#14
I already have a Vertex 2 in my XBMC box, would this make that much of an improvement? Thumbnails are instant, but I kind of want fanart to load a tad faster. They take like a quarter of a second to load, but that may be the skin just telling it to wait
Server - Debain Squeeze Server + 6TB RAID5 + Sabnzbd + CP & SB
HTPC - Zotac MAG + 60GB Vertex 2 SSD + OpenELEC Frodo 12.1 + Aeon Nox
HTPC 2 - AppleTV 2
Reply
#15
Quote:I already have a Vertex 2 in my XBMC box, would this make that much of an improvement? Thumbnails are instant, but I kind of want fanart to load a tad faster. They take like a quarter of a second to load, but that may be the skin just telling it to wait

I assume that RAM is quicker than SSD, but that is not really the issue. We have to look at persived performance.
I just moved the skin to RAM as well and I think it made it quicker, but I still have to wait when I go to TV shows. Is this what you are talking about?

I suspect it is the fanart that is my issue. Cant be that slow to query the db with 50-60 tv series? Not sure how the fanart is loading, I can only find the thumbs and the address to the original pic on tvtdb.

You have to try to find out, in my case the issue is other processes using the disk. Not sure how helpful a SSD is in that case compared to a normal disk.
Reply

Logout Mark Read Team Forum Stats Members Help
Anyone running RAM Disk?0