January 20, 20179 yr I'm using unRAID version 6.2.4. I've mounted a new 120 GB drive (okay, it's old, actually) as /mnt/disks/Applications using the "Unassigned Devices" plugin. I've turned on sharing of the drive and adjusted its share permissions in its Settings. I now want to use that disk as my "appdata" share so I don't lose data on a reboot. This is not a cache disk. How do I do this? (BTW: I've seen lots of examples of how to use a cache disk for this but I don't have a cache disk. Mine is simply an Unassigned Devices disk.) Thanks so much!
January 20, 20179 yr Community Expert Since you don't have a cache disk why not use it that way? It's simpler to setup and it solves this particular problem easily.
January 20, 20179 yr Community Expert I say this because some people have some specific reasons to have an app drive separate from a cache drive, but I really can't think of any reason to have an app drive without a cache drive. I am just wondering what your reason is.
January 20, 20179 yr Author The drive I'm using is really too small to be a cache drive, I think. That, and it's only 5400 rpm, I think as well. I want the app drive strictly to hold settings for my apps, e.g. my MineOS installed Minecraft server, so that it doesn't lose settings between boots. I didn't want to use a 120gb cache drive as it isn't enough for my daily transfer right now while I'm getting everything setup (multiple Mac Time Machines, some other backups, media files, etc.) which are pushing well past 120gb per day, double or so, really. Wouldn't I want a large SSD for cache? I've read comments in lots of threads about using Unassigned Devices to mount a separate drive from the array to use as appdata, but none that I can find telling me how to do it. Is this not a good way to use this little spare drive?
January 20, 20179 yr The cache drive is the defacto application drive under unRAID 6. Placing Dockers on an unassigned drive is *also* supported but most documentation for people starting out references having appdata in its default location of the cache drive. I'd recommend using the 120GB drive as your cache drive and locating appdata on it for now unless you have near term plans to get more complicated and start using unAssigned Devices. By the way, there's no requirement to cache writes to the array on your cache drive. You can configure that for each user share. Personally I don't cache any writes at all, my cache drive is strictly an application drive. Note that the Use Cache Disk setting under the settings for the share should be set as "no" if you don't want to cache writes, and "only" or "prefer" for shares like appdata that you want to live strictly on the cache drive. A good reference is the Automatic System Shares section in this post, just scroll down a little.
January 20, 20179 yr Author Also, it's not clear from the Manual that the default for appdata is on the cache drive for this purpose. It would be nice if Lime made this really, really clear somewhere.
January 20, 20179 yr Author Now, if I enable a cache drive, do I have to go and change the locations for appdata and Docker storage img in Docker settings or will it switch automatically? If so, which one(s) do I change? What do I change them to? Thanks.
January 20, 20179 yr Community Expert Now, if I enable a cache drive, do I have to go and change the locations for appdata and Docker storage img in Docker settings or will it switch automatically? If so, which one(s) do I change? What do I change them to? Thanks. If you have them setup as in the "Automatic System Shares" linked in tdallen's post it should be automatic. If you don't have them setup that way then we would need to know exactly how you do have them setup before we can tell you what to do. Also, as for caching user share writes, user shares are set to not use cache by default (except as already noted with the system shares) so unless you have set a user share to use cache it will not.
January 20, 20179 yr Author Great! I'm early enough in my setup that I actually don't mind completely rebuilding my array / cache, etc. And it turns out, that I have a 500 GB drive I could use as a real cache if I decide to. With answers to various posts and defaults set to not cache shares automatically, I'm getting the impression that most people don't use the cache as cache at all. Is this true?
January 20, 20179 yr With answers to various posts and defaults set to not cache shares automatically, I'm getting the impression that most people don't use the cache as cache at all. Is this true? Partially. The cache drive started a long time ago in unraid terms as exactly that, JUST a cache drive to compensate for slow parity protected writes. Hardware and software has evolved greatly since then, and many people find array writes across the network plenty fast without caching, especially with turbo write now available. However... there is still a need for the extra performance boost of a non-parity protected drive for mainly internal unraid use, such as docker appdata and VM's. TL;DR Caching for externally generated writes isn't really needed anymore, but data generated and manipulated inside the unraid box can still benefit from the extra speed.
January 20, 20179 yr Community Expert With answers to various posts and defaults set to not cache shares automatically, I'm getting the impression that most people don't use the cache as cache at all. Is this true? I haven't done any polls, but I suspect most people use cache in multiple ways. I have a cache-only share for pictures that get used as wallpaper and screensavers on other computers. I keep them on cache so none of my array drives have to spin up to access them since they may be frequently accessed. I have a cache-only share for DVR recording since I don't usually keep any of that long-term so no need to store it on my array. The SSD cache allows it to be saved more quickly and doesn't spin up my parity drive for writing. I have a cache-only (could be cache-prefer now) appdata share that keeps all my docker applications "working storage". I have a cache-yes share for downloads so they get written to cache as they are download but are later copied to the array when mover runs. All of my other shares are cache-no. How much cache you need depends on how you use it.
January 20, 20179 yr Author Hmmmm. So I actually just added an SSD as my cache and completely reinstalled unRAID from square one. (Right down to re-formatting the boot device and re-downloading the key file.) I have caching turned on in Global Share settings. I see appdata, domains, and system folders on the cache drive. However, the Docker setup shows appdata at /mnt/user/appdata and the Docker storage location as /mnt/user/system/docker/docker.img Is there a guide somewhere to switching over to using the cache locations for appdata, Docker images, and VM images? I can't seem to find the resource I was looking at before. Thanks!
January 20, 20179 yr If you re-installed unRAID it was going to do exactly what you wanted by default - there shouldn't have been a need to change anything. Since you did... based on your prior posts you didn't want to change the global cache setting for shares. That will cause every share you create to use the cache drive for write-caching. Unless you want that, turn it back off. Take a look at the settings for each individual share by clicking on it in the main window. That's were you can set a specific share to Use Cache "yes" or "prefer". You should see that "prefer" was selected for appdata and system by default. If not, then change it. You don't need to change any references from /mnt/user/appdata to /mnt/cache/appdata. They are for all intents and purposes the same thing, with the exception that the /mnt/user reference is going through FUSE and therefore has the intelligence to make use of the cache drive when appropriate.
January 20, 20179 yr Author Alright, so I reset "Use cache disk" to "no" in Global shares settings. I just checked the system shares and you're right...they're either set to Prefer or Yes for use cache disk (only isos is set to Yes). I then exported each of these shares and did a test. Once exported, I wrote to each one using my primary non-root user account from my Mac. I created a separate folder under each one. When I ssh'd over using my root account, and look at /mnt/user/appdata for example, I can see the folder I just built there. When I look at /mnt/cache/appdata, it's not there. They don't seem to be connected. Writing to /mnt/user/appdata doesn't seem to affect /mnt/cache/appata. And, there is no /mnt/cache/isos directory, either. Am I missing something? Thanks again.
January 20, 20179 yr My install is older, so rather than give you steps I'll give you settings since the steps have changed. My Global Share Settings Use Cache is set to Yes (and maybe I was wrong, and you should change that). My setting for each user share is Use Cache Disk "No", except for the ones I want to use cache. My setting for each user share that should use the cache disk is "yes" or "prefer". A restart of the array is needed if you change the Global Share Settings.
January 20, 20179 yr Author Yup. Looks like it needs to have "Yes" set in Global share settings. Now changes I make to the shares themselves show up in the dirs on the cache. And isos is there now. Thanks!
January 20, 20179 yr Community Expert My install is older, so rather than give you steps I'll give you settings since the steps have changed. My Global Share Settings Use Cache is set to Yes (and maybe I was wrong, and you should change that). My setting for each user share is Use Cache Disk "No", except for the ones I want to use cache. My setting for each user share that should use the cache disk is "yes" or "prefer". A restart of the array is needed if you change the Global Share Settings. If you turn on Help, you will see this for Global Share Settings - Cache Settings - Use cache disk: If set to 'Yes' then User Shares can possibly make use of the Cache Disk. You still need to enable use of the Cache Disk on individual user shares.So that would imply that setting it to No means no user shares can use cache. As far as I know it has always worked this way.
February 28, 20188 yr I initially thought I had no need to use a Cache disk for my files, so I opted to set up a M.2 drive in unassigned devices to store my files, Dockers and VMs. I would now also like to move over my appdata and ISOs folder to my unassigned devices drive. After reading this thread, it seems like the best solution would be to just move my unassigned devices drive into cache and only turn on cache for the folders I want to run on my M.2 drive. Is this the best method to get Dockers, VMs, appdata, ISOs and personal files on one drive?
November 26, 20187 yr To answer the original question: Under Settings -> Docker -> Advanced View you can change the folder where it stores appdata and the docker img. don't forget to move the files before restarting docker. FYI: You can also move the libvirt folder too. (Settings - VM Manager - Advanced View)
Archived
This topic is now archived and is closed to further replies.