Topic
IC4NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
3 replies Latest Post - ‏2009-10-07T08:49:34Z by SystemAdmin
SystemAdmin
SystemAdmin
7929 Posts
ACCEPTED ANSWER

Pinned topic Sequential CPLEX and parallel computations

‏2009-08-22T02:24:04Z |

[tanjad said:]

Dear members,

I have some technical questions about this new issue. We have an HPC
Linux Cluster which we want to use for running MIP optimizers. We would
like to perform a synchronous execution of programs (each program running
on a different CPU), where each thread contains a call to a CPLEX MIP
optimizer. We are not sure if one CPLEX licence is enough to perfom that
task. If not, could you please inform us where we could find a detailed
instruction about the installation of a number of sequential licenses on a
cluster computer? Also, in that case, we would like to know how to control the
usage of the licenses installed, i.e. how to guarantee that each time
the program is run, CPUs selected for execution will have access to at
least one CPLEX licence. We assume that the number of available
licenses will be smaller then the number of available CPUs.

Since the algorithm we want to test is very specific, we insist on using
a number of sequential optimizers within the cluster computer, rather
than using a parallel CPLEX optimizer.

I would be very grateful for your help.

With kindest regards,
Tatjana Davidovic.

Updated on 2009-10-07T08:49:34Z at 2009-10-07T08:49:34Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    7929 Posts
    ACCEPTED ANSWER

    Re: Sequential CPLEX and parallel computations

    ‏2009-09-10T20:49:45Z  in response to SystemAdmin

    [notdarkyet said:]

    Hi,

    first: I never tried using CPLEX in parallel on a cluster, but on a multi-CPU shared-memory computer. From my test with that configuration I think you would need as many licenses as there are threads used. Each of the threads needs its own CPLEX environment, blocking one license token druing execution.
    There are some global variables used in CPLEX (i.e. the iterations count) which inhibit solving more than one problem at the same time within the same environment.

    notdarkyet
    • SystemAdmin
      SystemAdmin
      7929 Posts
      ACCEPTED ANSWER

      Re: Sequential CPLEX and parallel computations

      ‏2009-09-28T06:16:50Z  in response to SystemAdmin

      [Mengue said:]

      Hi,

      I agree with Notdarkyet: you will need the same number of licences as the numbers of threads/CPUs.

      Best regards,

      Leandro Mengue
      • SystemAdmin
        SystemAdmin
        7929 Posts
        ACCEPTED ANSWER

        Re: Sequential CPLEX and parallel computations

        ‏2009-10-07T08:49:34Z  in response to SystemAdmin

        [achterberg said:]

        Hi Tatjana,

        [quote author=tanjad link=topic=1350.msg3773#msg3773 date=1250875444]
        I have some technical questions about this new issue. We have an HPC
        Linux Cluster which we want to use for running MIP optimizers. We would
        like to perform a synchronous execution of programs (each program running
        on a different CPU), where each thread contains a call to a CPLEX MIP
        optimizer. We are not sure if one CPLEX licence is enough to perfom that
        task.


        As far as I understand, you have a Linux cluster consisting of several machines with distributed memory, each machine having several cores. Furthermore, you want to run several sequential CPLEX MIP solves on each of the cluster machines. Is this correct?

        To the best of my knowledge, you need one license per process. Thus, if you create multiple threads in a single process, each of them opening one CPLEX environment in order to solve some problem instance (you need one environment per solve!), one license should be enough from a technical point of view. I don't know whether this is okay in terms of the license agreement (i.e., in terms of the legal aspects).

        In any case, you need a seperate license for each machine in your cluster. In other words, if you have a token server that provides 20 CPLEX licenses, you can run CPLEX on at most 20 machines at the same time.

        [quote author=tanjad link=topic=1350.msg3773#msg3773 date=1250875444]
        Also, in that case, we would like to know how to control the
        usage of the licenses installed, i.e. how to guarantee that each time
        the program is run, CPUs selected for execution will have access to at
        least one CPLEX licence. We assume that the number of available
        licenses will be smaller then the number of available CPUs.


        First, you need a floating license that issues license tokens. Second, it would be useful to check the status code of the CPXopenCPLEX() call and have a loop around it like this:

        cpxenv = CPXopenCPLEX(&status);
        while ( status != 0 ) {
          sleep(0.5);
          cpxenv = CPXopenCPLEX(&status);
        }


        Tobias