Index  | Recent Threads  | Unanswered Threads  | Who's Active  | Guidelines  | Search
 

Quick Go »
No member browsing this thread
Thread Status: Active
Total posts in this thread: 3
[ Jump to Last Post ]
Post new Thread
Author
This topic has been viewed 1641 times and has 2 replies Next Thread
Former Member
Cruncher
Joined: May 22, 2018
Post Count: 0
Status: Offline
Reply to this Post  Reply with Quote 
Computer optimization

How to eliminate involuntary resetting of work units when crunching CEP2 on many threads, and to some degree, although limited, also improving crunching speed and lowering the power usage.

Over the last year I've wasted many kWh due to resetting work units, but then I stumbled upon two good ideas here in the forums and so I decided to combine them into one how-to.

1: Short stroking HDD -- read this and this.
2: RAM caching HDD/SSD in Windows -- read this and this.

If you don't want to reinstall the operative system then go directly to point 2, RAM caching, or read point 3 at the bottom. RAM caching is often enough to solve the problem, but you should begin with short stroking if you have an HDD and want to increase the performance and energy efficiency.



1: Short stroking HDD

If you don't have a large HDD, buy the largest single platter HDD you can find. Perhaps something similar to this 1TB, 7200rpm, 4K native HDD (PDF).

Connect it to a computer, either directly inside the computer with a SATA cable (you'll have to reboot for the HDD to be detected) or via a USB connected HDD docking station, and go to:

=> Start menu => Right-click "Computer" => Manage => Storage => Disk Management


Create the first partition:

Find the new disk and right-click to the left to initialize it. Then right-click again, this time choose "New simple volume".

=> Next => set the size to 50GB (my processors have 24 threads and I have set my size to 50GB) => Next => Next => In Volume label write "BOINC partition" => Next => Finish



If you intend to download and store more work units than you can crunch immediately, which I don't do, and/or have a many-many threaded computer, think 32+, and like to crunch heavy work units such as CEP2, which I do, then choose a larger size, perhaps 100GB. The smaller it is, the faster the HDD will be, but it's also worth remembering that it's difficult to increase the size afterwards. It can be done but you'll need an HDD cloning sofrware or you'll have to redo the whole installation process. This is because the second partition, the C: partition, will be next to it and this partition, which contains the operative system, is difficult to move. An alternative could be to create one more partition between the BOINC partition and the C: partition and leave it empty for future needs.

Later you'll install BOINC's data directory in the BOINC partition, and the reason you'll do that, instead of installing the OS in this, the first and the fastest partition, is because most of the disk activity will take place in the BOINC data file, since the operative system by that point already has been loaded into the RAM. Short stroking means you want the HDD's arm to move as little as possible, and the first partition is closest to its resting position and has most bits per track there, since it's closest to the edge of the disk. This will lower the latency.


Create the second partition:

Right-click again, this time on the empty, unallocated part to the right, and choose "New simple volume". This time you'll name it "Empty partition" and set this one to the maximum space that's left, if you intend to use the computer for other things than just crunching. If you plan to use it as a dedicated cruncher, set the size to 50GB.


Install the OS:

Now that the HDD is sliced, the time has come to bake it. Connect it to the computer you intend to use it in and install the operative system by inserting the OS CD and rebooting. Follow the instructions and install the OS in the "Empty partition", which you can rename during the installation process. Afterwards, create a user account -- before you connect the computer to the internet -- and then go to Windows Update.


Install BOINC:

Download it and open the installation file. During the installation process you'll have to change the address for the Data directory by clicking:

=> Advanced => "Change", next to Data directory => In the drop-down menu click on the newly created BOINC partition and write "BOINC data" in the empty field at the bottom and click OK => Next => Install

You are now ready to go, if you don't want to install the RAM caching software. Go to the start menu, find the BOINC file and attach WCG after you've started the program.





2: RAM caching HDD/SSD in Windows

If you've done the steps in short stroking, jump to "Install the RAM cache software", otherwise uninstall BOINC if it's already installed. Reboot. Then do this:

=> Start menu => Right-click "Computer" => Manage => Storage => Disk Management


Create a second partition:

If there is at least 10GB of unallocated, empty space on the HDD -- how much you need depends on how many threads you will crunch with and what projects you're going to do, but have at least 0,5GB free space per crunching thread and for CEP2 threads, 2GB -- right-click the empty space and choose "New simple volume". There you name it "BOINC partition" and set the size to 50GB if possible (my processors have 24 threads and I have set my size to 50GB). If there is not enough empty space (or not any empty space at all), you could try to shrink the C: partition before creating the new partition, and in doing so opening up more of the empty space.

=> Right-click on the C: partition and choose "Shrink volume" => Set the size you want to shrink the C: partition to so that the freed up space reaches 50Gb together with the already empty space.


Install BOINC:

Download it and open the installation file. During the installation process you'll have to change the address for the data directory by clicking:

=> Advanced => "Change", next to Data directory => In the drop down menu click on the newly created BOINC partition and write "BOINC data" in the empty field at the bottom and click OK => Next => Install.


Install the RAM cache software:

Download the RAM caching software you intend to buy, or download the 14-day trial version from Superspeed, and install it in the newly created BOINC partition.



This is important because the software can't write to the HDD if it's installed in the C: partition, only allow the processor to read what's in the RAM cache. It needs to be in the same partition as the BOINC data directory so that it can regulate the writing process to the HDD's internal DDR2 cache. This could perhaps be a safety measure put in place to protect the OS.


Create a RAM cache:

Go to the start menu and click on Superspeed and then on Supercache.

=> Action => Cache => Configure => Set "Main memory allocation" to about 3GB, less if you can't spare that much => Set "Cache granularity" to 4kB => Check "Deferred-Write Mode" and set the "Lazywrite Latency" to 5s => OK => Close


You are now ready to go. Go to the start menu, find the BOINC file and attach WCG after you've started the program.





3:

The BOINC partition, and with it the RAM cache, if you choose to install such, can also be installed on a second HDD, instead of on the same HDD as the C: partition. This way, if you have a stationary computer or an e-sata HDD docking station, you can avoid having to reinstall the OS and still have the BOINC data file short stroked. This solution also has the added benefit of allowing you to increase the BOINC data partition, should future projects or processor upgrades require you to do so. The downside to this approach is that it uses more power because there are two HDDs.


A RAM cache improves the performance regardless if you use an HDD or an SSD, but it's the ability to avoid resetting wus that's most interesting. No more wasted kWh down the drain.

In this video they show how the random 4K numbers improve with different combination of RAM cache and RAMdisk, but they don't show the HDD RAM cache number. To the left are the read numbers and to the right the write numbers.

HDD: 0,3 - 2,3
SSD: 31 - 87
SSD + RAM cache: 459 - 121
RAMdisk 1 (1333MT/s): 1300 - 1019
RAMdisk 2 (2133MT/s): 1400 - 1078


The HDD in the test above was not short stroked. Short stroking this multiplatter, 1000GB HDD to 20% of total size, improved the latency by 24% and minimum transfer rate by 56%. You can use HDTune to see the returns from short stroking your particular drive. However, if you intend to use the HDD for a dedicated cruncher, all you have to do is set the HDD's partitions to the smallest size possible. But check the drive with HDTune anyway, because it could be damaged without you knowing it and that's true even for new HDDs.


A RAM cache, combined with a slow HDD, is a good alternative to a RAMdisk or an SSD, since it doesn't require as much memory as a RAMdisk, and since it's almost as fast as an SSD and doesn't wear out or lose data during a prolonged power off, such as during the summer heat when many don't crunch. It's almost a necessity when simultaneously crunching many extremely I/O heavy CEP2 and UGM work units with an HDD. I saw in the Resource Monitor that these can generate over 120MB/s in disk activity (yes bytes, not bits). No wonder an HDD without a RAM cache pops the fuse on some threads.

Before I installed a RAM cache I usually crunched 12 CEP2 and 12 UGM wus and 5-10 % used to reset on a regular basis, most of the time all the way down to zero. A RAM cache fixed the problem without short stroking. So much so that I could increase the number of CEP2 wus to 16 and have UGM on the remaining 8 threads. I also tried combining CEP2 and OET without a RAM cache on another computer, but the resetting problem persisted. So, a RAM cache it is.

One more thing remains to be done. I'm still staggering the CEP2 wus after restarting the computer, but I'll check if that's really necessary with a RAM cache.
[May 21, 2015 1:27:13 PM]   Link   Report threatening or abusive post: please login first  Go to top 
ThreadRipper
Veteran Cruncher
Sweden
Joined: Apr 26, 2007
Post Count: 1324
Status: Offline
Project Badges:
Reply to this Post  Reply with Quote 
Re: Computer optimization

Good post and guide!

I belive Samsung has included RAM caching in their "Samsung Magician" software, if you have a compatible Samsung SSD. This could be something to consider if planning of buying an SSD.

I'd like to add to the optimization that I have been running BOINC data directory on a RAM disk, and this works quite well.
Very fast storage (compared to HDD), no wear-down (compared to SSD). The drawback is of course that RAM is very expensive/GB.

Right now I have 32GB of RAM, of which I have dedicated 8GB to BOINC and set the client to run a maximum of 4 CEP2 simultaneousely. This has worked well (running a total of 12 threads). If I would be to run 12 CEP2 WUs at the same time, I Believe that around 24-26GB of RAM would be needed.

Then there is overclocking of course, but that should be a separate thread/guide :)
----------------------------------------

Join The International Team: https://www.worldcommunitygrid.org/team/viewTeamInfo.do?teamId=CK9RP1BKX1

AMD TR2990WX @ PBO, 64GB Quad 3200MHz 14-17-17-17-1T, RX6900XT @ Stock
AMD 3800X @ PBO
AMD 2700X @ 4GHz
[May 23, 2015 12:36:14 PM]   Link   Report threatening or abusive post: please login first  Go to top 
Former Member
Cruncher
Joined: May 22, 2018
Post Count: 0
Status: Offline
Reply to this Post  Reply with Quote 
Re: Computer optimization

I didn't know Samsung had this caching software, Samsung Magician. Having the write-cache turned on will increase the speed of the already fast SSD.

But RAMdisk remains the gold standard of fast storage, at least from the processor's side. Too bad CEP2 doesn't have a smaller storage requirement. If its storage need had been limited to the same size as OET's, 50MB, I would have chosen a RAMdisk without any hesitation. But I guess the algorithms don't permit that. Unfortunately, the project that is most write-intensive, and therefore would have benefited most from a RAMdisk, is also the project that requires most storage space. No matter how fast DIMMs' memory capacities increase, RAM always seems to remain the narrowest computing bottleneck. The difference these days is that it's a financial bottleneck, when it previously was a technical.


In my earlier comment I forgot to mention that the Acronis disk cloning software is free if you have a Western Digital disk.

Acronis True Image WD Edition Software
[May 24, 2015 2:46:13 PM]   Link   Report threatening or abusive post: please login first  Go to top 
[ Jump to Last Post ]
Post new Thread