Ask Your Question
0

How can I install the CGroup V2 Plugin for Slurm?

asked 2023-04-08 18:27:23 +0000

qstack gravatar image

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
1

answered 2023-04-08 18:47:02 +0000

plato gravatar image

updated 2023-04-08 18:47:28 +0000

In case you get this error:

slurmd: symbol lookup error: /usr/local/lib/slurm/cgroup_v2.so: undefined symbol: dbus_error_init

when starting the slurmd edit the Makefile again:

Replace the line starting with cgroup_v2_la_LIBADD

cgroup_v2_la_LIBADD = ../common/libcgroup_common.la -ldbus-1

But the following, perform the build and copy the library again. The daemon should work now.

edit flag offensive delete link more
0

answered 2023-04-08 18:33:38 +0000

qstack gravatar image

updated 2023-04-08 18:42:42 +0000

First:

cd ~/slurm-22.05.6/src/plugins/cgroup/v2
make clean; make
When you run in the following error:
 -g -O2 -fno-omit-frame-pointer -pthread -ggdb3 -Wall -g -O1 -fno-strict-aliasing -MT cgroup_v2.lo -MD -MP -MF .deps/cgroup_v2.Tpo -c -o cgroup_v2.lo cgroup_v2.c
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I../../../.. -I../../../../slurm -DSLURM_PLUGIN_DEBUG -I../../../.. -I../../../../src/common -g -O2 -fno-omit-frame-pointer -pthread -ggdb3 -Wall -g -O1 -fno-strict-aliasing -MT cgroup_v2.lo -MD -MP -MF .deps/cgroup_v2.Tpo -c cgroup_v2.c  -fPIC -DPIC -o .libs/cgroup_v2.o
In file included from cgroup_v2.c:62:
../../../../src/plugins/cgroup/v2/cgroup_dbus.h:40:10: fatal error: dbus/dbus.h: No such file or directory
   40 | #include <dbus dbus.h="">
      |          ^~~~~~~~~~~~~
compilation terminated.

You can fix it with the following steps under Ubuntu 22.04:

sudo apt-get install libdbus-1-dev

Edit the Makefile and replace the line starting with AM_CPPFLAGS by

AM_CPPFLAGS = -I$(top_srcdir)/slurm -DSLURM_PLUGIN_DEBUG -I/usr/include/dbus-1.0 -I/usr/lib/x86_64-linux-gnu/dbus-1.0/include

Make sure that these are the correct include paths of `dbus.h and dbus-arch-deps.h

Now the build should work.

Copy the shared library:

sudo cp ~/slurm-22.05.6/src/plugins/cgroup/v2/.libs/cgroup_v2.so  /usr/local/lib/slurm

Make sure that this is the directory of your slurm installation.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

1 follower

Stats

Asked: 2023-04-08 18:27:23 +0000

Seen: 36 times

Last updated: Apr 08 '23