Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
Dmacleo Posted July 15, 2013 Posted July 15, 2013 wondering if anyone has ever run cache from ram and if so are there any problems? thanks.
Luis Manson Posted July 20, 2013 Posted July 20, 2013 sorry for not being helpful with your answer, but why not a SSD?i think the issue here can be on generated files which you might loose on a reboot or power failure
Dmacleo Posted July 20, 2013 Author Posted July 20, 2013 money and size. also looking towards files that are not as critical.
AlexJ Posted July 20, 2013 Posted July 20, 2013 Wondering how to do that.. well i have 32GB RAM server and could put 1GB for xcache... hack it would be a lot faster... But question is how to..
Luis Manson Posted July 29, 2013 Posted July 29, 2013 firt i would copy all file to some place, make a ram disk and copy files back, i would also copy/sync files to a disk periodicallyfor the ram disk in cache dir i would use a bind mount..however im still wondering how useful is this, SO fs cache should take care of this files
Dmacleo Posted July 29, 2013 Author Posted July 29, 2013 honestly have not had a free moment to even mess with this. as it stands I have 10-12gb ram thats not being used
Luis Manson Posted July 30, 2013 Posted July 30, 2013 well i dont think this can be a good idea, but here you go: $ sudo mount -t tmpfs -o size=123m none /mnt/boot-sav/ $ mount none on /mnt/boot-sav type tmpfs (rw,size=123m) $ dd bs=1M count=100 if=/dev/zero of=/mnt/boot-sav/test conv=fdatasync 100+0 records in 100+0 records out 104857600 bytes (105 MB) copied, 0.126435 s, 829 MB/s $ dd bs=1M count=100 if=/dev/zero of=/home/user/test conv=fdatasync 100+0 records in 100+0 records out 104857600 bytes (105 MB) copied, 2.07991 s, 50.4 MB/s then i would COPY this directory and bind mount it in ramdisk, after that, rsync files from cacheInDisk to cache (ramdisk)afterwards this should be done in the opposite way periodically to not loose anything and survive reboots without human intervention, and (not sure how) have the board survive with/without cache mounted in ramalso someone already took care of most of this, check: https://github.com/graysky2/anything-sync-daemon
Dmacleo Posted July 30, 2013 Author Posted July 30, 2013 I'll read up on that, thanks. not committing to any particular setup yet, want to really study the setups and how to recover if anything goes bad.
Makoto Posted July 30, 2013 Posted July 30, 2013 It would be better/more sane to just use APC and up the SHM size a bit. Also, when you have so much memory available, it's not all just sitting there unused. Your free memory is used for disk caching. Meaning, files that are frequently used are already likely loaded into RAM. So a ramdisk can actually give you no benefit while just introducing a risk of data loss.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.