lishpy Posted July 31, 2014 Share Posted July 31, 2014 I threw in a SSD as a cache drive in my server, hoping to get better write performance when I'm copying files. I moved over a 4.5gb file and I'm getting about 25MB/s. When writing without the cache installed I was getting 35-40 on average. Any clue what could be the problem? Tried swapping cables and it didn't make a difference. Also tried using a different SATA port (one on the motherboard or one on a SATA3 expansion card) and that didn't make a difference either. Unraid 5.05, user shares are set to include the cache drive. Syslog doesn't show anything about the drive when copying files over. I expected a heck of an improvement in write performance, and this SSD in an old USB2 enclosure writes quicker than this. Quote Link to comment
garycase Posted July 31, 2014 Share Posted July 31, 2014 What are you copying FROM? ... and are you definitely copying to a share -- not to a specific drive on the server? Finally, what is the network topology between the source and the UnRAID server? Quote Link to comment
lishpy Posted July 31, 2014 Author Share Posted July 31, 2014 Copying from my Mac Mini. It's the same set up I've been running for years, other than now adding that cache drive. The user share is connected via SMB. I know I'm writing to the user share because that's the only thing I have mounted on my mini. I don't ever mount individual disks. I also see in the webGUI that the cache drive was getting written to as the space was updating showing it was filling up. The server is hooked up to a Gig switch which runs to another gig switch which my Mini is hooked up to. unRAID sees the connection as a Full Duplex 1000. I also should add that the SMART reports on the SSD all check out just fine IMO. Quote Link to comment
garycase Posted July 31, 2014 Share Posted July 31, 2014 How much free space on the SSD? ... and how long since it's been optimized to ensure it's properly "trimmed" ? Quote Link to comment
lishpy Posted July 31, 2014 Author Share Posted July 31, 2014 How much free space on the SSD? ... and how long since it's been optimized to ensure it's properly "trimmed" ? The SSD is 2% full. It only has one file on it. As for the trimming, I have no idea. Going to go with never on that. I plugged it in, formatted it and it sat for a day or two. Now I copied the file and it's slow, so I made a thread. The SSD was used prior to this application so I can't honestly answer the TRIM question. Quote Link to comment
garycase Posted August 1, 2014 Share Posted August 1, 2014 If it's a relatively new (2 years old or newer) SSD, it likely has good garbage collection algorithms embedded in the firmware ... so if you simply let it sit idle for a couple days, the performance may actually improve. If it's older than that, look on the manufacturer's site and see if there's an optimization utility you can run. It'll likely require you to connect it to a Windows PC to run it; but it can make a HUGE difference in the performance if this drive hasn't been used on a system that supports TRIM. Another thing you could try to confirm it's the SSD and not some other issue is to replace the SSD with a "spinner" (traditional drive) and see if the cache then writes at higher speeds. Quote Link to comment
Fireball3 Posted August 1, 2014 Share Posted August 1, 2014 Have you tried to reset (powercycle) your network equipment (routers and switches)? Quote Link to comment
gfjardim Posted August 1, 2014 Share Posted August 1, 2014 Try trimming the file system: fstrim /mnt/cache PS. I have fstrim set as a weekly cronjob. echo "fstrim /mnt/cache" >/etc/cron.weekly/fstrim chmod +x /etc/cron.weekly/fstrim Quote Link to comment
lishpy Posted August 1, 2014 Author Share Posted August 1, 2014 If it's a relatively new (2 years old or newer) SSD, it likely has good garbage collection algorithms embedded in the firmware ... so if you simply let it sit idle for a couple days, the performance may actually improve. It's a Samsung 840 Pro. I tried to use the Samsung Magician software but it requires the drive to be installed in the computer it's running on and doesn't work over the external USB interface. Thanks Samsung for making a Windows only app. The only Windows computer I have is a laptop with only one drive bay. Try trimming the file system: fstrim /mnt/cache PS. I have fstrim set as a weekly cronjob. echo "fstrim /mnt/cache" >/etc/cron.weekly/fstrim chmod +x /etc/cron.weekly/fstrim fstrim comes up as a not found command. Is that included with unRAID 5.05 or something I need to move to 6 for? Quote Link to comment
Fireball3 Posted August 1, 2014 Share Posted August 1, 2014 Forget TRIM. Lets say, in worst case you might have only 50% of the SSD performance (which is very pessimistic), then you still have what? About 200 MB/s? I doubt your LAN can deliver that. Is your throughput to the protected share the same as to the SSD at the moment? Quote Link to comment
lishpy Posted August 1, 2014 Author Share Posted August 1, 2014 Forget TRIM. Lets say, in worst case you might have only 50% of the SSD performance (which is very pessimistic), then you still have what? About 200 MB/s? I doubt your LAN can deliver that. Is your throughput to the protected share the same as to the SSD at the moment? Everything in my place is wired Cat 6. The Mini is going through GigE to an unmanaged Gig Switch and straight to the unRAID server with Cat 6. unRAID reports a full 1000 duplex signal, same with the switch and the Mini. No other live devices are tied to the switch at the moment. What would be the differentiating factor here regarding throughput to the SSD vs this same exact setup using spinning disks (where I'm sustaining higher write speeds)? Even if it's a LAN issue, writing at 20MB/s is what, 160mbps? It's still utilizing speeds over 100mbps. Just don't see where the bottleneck is coming from. If I mount the cache drive itself and write directly to it instead of writing to the user share, same average speed of around 20MB/s. Quote Link to comment
garycase Posted August 1, 2014 Share Posted August 1, 2014 If you write directly to a disk share (NOT a cached write), do you still get the 30-40MB/s you were getting without a cache installed? This will confirm it's not a networking issue that's suddenly cropped up. Assuming that's the case, I'd do what I suggested earlier -- swap the SSD for a spinner and see if that then gives you improved write speeds. If so, you know the issue is with the SSD; if not, then we need to look at other possibilities. [You've already tried the most obvious suspects -- cables and ports] Quote Link to comment
lishpy Posted August 1, 2014 Author Share Posted August 1, 2014 Thanks everyone for the help. I will run some more tests tonight and update you all to try to get this resolved. Quote Link to comment
uldise Posted February 14, 2015 Share Posted February 14, 2015 Sorry for bumping a very old thread, but i have a similar problem with a cache drive. just purchased my first Plus key to test how cache drive works.. i have a small array with 2 disks and parity drive - write speeds are about 40-50 MB/s. i added a cache drive (ssd) and tried to test write speed. when i write(with dd command on the server itself) to /mnt/cache write speed is about 350 MB/s when i write to user share with cache enabled, then write speed are the same 40-50 MB/s, but writes to cache drive occur, i can see the just written file on /mnt/cache. looks like a problem are with user shares? any ideas how improve write speeds to user shares welcome thanks in advance. Quote Link to comment
garycase Posted February 14, 2015 Share Posted February 14, 2015 Are your user shares set to use the cache? Quote Link to comment
uldise Posted February 14, 2015 Share Posted February 14, 2015 attached a pick with share settings. as i noted before, when i write to this user share, a i can see a content on /mnt/cache too. Quote Link to comment
uldise Posted February 14, 2015 Share Posted February 14, 2015 some update from me - when write to user share in progress, shfs process eats all available CPU!! so, are there any config for mounting user shares to plau with? Quote Link to comment
Recommended Posts
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.