Cent OS 7上需要把mongoDB添加到systemd,否则会出现上面的错误

将mongoDB添加到systemd

# vim /usr/lib/systemd/system/mongod.service

[Unit]
Description=mongodb database

[Service]
User=mongod
Group=mongod
Environment="OPTIONS=--quiet -f /etc/mongod.conf"
ExecStart=/usr/bin/mongod $OPTIONS run
PIDFile=/var/run/mongodb/mongod.pid

[Install]
WantedBy=multi-user.target

建立链接
ln -s /usr/lib/systemd/system/mongod.service /etc/systemd/system/multi-user.target.wants/

重新加载systemctl
systemctl daemon-reload

mongod.service: control process exited, code=exited status=1的更多相关文章

  1. CenOS7.1 vncserver@:1.service: control process exited, code=exited status=2

    参考:http://www.cnblogs.com/gaohong/p/4829206.html 报错细节: vncserver@:1.service: control process exited, ...

  2. centOS 7一个解决“network.service: control process exited, code=exited status=1”方法

    今天早上2017-08-04,我打开虚拟机,使用远程工具xshell对虚拟机进行连接,我发现连接不上去,然后我ifconfig,发现找不到ens33了,就剩一个本地回环,看来是我的网络出现了问题,然后 ...

  3. nginx.service: control process exited, code=exited status=1

    安装linux的宝塔面板,结果面板显示nginx和php已经运行了,但是机器系统上并没有运行.记录一次nginx报错,操作步骤看下代码: [root@localhost nginx]# systemc ...

  4. vsftpd.service: Main process exited, code=exited, status=2/INVALIDARGUMENT和vsftpd:500 OOPS: vsftpd: refusing to run with writable root inside chroot ()错误的解决方法

    今天在配置VSFTPD过程中遇到两个错误 1是启动失败,通过 SERVICE VSFTPD STATUS 查看到报错 May 02 16:06:58 debian systemd[1]: Starti ...

  5. centos 7 network.service control process exited

    一.service network restart 出错 问题描述: vmware 12 下centos 7 网络模式,NAT 昨晚作者打算更新自己虚拟机python,发现没网络ping www.ba ...

  6. main process exited, code=exited, status=203/EXEC

    问题描述: Oct :: c_3. systemd[]: Started etcd. Oct :: c_3. systemd[]: Starting etcd... Oct :: c_3. syste ...

  7. (samba启动失败)smb.service: main process exited, code=exited, status=1/FAILURE

    按照指示,前往:journalctl -xe 没什么发现,搜的时候有人说也可以查看 journalctl -r 打出来之后我也看不出什么门道来 又看到有人说 smb 方面可以看看 testparm 我 ...

  8. Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details

    thinkphp 在Apache上配置启用伪静态,重启Apache1 restart 竟然失败了,报错 Job for httpd.service failed because the control ...

  9. Linux 重启网卡失败 Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details.

    linux下重启网卡使用命令 : service network restart 时报错: [root@slave01 hadoop]# service network restart Startin ...

随机推荐

  1. dis集群研究和实践(基于redis 3.0.5) 《转载》

    https://www.cnblogs.com/wxd0108/p/5798498.html 前言 redis 是我们目前大规模使用的缓存中间件,由于它强大高效而又便捷的功能,得到了广泛的使用.现在的 ...

  2. C#6.0新语法

    .自动属性初始化的改进(有用) 原来的用法(声明时无法同时初始化),例如: class MyClass { public int Age { get; set; } public string Nam ...

  3. Skyline TerraExplorer 7.0- 扩展信息树

    Skyline TerraExplorer V7增加了一个扩展信息树的控件TEInformationWindowEx.  该控件能够将TE3DWindowEx窗口里面的对象显示为信息树的方式.TEIn ...

  4. Android View添加删除或隐藏显示的默认动画;

    代码中给控件设置Visibility ? VISIBLE : GONE ;时太生硬,用户体验不好:设置一个Android ViewGroup的默认动画很实用: 给需要添加动画的控件或布局的父布局,记住 ...

  5. LINUX 安装扩展(笔记)

    1.下载扩展包: 网址:http://pecl.php.net/ 2.解压安装包. 3.进入解压好的安装包. 4.使用php中的phpize (扩展模块) 使其生成configure. 5../con ...

  6. 解决导出CSV后在EXCEL打开纯数字前面0丢失问题

    select ip ,concat('="',accountname,'"')select ip ,concat('="',accountname,'"')

  7. dva中roadhog版本升级后带来的问题及解决方法

    从同事手中接手项目之后.npm install 然后npm start的时候.开始报上图的错误.解决方法一(比较 愚蠢)当时找到的解决方法都没有用.然后只能按照报错的路径,从同事那边复制了node_m ...

  8. Python全栈开发记录_第六篇(生成器和迭代器)

    说生成器之前先说一个列表生成式:[x for x in range(10)]   ->[0,1,2....,9]这里x可以为函数(因为对python而言就是一个对象而已),range(10)也可 ...

  9. [python,2018-06-25] 高德纳箭号表示法

    概念 高德纳箭号表示法是种用来表示很大的整数的方法,由高德纳于1976年设计.它的意念来自幂是重复的乘法,乘法是重复的加法. 定义 计算 一个箭头 2↑3=2×2×2=8 2↑4=2×2×2×2=16 ...

  10. 如何解决button,a,input标签自带蓝色边框

    通常我们会设置该标签outline:0;但是我在使用iview自带的button组件的时候,设置无效,经过测试只要设置 :focus{      outline:0; }  即可,方便有效