我在ubuntu18.04上通过dev堆栈安装openstack。我坚持“未能启动rtslib Failed tctl.service”,有谁知道如何解决这个问题吗?
+functions-common:apt_get:1109 sudo DEBIAN_FRONTEND=noninteractive http_proxy= https_proxy= no_proxy= apt-get --option Dpkg::Options::=--force-confold --assume-yes install targetcli-fb
Reading package lists... Done
Building dependency tree
Reading state information... Done
targetcli-fb is already the newest version (2.1.43-1).
The following package was automatically installed and is no longer required:
python3-wheel
Use 'sudo apt autoremove' to remove it.
0 upgraded, 0 newly installed, 0 to remove and 16 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up python3-rtslib-fb (2.1.71-0ubuntu1~cloud0) ...
Failed to start rtslib-fb-targetctl.service: Unit rtslib-fb-targetctl.service is not loaded properly: Exec format error.
See system logs and 'systemctl status rtslib-fb-targetctl.service' for details.
invoke-rc.d: initscript rtslib-fb-targetctl, action "start" failed.
● rtslib-fb-targetctl.service - Restore LIO kernel target configuration
Loaded: error (Reason: Exec format error)
Active: inactive (dead)
Apr 28 21:41:20 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
Apr 28 21:41:20 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
Apr 28 21:41:20 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
Apr 28 21:41:59 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
Apr 28 21:41:59 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
Apr 28 21:41:59 jun-VirtualBox systemd[1]: /lib/systemd/system/rtslib-fb-targetctl.service:9: Executable path is not absolute: mkdir -p /etc/rtslib-fb-target
dpkg: error processing package python3-rtslib-fb (--configure):
installed python3-rtslib-fb package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of targetcli-fb:
targetcli-fb depends on python3-rtslib-fb; however:
Package python3-rtslib-fb is not configured yet.
dpkg: error processing package targetcli-fb (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
Errors were encountered while processing:
python3-rtslib-fb
targetcli-fb
E: Sub-process /usr/bin/dpkg returned an error code (1)
+functions-common:apt_get:1 exit_trap
+./stack.sh:exit_trap:503 local r=100
++./stack.sh:exit_trap:504 jobs -p
+./stack.sh:exit_trap:504 jobs=
+./stack.sh:exit_trap:507 [[ -n '' ]]
+./stack.sh:exit_trap:513 '[' -f '' ']'
+./stack.sh:exit_trap:518 kill_spinner
+./stack.sh:kill_spinner:413 '[' '!' -z '' ']'
+./stack.sh:exit_trap:520 [[ 100 -ne 0 ]]
+./stack.sh:exit_trap:521 echo 'Error on exit'
Error on exit
+./stack.sh:exit_trap:523 type -p generate-subunit
+./stack.sh:exit_trap:524 generate-subunit 1619615804 1523 fail
+./stack.sh:exit_trap:526 [[ -z /opt/stack/logs ]]
+./stack.sh:exit_trap:529 /usr/bin/python3.6 /opt/stack/devstack/tools/worlddump.py -d /opt/stack/logs
World dumping... see /opt/stack/logs/worlddump-2021-04-28-134208.txt for details
+./stack.sh:exit_trap:538 exit 100这是rtslib fb- This tctl.service的内容。
root@jun-VirtualBox:/lib/systemd/system# cat rtslib-fb-targetctl.service
[Unit]
Description=Restore LIO kernel target configuration
Requires=sys-kernel-config.mount
After=sys-kernel-config.mount network.target local-fs.target
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=mkdir -p /etc/rtslib-fb-target
ExecStart=/usr/bin/targetctl restore
ExecStop=/usr/bin/targetctl clear
SyslogIdentifier=target
[Install]
WantedBy=multi-user.target发布于 2021-04-30 15:57:55
我只看到一件不正常的事情:您需要在服务中使用绝对路径,所以选择一个编辑器并将mkdir更改为/bin/mkdir。
编辑工作可通过以下方式完成:
sudo nano /lib/systemd/system/rtslib-fb-targetctl.service(或vi、vim或gedit)
,然后使用
systemctl status rtslib-fb-targetctl.service如果它能重新加载或停止/启动它
https://askubuntu.com/questions/1334619
复制相似问题