open-iscsi / rtslib-fb

Python library for configuring the Linux kernel-based multiprotocol SCSI target (LIO)
Apache License 2.0
73 stars 90 forks source link

NotADirectoryError: [Errno 20] Not a directory: '/sys/kernel/config/target/iscsi/cpus_allowed_list' #195

Open lentilwallop opened 1 year ago

lentilwallop commented 1 year ago

under linux-6.3, when attempting to delete a backstore/fileio, i get: NotADirectoryError: [Errno 20] Not a directory: '/sys/kernel/config/target/iscsi/cpus_allowed_list'

offending line (tcm.py line 215 in my version): "for tpgt_dir in listdir(tpgts_base):" https://github.com/open-iscsi/rtslib-fb/blob/c1378f28f7abce6f8993a43c34d5e287b092bb1e/rtslib/tcm.py#L218C8-L218C8

maurizio-lombardi commented 1 year ago

Which version of rtslib/targetcli are you using?

urb31075 commented 12 months ago

It worked when installing Linux. Today this error suddenly appeared. There may have been a system update. targetcli-error

urb31075 commented 12 months ago

How to view the rtslib version?

gkyildirim commented 12 months ago

Same problem here. This is Ubuntu 22.04 with a custom kernel.

uname -a
Linux SHARED-DISKS 6.5.10-zabbly+ #ubuntu22.04 SMP PREEMPT_DYNAMIC Fri Nov  3 13:33:23 UTC 2023 aarch64 aarch64 aarch64 GNU/Linux
dpkg -l | grep LIO
ii  python3-rtslib-fb               2.1.74-0ubuntu4                         all          object API for managing the Linux LIO kernel target - Python 3.x
ii  targetcli-fb                    1:2.1.53-1ubuntu3                       all          Command shell for managing the Linux LIO kernel target
urb31075 commented 12 months ago
dupel:~ uname -a
Linux dupel 6.2.0-36-generic #37~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon Oct  9 15:34:04 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
dupel:~ dpkg -l | grep LIO
ii  python3-rtslib-fb                          2.1.74-0ubuntu4                         all          object API for managing the Linux LIO kernel target - Python 3.x
ii  targetcli-fb                               1:2.1.53-1ubuntu3                       all          Command shell for managing the Linux LIO kernel target
dupel:~
gkyildirim commented 12 months ago

Maybe this helps?

https://aur.archlinux.org/packages/targetcli-fb

maurizio-lombardi commented 11 months ago

@urb31075 @gkyildirim This was fixed in rtslib 2.1.75 more than 1 year ago. Ubuntu / Debian should update their packages