Skip to content

opencas service failed to run because of casctl settle failure #1698

@liyimeng

Description

@liyimeng

Description

In my system, I have open-cas service like this:

# /lib/systemd/system/open-cas.service
#
# Copyright(c) 2019-2021 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause
#

[Unit]
Description=opencas initialization service
After=systemd-remount-fs.service
Before=local-fs-pre.target local-fs.target
Wants=local-fs-pre.target local-fs.target
DefaultDependencies=no
OnFailure=emergency.target
OnFailureJobMode=isolate

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/sbin/casctl settle --timeout 1780 --interval 5
TimeoutStartSec=30min

[Install]
RequiredBy=local-fs.target local-fs-pre.target

# /etc/systemd/system/open-cas.service.d/override.conf
[Service]
ExecStartPre=/bin/bash -c 'echo Starting open-cas' 

but in systemd log, I see error like this

add_core() got an unexpected keyword argument 'try_add'

I try run the command manually, and get the same error

~# casctl settle 
add_core() got an unexpected keyword argument 'try_add'

So, it seems casctl settle is broken in some way

Expected Behavior

open-cas service should startup properly.

Actual Behavior

It failed

Steps to Reproduce

  1. Install opencas 25.03
  2. Configure opencas.conf
  3. Retart OS
  4. Error popup in systemd log

Context

Possible Fix

Logs

Configuration files

Your Environment

  • OpenCAS version (commit hash or tag): 25.03
  • Operating System: ubuntu
  • Kernel version: 6.8.0
  • Cache device type (NAND/Optane/other): nvme ssd
  • Core device type (HDD/SSD/other): hdd
  • Cache configuration:
    • Cache mode: (default: wt) wb
    • Cache line size: (default: 4) 32k
    • Promotion policy: (default: always)
    • Cleaning policy: (default: alru)acp
    • Sequential cutoff policy: (default: full)
  • Other (e.g. lsblk, casadm -P, casadm -L)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions