Page 1 of 1

How to set maximum number of cores to be used by slot?

Posted: Sun Mar 29, 2020 9:28 pm
by pmalek
Hello all,

I have the following config for my Linux client:

Code: Select all

<config>
  <user value="XXXXXX"/> <!-- Enter your user name here -->
  <team value="XXXXXX"/>         <!-- Your team number -->
  <passkey value="XXXXXX"/>       <!-- 32 hexadecimal characters if provided -->

  <data-directory value="/var/cache/fahclient/"/>
  <core-dir value="/var/cache/fahclient/"/>

  <power value="full"/>
  <max-packet-size value="big"/>
  <gpu value="true"/>      <!-- If true, attempt to autoconfigure GPUs -->
  <fold-anon value="false"/>
  <checkpoint value="3"/>

  <slot id="0" type="CPU"/>
  <slot id="1" type="GPU"/>

  <allow>127.0.0.1 x.x.x.x</allow>
  <web-allow>127.0.0.1 x.x.x.x</web-allow>
</config>
I'd like to change the number of cores being used in the CPU slot. I've seen the following in help:

Code: Select all

Folding Slot Configuration:
(...)

  cpu-type <string=AMD64>
    CPU type.

  cpus <integer=-1>
    How many CPUs a slot should use. <= 0 will use all the CPUs detected in the
    system.
But I cannot make it work either with command line options or with changes in the config.
Adding cpus to <slot id="0" type="CPU" cpus="4"/> doesn't seem to work. Is there any comprehensible documentation about this?

Re: How to set maximum number of cores to be used by slot?

Posted: Sun Mar 29, 2020 11:54 pm
by Joe_H
First, are you using FAHControl on the system itself or remotely to configure this system? If so it is relatively easy, use Configure, select the Slots tab and click on the cpu slot, and Edit. Then the CPU thread count is changed from '-1' to the number you want to use, Okay and Save the change.

If you are editing the config.xml file directly you would need to insert a line that looks something like this:

Code: Select all

 <cpus v='2'/>
after this line:

Code: Select all

  <slot id="0" type="CPU"/>
The XML format used by the client is a restricted subset, so it may need some tweaking to be accepted, not certain on indentation, etc.

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 6:17 am
by saad3000
Dears,

Is there a guide to the different parameters in config.xml for Linux client on the FAQ website?

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 6:33 am
by extide
Make the CPU Slot section look like:

Code: Select all

  <slot id='0' type='CPU'>
    <cpus v='24'/>
  </slot>

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 7:07 am
by anandhanju
What extide said, but with your desired number of cpus :)

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 7:56 am
by Neil-B
Search for "large primes" as the are numerous discussions .. best to avoid core counts that are multiple of primes large than 5 - actually avoiding 5 as well is safer.

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 8:02 am
by pmalek
Neil-B wrote:Search for "large primes" as the are numerous discussions .. best to avoid core counts that are multiple of primes large than 5 - actually avoiding 5 as well is safer.
Can you elaborate? (or link a topic) Why is that an issue?

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 8:03 am
by pmalek
extide wrote:Make the CPU Slot section look like:

Code: Select all

  <slot id='0' type='CPU'>
    <cpus v='24'/>
  </slot>
So I've tested

Code: Select all

  <slot id="0" type="CPU"/>
    <cpus v='4'/>
  <slot id="1" type="GPU"/>
and it works. I'll check out your version when my work units gets submitted (don't want to loose them points :) )

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 8:10 am
by anandhanju
You'd have to use it like this to take effect:

Code: Select all

  <slot id="0" type="CPU">
    <cpus v='4'/>
  </slot>
  <slot id="1" type="GPU"/>

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 8:18 am
by Neil-B
Sorry can't easily link post at the moment ... using small mobile phone to post ... a search on large primes will find posts explaining but I'll be at a desktop in half hour or so and check back with link then if you havent found one

Re: How to set maximum number of cores to be used by slot?

Posted: Fri Apr 03, 2020 9:05 am
by Neil-B
What to use … 2rd response to this post viewtopic.php?f=61&t=33791&p=321309

A little bit about why (my simplified approach - it is about making cubes with whole numbers) … 1st response to this post viewtopic.php?f=96&t=33701&p=321282#p321282

There are long/more in depth discussions about dimensioning but hopefully the above will help.