【问题标题】:Redhat Server oracle-rdbms.service Startup ErrorRedhat 服务器 oracle-rdbms.service 启动错误
【发布时间】:2018-10-27 01:48:42
【问题描述】:

我正在尝试创建一个服务文件,该文件将允许我在重新启动时自动启动我的 Oracle 12C 数据库和侦听器。我编写了包含以下内容的服务文件:

# /etc/systemd/system/oracle-rdbms.service

# Invoking Oracle scripts to start/shutdown Instances defined in /etc/oratab

# and starts Listener

[Unit]

Description=Oracle Database(s) and Listener

Requires=network.target

[Service]

Type=forking

Restart=no

ExecStart=/u01/app/oracle/product/12.2.0/dbhome_1/bin/dbstart /u01/app/oracle/product/12.2.0/dbhome_1/

ExecStop=/u01/app/oracle/product/12.2.0/dbhome_1/bin/dbshut /u01/app/oracle/product/12.2.0/dbhome_1/

User=oracle

[Install]

WantedBy=multi-user.target

当我启用服务并检查状态时,我收到以下错误:

● oracle-rdbms.service - Oracle Database(s) and Listener
   Loaded: loaded (/etc/systemd/system/oracle-rdbms.service; enabled; vendor preset: disabled)
   Active: inactive (dead) since Mon 2018-10-22 11:45:02 EDT; 1 day 23h ago
  Process: 1377 ExecStop=/u01/app/oracle/product/12.2.0/dbhome_1/bin/dbshut /u01/app/oracle/product/12.2.0/dbhome_1 (code=exited, status=0/SUCCESS)
  Process: 615 ExecStart=/u01/app/oracle/product/12.2.0/dbhome_1/bin/dbstart /u01/app/oracle/product/12.2.0/dbhome_1 (code=exited, status=0/SUCCESS)

Oct 22 11:45:00 oracle-dev dbstart[615]: /u01/app/oracle/product/12.2.0/dbhome_1/bin/dbstart: line 94: /u01/app/oracle/product/12.2.0/dbhome_1/listener.log: Permission denied
Oct 22 11:45:02 oracle-dev dbstart[615]: touch: cannot touch ‘/u01/app/oracle/product/12.2.0/dbhome_1/startup.log’: Permission denied
Oct 22 11:45:02 oracle-dev dbstart[615]: chmod: changing permissions of ‘/u01/app/oracle/product/12.2.0/dbhome_1/startup.log’: Operation not permitted
Oct 22 11:45:02 oracle-dev dbstart[615]: Processing Database instance "orcl": log file /u01/app/oracle/product/12.2.0/dbhome_1/startup.log
Oct 22 11:45:02 oracle-dev dbstart[615]: /u01/app/oracle/product/12.2.0/dbhome_1/bin/dbstart: line 346: /u01/app/oracle/product/12.2.0/dbhome_1/startup.log: Permission denied
Oct 22 11:45:02 oracle-dev dbshut[1377]: /u01/app/oracle/product/12.2.0/dbhome_1/bin/dbshut: line 63: /u01/app/oracle/product/12.2.0/dbhome_1/listener.log: Permission denied
Oct 22 11:45:02 oracle-dev dbshut[1377]: /u01/app/oracle/product/12.2.0/dbhome_1/bin/dbshut: line 64: /u01/app/oracle/product/12.2.0/dbhome_1/listener.log: Permission denied
Oct 22 11:45:02 oracle-dev dbshut[1377]: Processing Database instance "orcl": log file /u01/app/oracle/product/12.2.0/dbhome_1/shutdown.log
Oct 22 11:45:02 oracle-dev dbshut[1377]: /u01/app/oracle/product/12.2.0/dbhome_1/bin/dbshut: line 160: /u01/app/oracle/product/12.2.0/dbhome_1/shutdown.log: Permission denied
Oct 22 11:45:02 oracle-dev systemd[1]: Started Oracle Database(s) and Listener.

我以 root 身份登录,但仍然不确定问题出在哪里。谢谢

【问题讨论】:

    标签: sql database oracle unix redhat


    【解决方案1】:

    您的 startup.log 和 listerner.log 没有设置正确的权限。对这两个文件使用chmod 命令以获得适当的权限,它应该可以工作

    【讨论】:

      猜你喜欢
      • 2019-04-20
      • 2016-02-16
      • 2022-01-13
      • 1970-01-01
      • 2019-02-26
      • 2017-06-14
      • 2012-03-05
      • 2013-04-21
      • 1970-01-01
      相关资源
      最近更新 更多