我在我的机器上运行Bosh lite,在Ubuntu 16.04 Stemcell上运行的三个花园容器上部署了一个Patroni集群。我创建了一个systemd服务,我想在这个测试环境中使用它,但我无法启动它。 问题是,默认情况下,Bosh lite不是以systemd开头的,如果我运行: systemctl --user start patroni_fencer.service 我得到了以下错误: Failed to connect to bus: No such file or directory 我在StackOverflow上发现了两个可能的讨论: Failed to connect
每次在WSL2上启动Ubuntu时,我都需要运行WSL2。
当我启动Ubuntu时,如何使服务自动启动?
WSL不使用systemd,所以sudo systemctl enable postgresql不能工作。
$ sudo systemctl status postgresql
System has not been booted with systemd as init system (PID 1).
Can't operate. Failed to connect to bus: Host is down
是否有一种在启动时启动服务的标准方法?
编辑
我想在Ubuntu启动时
我在安装UbuntuServer18.10时通过snap安装了Docker。
如果我有一个引用docker命令的systemd单元文件,我会得到以下错误:
Executable "docker" not found in path "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
我不知道这条搜索路线是从哪里来的。它与/etc/环境中的内容不匹配。
在不修改单元文件的情况下,我是否可以全局更改systemd使用的搜索路径以包含/snap/bin?
在Ubuntu18.04系统上,只使用没
当我试图在家里重启或关闭我的主存储服务器时,我遇到了一个问题。关机过程卸载并停止大部分系统,直到它到达systemd-udevd,然后挂起。
显示器上显示的内容如下:
...
[ OK ] Reached target Unmount All Filesystems.
[ OK ] Stopped Remount Root and Kernel File Systems.
[ OK ] Reached target Shutdown.
[ OK ] Reached target Final Step.
[ OK ] Finished Reboot.
[ OK ] Rea
我有一个节点应用程序,通过Ubuntu16.04上的systemd服务运行
但是,经过一段时间后,服务将自动重新启动。
我在日志里看到的是:
Mar 17 14:35:10 testmachine systemd[1]: myService.service: Main process exited, code=exited, status=7/NOTRUNNING
Mar 17 14:35:10 testmachine systemd[1]: myService.service: Unit entered failed state.
Mar 17 14:35:10 testmachine sy
我把我的主文件夹移到了一台新笔记本电脑上。在我使用Ubuntu18.04和我的新笔记本电脑之前,我使用的是Kubuntu19.04。
我将所有相关文件夹复制到新系统中,但流浪者无法在新系统上启动旧容器:
vagrant up trusty64
Bringing machine 'trusty64' up with 'virtualbox' provider...
==> trusty64: Clearing any previously set network interfaces...
There was an error while executing
几天前,我将服务器从16.04更新到18.04,今天我发现:
19 packages can be updated.
18 updates are security updates.
我做了:
sudo apt-get update
sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept