To Cache drive or not to Cache drive?


Recommended Posts

I have been reading the cache drive stuff on the wiki and its use still confuses me. Here's what I gather from it:

 

1. If you have a cache drive, make sure it is a high speed drive, like a WD black drive...and at least 1TB (or a 500GB SSD if you got $$$$) if you write alot to it.

 

2. Stuff written to a cache drive gets moved nightly to the array.

 

What's all fine but then I read this:

 

1. Store apps, plugins, plex data/library, etc... on it. Problem: How do I prevent those items from being moved to the array? Because if it gets moved, then don't the plugins stop working?

 

Is there a more "laymen's" explanation of how to best utilize a cache drive?

Link to comment
  • Replies 366
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

I have been reading the cache drive stuff on the wiki and its use still confuses me. Here's what I gather from it:

 

1. If you have a cache drive, make sure it is a high speed drive, like a WD black drive...and at least 1TB (or a 500GB SSD if you got $$$$) if you write alot to it.

 

2. Stuff written to a cache drive gets moved nightly to the array.

 

What's all fine but then I read this:

 

1. Store apps, plugins, plex data/library, etc... on it. Problem: How do I prevent those items from being moved to the array? Because if it gets moved, then don't the plugins stop working?

 

Is there a more "laymen's" explanation of how to best utilize a cache drive?

 

Back in 5b8d, a new feature was introduced;

New feature called "cache-only" shares along with a re-written mover script.  The idea with a cache-only share is that the entire share exists only on the cache drive and is never moved to the array.  When a new share is created, and you have a cache disk, you are able to select 'only' for the "Use cache disk" setting.  In this case the top-level share name directory will only be created on the cache disk.  To support this, the 'mover' script is a bit different: it will never move top-level directories on the cache disk which don't also exist on the array.  Note to plug-in developers: if you have created a custom 'mover' script, please examine what is happening with the mover script of 5.0-beta8, since your custom script could now interfere with proper operation of the 'cache-only' share feature.

 

 

Before that people would create a share/folder on their cache but start the name with a . or _ so the folder would be hidden and not moved by the mover.

Link to comment

...

1. If you have a cache drive, make sure it is a high speed drive, like a WD black drive...and at least 1TB (or a 500GB SSD if you got $$$$) if you write alot to it.

 

2. Stuff written to a cache drive gets moved nightly to the array.

...

If you don't intend for your cache drive to be a "warm spare" then its size depends on your usage. It doesn't need to be any bigger than the amount your cache-only apps share needs, plus the amount you would expect to write in one day to any shares that are cached (assuming default mover schedule).

 

For example, I only have a 128GB SSD for cache. The only share I am caching is the one targetted by transmission and nzbget and I don't think I have ever downloaded more than 50GB in a day. I also have a cache-only share for my arch VM.

 

Before I got the SSD I was using a 150GB 10000rpm drive I already had. And even a slower drive will give some benefit because a write to the array is actually two reads and two writes, while a write to cache is just a write.

Link to comment

Does anyone know why write speeds to my SSD cache drive would be so bad or what I could look at to try to figure it out? I'm very new to unraid and linux so I'm not really sure how to troubleshoot this.

I believe you, but your graphs don't seem right! :o

Most of us would *LOVE* to have 111 meg write speed to a regular hard drive.

And if we were only getting 28 meg from an SSD, we'd throw it out!

So you aren't calculating parity at all, correct?

There is a thread in the forums about SSD drives and how to make sure their internal format is properly aligned. It was a problem with older SSD...but I think the newer ones don't have that problem.  You might search the forums for it.  (something like: "SSD internal block align" or SSD format)

 

 

 

 

If you're still concerned, add some details about your configuration (number of drives, motherboard, RAM, etc.) so we know what you're working with.

Also, details about the SSD (make,  model, size, etc.)

And a Syslog from unRAID would be very helpful.

 

I did find threads about SSD alignment but after looking through all that information it appears that my SSD is properly aligned.

 

As far as system specs go:

i5 4570

asus h87i plus

8gb ram

2x wd red 3tb

1x crucial m500 240gb

unraid 5.0.5

 

Still no parity drive so no parity calculations going on.

 

I attached my syslog which is probably a bit of a mess since I've been screwing with it so much.

syslog.zip

Link to comment

I have been reading the cache drive stuff on the wiki and its use still confuses me. Here's what I gather from it:

Like the others above, I have a small cache drive. (250Gig repurposed from an old PC). Mover runs every night. Any day that I actually fill up a 250G cache drive with work and/or fun is day that's too productive for good health.

 

(I do keep my PLEX library on the Cache drive...so there's only about 240 Gig of mischief I can do each day.)

Link to comment

I believe you, but your graphs don't seem right! :o

I did find threads about SSD alignment but after looking through all that information it appears that my SSD is properly aligned.

...

Still no parity drive so no parity calculations going on.

 

I attached my syslog which is probably a bit of a mess since I've been screwing with it so much.

Its very late for me, so I haven't finished looking at your syslog. but a couple of thoughts:

 

1. Add-ins/Plug-ins aren't well synchronized with each other...so they may start feuding over which library version to load in order to run properly. These conflicts are hard to find.  Best practice is to install the ones you actually USE, and not everything you see that your might want to try.  Get a basic working flash key set up. Copy it to your PC. Then, as you add plugins, if things don't work, you can always revert back to the saved version of the key.

2. Certain plugins are known to be incompatible with version 5.  Headphones is one. Check the forums for the latest status on that one.

3. I'm not sure about Transmission. I don't use it, but I saw someone suggesting that it,too, didn't work with version 5. Check the forums for status on that one, too.

 

4. I don't think the plug in conflicts explain the speeds you're seeing. Are you sure you didn't flip the labels on the speed graphs by mistake? :o

Link to comment

I believe you, but your graphs don't seem right! :o

I did find threads about SSD alignment but after looking through all that information it appears that my SSD is properly aligned.

...

Still no parity drive so no parity calculations going on.

 

I attached my syslog which is probably a bit of a mess since I've been screwing with it so much.

Its very late for me, so I haven't finished looking at your syslog. but a couple of thoughts:

 

1. Add-ins/Plug-ins aren't well synchronized with each other...so they may start feuding over which library version to load in order to run properly. These conflicts are hard to find.  Best practice is to install the ones you actually USE, and not everything you see that your might want to try.  Get a basic working flash key set up. Copy it to your PC. Then, as you add plugins, if things don't work, you can always revert back to the saved version of the key.

2. Certain plugins are known to be incompatible with version 5.  Headphones is one. Check the forums for the latest status on that one.

3. I'm not sure about Transmission. I don't use it, but I saw someone suggesting that it,too, didn't work with version 5. Check the forums for status on that one, too.

 

4. I don't think the plug in conflicts explain the speeds you're seeing. Are you sure you didn't flip the labels on the speed graphs by mistake? :o

 

I installed most of the plugins just to screw around but am planning to remove a few of them (including transmission). Also, are you sure about headphones? I see many people on the forum running version 5 with influencer's headphones installed and it functions perfectly fine for me.

 

As you say though I don't think it's a plugin issue, especially since I saw this issue before I had any plugins installed.

 

I wish I had flipped the labels on those pictures but unfortunately it's true :(

 

edit: I noticed some more strange behavior. When I'm copying to the cache drive, the unraid web interface becomes completely unresponsive. However, if I'm copying to directly to disk1 or the other hdd in the array, the web interface behaves normally. I don't understand that at all.

Link to comment

Probably not what you want to hear, but at 16:41, there was a Machine Check Exception:

Mar 19 16:41:29 LENNETH kernel: mce: [Hardware Error]: Machine check events logged

 

This appeared to be one of the more helpful pages about it.

 

I don't see evidence of overclocking or overheating, but that still leaves possible problems with the system bus, the CPU caches, the memory (especially if ECC memory), or other even rarer issue.  The easiest one to test for is memory, so try a long memtest.  And no, I can't say if there is any connection with your SSD I/O speed, although it is possible.

Link to comment

Probably not what you want to hear, but at 16:41, there was a Machine Check Exception:

Mar 19 16:41:29 LENNETH kernel: mce: [Hardware Error]: Machine check events logged

 

This appeared to be one of the more helpful pages about it.

 

I don't see evidence of overclocking or overheating, but that still leaves possible problems with the system bus, the CPU caches, the memory (especially if ECC memory), or other even rarer issue.  The easiest one to test for is memory, so try a long memtest.  And no, I can't say if there is any connection with your SSD I/O speed, although it is possible.

 

This article doesn't seem relevant to unraid because mcelog does not seem to be a function in unraid unless it must be run in some different fashion. So I guess that leaves it up to a guessing game as to what the machine check error is in reference to.

 

As far as memtest, I left it running for 5 passes yesterday and did not have any errors.

 

I'm going to order a new SSD and when it gets here I'm going to take all the drives out and start over with that much of it at least. Guess that'll narrow down whether it is a problem with the SSD itself.

Link to comment

Probably not what you want to hear, but at 16:41, there was a Machine Check Exception:

Mar 19 16:41:29 LENNETH kernel: mce: [Hardware Error]: Machine check events logged

 

This appeared to be one of the more helpful pages about it.

 

I don't see evidence of overclocking or overheating, but that still leaves possible problems with the system bus, the CPU caches, the memory (especially if ECC memory), or other even rarer issue.  The easiest one to test for is memory, so try a long memtest.  And no, I can't say if there is any connection with your SSD I/O speed, although it is possible.

 

I've been reading this forum extensively the past few days, and MCEs seem to have one thing in common, the H87I-Plus.

 

I'm trying my unRAID setup on an older B75/G1620 rig later, and will report back, but I think there's something not right with the H87I-Plus and unRAID (or perhaps it's Haswell?).

Link to comment

Probably not what you want to hear, but at 16:41, there was a Machine Check Exception:

Mar 19 16:41:29 LENNETH kernel: mce: [Hardware Error]: Machine check events logged

 

This appeared to be one of the more helpful pages about it.

 

I don't see evidence of overclocking or overheating, but that still leaves possible problems with the system bus, the CPU caches, the memory (especially if ECC memory), or other even rarer issue.  The easiest one to test for is memory, so try a long memtest.  And no, I can't say if there is any connection with your SSD I/O speed, although it is possible.

 

I've been reading this forum extensively the past few days, and MCEs seem to have one thing in common, the H87I-Plus.

 

I'm trying my unRAID setup on an older B75/G1620 rig later, and will report back, but I think there's something not right with the H87I-Plus and unRAID (or perhaps it's Haswell?).

 

Well that's disappointing if it's a motherboard compatibility issue.

 

Were you having any problems with your setup, though? Or were you just getting MCE's in your log?

Link to comment

To be honest I've sort of given up on unRAID right now, I couldn't get the plugins to work.  At all.  On either machine.  I'm obviously missing something really simple and obvious, so I'm going to have another spin at it next weekend.

Oh!

Try booting up into SAFE MODE (watch the boot from the Console).  Its full functionality but without ANY plugins...

Does THAT work?

Link to comment

I just installed my first unRaid server and I'm still copying data to it without a parity drive. Going to install it tomorrow hopefully. Now I have two 500GB HDDs (one 7.2k rpm, other WD Green) which I could use as Cache Drive but I have two more questions:

 

- Will the Cache drive always spun up or only when it accepts data? Because the old 7.2k rpm drive probably uses a lot more power than the Green (I want to determine which one to use as Cache)

- Do I need to configure anything else other than set the drive as Cache drive? I'm using 5.05 with Dynamix GUI. Can I configure the mover script via WebGUI or do I need to do it via telnet?

Link to comment

It'll only spin up if its reading/writing.

The webGUI has a couple of tabs with Cache Drive Settings.

(on the main page, you define the drive as cache. A Cache Tab then lets you configure it).

Then for each USER share that you want to use with Cache, go to that Share's configuration and allow use of the Cache Drive.

The Mover will run automatically at 3:10 AM, daily.

That's probably enough, but it can be tweaked if need be.

It can also be started manually.

 

Link to comment

To be honest I've sort of given up on unRAID right now, I couldn't get the plugins to work.  At all.  On either machine.  I'm obviously missing something really simple and obvious, so I'm going to have another spin at it next weekend.

 

Pleased to report I've got unRAID working fully on the hardware in my signature below.  I tried again on the H87I-Plus, still not great stability.  Not stable enough for me, I need to turn it on and leave it.  My current NAS (Asustor) has an uptime approaching 200 days, it's basically never been rebooted since I took it out of the box and plugged the drives in.

 

So far so good on the Celeron/B75.

Link to comment
  • 3 weeks later...

I replaced my Crucial M500 with a Samsung Evo SSD as my cache drive just to see if there was an issue with the SSD. Still having the same issues with slow and inconsistent write speed.

 

One thing I noticed is that if I'm copying a file from windows to \\unraid\cache\movies then the speed is slow but if i instead copy to \\unraid\movies which uses the cache then my write speed seems normal. Why would that be? What is happening differently? They both end up on the cache drive at the end of the copy.

 

I wouldn't really be concerned about it and would just copy everything to the share instead of the cache drive folder but I have cache-only shares that suffer from the same write speed problems. In that case I have no choice but to copy to \\unraid\cache\folder which gives me the slow speeds.

Link to comment

I replaced my Crucial M500 with a Samsung Evo SSD as my cache drive just to see if there was an issue with the SSD. Still having the same issues with slow and inconsistent write speed.

 

One thing I noticed is that if I'm copying a file from windows to \\unraid\cache\movies then the speed is slow but if i instead copy to \\unraid\movies which uses the cache then my write speed seems normal. Why would that be? What is happening differently? They both end up on the cache drive at the end of the copy.

 

I wouldn't really be concerned about it and would just copy everything to the share instead of the cache drive folder but I have cache-only shares that suffer from the same write speed problems. In that case I have no choice but to copy to \\unraid\cache\folder which gives me the slow speeds.

Don't know about your speed enigma, but you do have a choice. If apps is a cache-only share, then /mnt/cache/apps and /mnt/user/apps are the same. If you're exporting both the cache drive and that cache-only apps share, then \\unraid\apps and \\unraid\cache\apps are the same.
Link to comment

I replaced my Crucial M500 with a Samsung Evo SSD as my cache drive just to see if there was an issue with the SSD. Still having the same issues with slow and inconsistent write speed.

 

One thing I noticed is that if I'm copying a file from windows to \\unraid\cache\movies then the speed is slow but if i instead copy to \\unraid\movies which uses the cache then my write speed seems normal. Why would that be? What is happening differently? They both end up on the cache drive at the end of the copy.

 

I wouldn't really be concerned about it and would just copy everything to the share instead of the cache drive folder but I have cache-only shares that suffer from the same write speed problems. In that case I have no choice but to copy to \\unraid\cache\folder which gives me the slow speeds.

Don't know about your speed enigma, but you do have a choice. If apps is a cache-only share, then /mnt/cache/apps and /mnt/user/apps are the same. If you're exporting both the cache drive and that cache-only apps share, then \\unraid\apps and \\unraid\cache\apps are the same.

 

Good point, but it looks like whatever I was seeing was just a fluke as now it's slow again no matter where I copy files to.

Link to comment
  • 3 weeks later...

Because the MLC wasn't working.

 

Not that it matters because neither works properly.

You must be joking.

The only thing that couldn't work is the controller. The type of memory doesn't matter in this case.

What matters is that TLC memory is worst choice for UNRAID, because this system doesn't have trim support.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.