Tag: upstart

将基本的upstart脚本迁移到systemd

我刚刚将服务器从Ubuntu 14.10升级到15.04,并且我通过自定义upstart脚本启动的一些服务不再运行。 我的理解是我需要将它们重新编写为systemd服务,但是一夜之间学习整个systemd系统的想法有点令人生畏。 upstart脚本只是在启动时启动autossh ,我还有一些其他类似的脚本可以启动长时间运行的进程。 #/etc/init/autossh.conf description “Maintain a permanent SSH tunnel to ” start on started mountall stop on shutdown exec autossh -N other_server 如何将其重新编写为systemd服务?

如何在其他Upstart作业之前确保一个Upstart作业启动?

这是一个普遍的Upstart问题,但让我使用一个特定的案例: Centrify是ActiveDirectory网关的NIS。 它需要在依赖于它提供的身份validation服务的任何服务之前加载,例如autofs,cron,nis等。 事实certificate这很难实现,即使在尝试更改其他服务的依赖关系时(我认为我们不应该这样做,我也不想触及其他Upstart工作,如果可能的话) 。 建议?

Ubuntu 13.X上的Upstart日志消息在哪里?

在Ubuntu 12.04上,我可以在/var/log/syslog找到Upstart日志消息。 命令: # initctl log-priority info # initctl emit hello 日志: Apr 1 01:56:56 precise64 kernel: [ 8365.820425] init: Connection from private client Apr 1 01:56:56 precise64 kernel: [ 8365.821130] init: Handling hello event 在Ubuntu 13.10上,消息不出现在syslog或/var/log目录下的任何其他地方,尽管像logger hello这样的命令按预期工作。 我应该在其他地方找他们吗? 是否需要在某处更改配置设置? 对于在Ubuntu 13.04上似乎有同样问题的人来说,有一个关于服务器故障的问题,而且这里和这里的更多内容也可能描述了同样的问题。 不幸的是,这些问题没有提供问题的线索。

用于列出启动时启动的服务的命令?

是否有命令列出在启动时运行的服务? 我想它会涉及解析/etc/init.d/和各种/etc/rc.*目录。

如何更改cron日志级别?

我用exec cron -L 15替换exec cron运行sudo service cron reload , sudo service cron restart但没有改变。 Cron不记录作业的结束,也不记录失败的作业。 我在Ubuntu 14.04中没有问题,但现在我在Ubuntu 16.04中遇到了这个问题。 我做错了什么? 一步一步:首先我改变了/etc/init/cron.conf: sudo sed -i ‘s|exec cron$|exec cron -L15|’ /etc/init/cron.conf && sudo restart cron && cat /etc/init/cron.conf 现在是 $ cat /etc/init/cron.conf # cron – regular background program processing daemon # # cron is a standard UNIX program that […]

如何用systemd替换upstart?

由于Mark Shuttleworth决定将来切换到sytemd ,我想知道我现在是否可以在我的Ubuntu上安装它?

安装git-all时“无法连接到Upstart”错误

我使用的是15.04。 所以我正在使用git,我安装了标准版本。 我设置了ssh密钥,并能够将我的一个存储库克隆到正确的文件夹中。 一切都很好,然后我决定安装更多的包是个好主意。 我运行了sudo apt-get install git-all 。 我正在查看现在必须处理暴发户的错误代码。 start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused No apport report written because the error message indicates its a followup error from a previous failure. dpkg: error processing package runit (–configure): subprocess installed post-installation script returned error exit status […]