zoukankan      html  css  js  c++  java
  • centos 7安装rac 11gR2时运行root.sh报错找不到ohas服务(ohasd failed to start)

    单独在linux 7中为ohasd设置一个服务。
    步骤如下
    1. 创建服务ohas.service的服务文件并赋予权限

    1 touch /usr/lib/systemd/system/ohas.service
    2 chmod 777 /usr/lib/systemd/system/ohas.service



    2. 往ohas.service服务文件添加启动ohasd的相关信息

    复制代码
     1  vi /usr/lib/systemd/system/ohas.service
     2 [Unit]
     3 Description=Oracle High Availability Services
     4 After=syslog.target
     5 
     6 [Service]
     7 ExecStart=/etc/init.d/init.ohasd run >/dev/null 2>&1 Type=simple
     8 Restart=always
     9 
    10 [Install]
    11 WantedBy=multi-user.target
    复制代码



    以上​部分的内容添加到文件里面

    3. 加载,启动服务

    1 重新加载守护进程
    2 systemctl daemon-reload
    3 设置守护进程自动启动
    4 systemctl enable ohas.service
    5 手工启动ohas服务
    6 systemctl start ohas.service



    复制代码
    1 4. 重新运行root.sh脚本
    2 sh root.sh
    3 报错消失
    4 
    5 5:查看ohas服务状态
    6 systemctl status ohas.service
    7 可以看到ohasd已经处于running的状态
    复制代码
  • 相关阅读:
    1066 Bash 游戏
    1070 Bash 游戏 V4
    codevs 2928 你缺什么
    分块、线段树练习
    Father Christmas flymouse
    codevs 2494 Vani和Cl2捉迷藏
    codevs 2144 砝码称重2
    国王游戏
    codevs 1664 清凉冷水
    2015ACM/ICPC亚洲区沈阳站 Pagodas
  • 原文地址:https://www.cnblogs.com/shujuyr/p/13131451.html
Copyright © 2011-2022 走看看