Rate This Document
Findability
Accuracy
Completeness
Readability

Running and Verification

If multiple nodes are running, configure the network environment:

  • In the /etc/hosts file, add the IP addresses and host names of the nodes.
  • Enable SSH password-free login between the nodes.
  • Disable the firewall and ensure that clients and servers are not disconnected.

Procedure

  1. Use PuTTY to log in to the server as the root user.
  2. Load the environment variables.
    export PATH=/path/to/CP2K/cp2k-7.1.0/exe/Linux-x86-64-gfortran:$PATH
  3. Create a hostfile file.
    1. Create hostfile.
      vi hostfile
    2. Press i to enter the edit mode and add the following content:
      Node1
      Node2

      Node1 and Node2 are the node names. Change them based on the site requirements and ensure that the nodes can ping each other.

    3. Press Esc, type :wq!, and press Enter to save the file and exit.
  4. Run the following commands as the root user:
    • Single node
      mpirun --allow-run-as-root -np 96 -x OMP_NUM_THREADS=1 cp2k.psmp /path/to/CP2K/cp2k-7.1.0/benchmarks/QS/H2O-256.inp > cp2k.H2O-256.inp.log
    • Dual nodes
      mpirun --allow-run-as-root -np 192 -N 96 -x PATH=$PATH -x LD_LIBRARY_PATH=$LD_LIBRARY_PATH -hostfile hostfile -x OMP_NUM_THREADS=1 cp2k.psmp /path/to/CP2K/cp2k-7.1.0/benchmarks/QS/H2O-256.inp > cp2k.H2O-256.inp.log
      Figure 1 Output example (1)
      Figure 2 Output example (2)

      The time difference between Figure 1 and Figure 2 and is 927s.

      Table 1 Parameter description

      Parameter

      Description

      -np

      Total number of running MPI processes.

      -N

      Number of processes running on each server.

      -hostfile

      Name of the node to be used.