post_stop_commands.append(
CephIscsi.configfs_mount_umount(data_dir, mount=False)
)
+ daemon = daemon_form_create(ctx, ident)
+ if ident.daemon_type == 'nvmeof':
+ hp = '4096'
+ files = getattr(daemon, 'files', None)
+ if isinstance(files, dict):
+ val = files.get('spdk_huge_pages')
+ if isinstance(val, int):
+ hp = str(val)
+ elif isinstance(val, str) and val.isdigit():
+ hp = val
+ pre_start_commands.append(f'/usr/sbin/sysctl -w vm.nr_hugepages={hp} || true\n')
runscripts.write_service_scripts(
ctx,
)
# sysctl
- install_sysctl(ctx, ident.fsid, daemon_form_create(ctx, ident))
+ install_sysctl(ctx, ident.fsid, daemon)
# systemd
ic_ids = [