简体   繁体   English

puppetserver.service 的作业失败,因为控制进程退出并显示错误代码

[英]Job for puppetserver.service failed because the control process exited with error code

Puppet: 5.3.3木偶:5.3.3
OS: Ubuntu Xenial (virtual box) Inbuilt RAM: 4GB操作系统:Ubuntu Xenial(虚拟盒子)内置内存:4GB

I am new to Puppet.我是木偶新手。 After installing Puppet v5.3.3, I wanted to start the server:安装 Puppet v5.3.3 后,我想启动服务器:

systemctl start puppetserver (or service puppetserver start) systemctl 启动 puppetserver(或服务 puppetserver 启动)

This gave me following error:这给了我以下错误:
Job for puppetserver.service failed because the control process exited with error code. See "systemctl status puppetserver.service" and "journalctl -xe" for details.


systemctl status puppetserver.service systemctl状态puppetserver.service

    puppetserver.service - puppetserver Service  
    Loaded: loaded (/lib/systemd/system/puppetserver.service; disabled; vendor preset: enabled)  
    Active: activating (start) since Wed 2018-01-24 13:08:28 UTC; 39s ago  
    Control: 19426 (bash)  
    Tasks: 17  
    Memory: 445.7M  
    CPU: 1min 12.296s  
    CGroup: /system.slice/puppetserver.service  
       ├─19426 bash /opt/puppetlabs/server/apps/puppetserver/cli/apps/start  
       ├─19434 /usr/bin/java -Xms400m -Xmx400m -Djava.security.egd=/dev/urandom -XX:OnOutOfMemoryError=kill -9 %p -cp /opt/puppetlabs/serve  
       └─19569 sleep 1

    Jan 24 13:08:28 master systemd[1]: Starting puppetserver Service...

I followed a few blogs ( blog1 , blog2 )that explained我关注了一些解释的博客( blog1blog2
- first identify the free memory: free -m (look mem row, free tab) - 首先识别空闲的 memory: free -m (查看 mem 行,free 选项卡)
- change memory allocation of file puppetserver - 更改 memory 文件puppetserver的分配

vi /etc/default/puppetserver vi /etc/default/puppetserver

    ###########################################  
    # Init settings for puppetserver  
    ###########################################  

    # Location of your Java binary (version 7 or higher)
    JAVA_BIN="/usr/bin/java"

    # Modify this if you'd like to change the memory allocation, enable JMX, etc
    JAVA_ARGS="-Xms400m -Xmx400m -        Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger"

    # These normally shouldn't need to be edited if using OS packages
    USER="puppet"
    GROUP="puppet"
    INSTALL_DIR="/opt/puppetlabs/server/apps/puppetserver"
    CONFIG="/etc/puppetlabs/puppetserver/conf.d"

    # Bootstrap path
        BOOTSTRAP_CONFIG="/etc/puppetlabs/puppetserver/services.d/,/opt/puppetlabs/server/apps/puppetserver/config/services.d/"

Even after reducing memory, I was not able to start puppetserver .即使在减少 memory 之后,我也无法启动 puppetserver Please help, where i am going wrong.请帮忙,我哪里出错了。

Changed memory to 250m (JAVA_ARGS="-Xms250m -Xmx250m). It worked.将内存更改为 250m (JAVA_ARGS="-Xms250m -Xmx250m)。它起作用了。
May be its 50% of free memory (free -m)可能是它 50% 的空闲内存 (free -m)

free memory was 440 initially.可用内存最初是 440。 i kept 400 in JAVA_ARGS initially.我最初在 JAVA_ARGS 中保留了 400。

I faced the same error.我遇到了同样的错误。 What I did was, deleted the SSL directory in /etc/puppetlabs/puppet/ssl/我所做的是,删除 /etc/puppetlabs/puppet/ssl/ 中的 SSL 目录

When trying to restart the puppetserver, this error was thrown:尝试重新启动 puppetserver 时,抛出了此错误:

Job for puppetserver.service failed because the control process exited with error code. puppetserver.service 的作业失败,因为控制进程退出并显示错误代码。 See "systemctl status puppetserver.service" and "journalctl -xe" for details.有关详细信息,请参阅“systemctl status puppetserver.service”和“journalctl -xe”。

Use this command to regenerate SSL:使用此命令重新生成 SSL:

puppetserver ca setup --config <PATH TO CONFIG FILE>

In my case PATH TO CONFIG FILE WAS: /etc/puppetlabs/puppet/puppet.conf在我的情况下,配置文件的路径是:/etc/puppetlabs/puppet/puppet.conf

Make sure the data specification size is M , if you specified it in mb :如果您在mb中指定数据规范大小,请确保它是M

JAVA_ARGS="-Xms500M -Xmx500M -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 nginx.service失败,因为控制进程退出 - nginx.service failed because the control process exited httpd.service的作业失败 - Job for httpd.service failed 更改服务帐户密码后,Control-M批处理作业开始引发错误 - Control-M batch job started throwing an error after Service account password getting changed 错误说明:-空闲,状态从启动变为启动,使用 SIGTERM 停止所有进程,进程以状态 143 退出 - error saying:- Idling, State changed from up to starting, Stopping all processes with SIGTERM, Process exited with status 143 "发生 PM2 错误 =&gt; 通过信号 [SIGINT] 以代码 [1] 退出" - PM2 error occurred => exited with code [1] via signal [SIGINT] Gunicorn 未开始抛出 gunicorn.service:失败,结果为“退出代码”。 错误 - Gunicorn not starting throwing gunicorn.service: Failed with result 'exit-code'. error C++ 程序无法连接到服务器,因为错误代码 10093 - C++ program cann't connect to server because of error code 10093 Nuxtjs失败:WebSocket握手期间出错:意外的响应代码:500 - Nuxtjs failed: Error during WebSocket handshake: Unexpected response code: 500 通过代码检查Cron作业状态 - Cron Job status check by code tomcat7.service 启动失败 - tomcat7.service failed to start
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM