<i id='RQVH1'><tr id='RQVH1'><dt id='RQVH1'><q id='RQVH1'><span id='RQVH1'><b id='RQVH1'><form id='RQVH1'><ins id='RQVH1'></ins><ul id='RQVH1'></ul><sub id='RQVH1'></sub></form><legend id='RQVH1'></legend><bdo id='RQVH1'><pre id='RQVH1'><center id='RQVH1'></center></pre></bdo></b><th id='RQVH1'></th></span></q></dt></tr></i><div id='RQVH1'><tfoot id='RQVH1'></tfoot><dl id='RQVH1'><fieldset id='RQVH1'></fieldset></dl></div>

      <small id='RQVH1'></small><noframes id='RQVH1'>

        <legend id='RQVH1'><style id='RQVH1'><dir id='RQVH1'><q id='RQVH1'></q></dir></style></legend>
          <bdo id='RQVH1'></bdo><ul id='RQVH1'></ul>

      1. <tfoot id='RQVH1'></tfoot>
      2. 在 Windows 机器上通过 Ansible 安装 Oracle 客户端 -

        时间:2023-06-06

          <bdo id='yU6dv'></bdo><ul id='yU6dv'></ul>

          • <legend id='yU6dv'><style id='yU6dv'><dir id='yU6dv'><q id='yU6dv'></q></dir></style></legend>

              <tbody id='yU6dv'></tbody>
            <tfoot id='yU6dv'></tfoot>

            1. <i id='yU6dv'><tr id='yU6dv'><dt id='yU6dv'><q id='yU6dv'><span id='yU6dv'><b id='yU6dv'><form id='yU6dv'><ins id='yU6dv'></ins><ul id='yU6dv'></ul><sub id='yU6dv'></sub></form><legend id='yU6dv'></legend><bdo id='yU6dv'><pre id='yU6dv'><center id='yU6dv'></center></pre></bdo></b><th id='yU6dv'></th></span></q></dt></tr></i><div id='yU6dv'><tfoot id='yU6dv'></tfoot><dl id='yU6dv'><fieldset id='yU6dv'></fieldset></dl></div>

              1. <small id='yU6dv'></small><noframes id='yU6dv'>

                  本文介绍了在 Windows 机器上通过 Ansible 安装 Oracle 客户端 - 退出代码 259, 1的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  限时送ChatGPT账号..

                  我正在尝试通过 Ansible 在 Windows Server 2016 上安装 Oracle Client 12c.

                  I'm trying to install Oracle Client 12c on a Windows Server 2016 via Ansible.

                  我尝试了各种安装客户端的选项:

                  I have tried various options to install the client:

                  选项 1

                    - name: "Install Oracle Client"
                    win_command: "C:\\Temp\\Software\\Oracle-Client\\client\\setup.exe -ignoreSysPrereqs -ignorePrereq -waitforcompletion -showProgress -silent -responseFile C:\\Temp\\Software\\Oracle-Client\\client\\response\\client.rsp"
                  

                  我得到的错误代码是:

                  fatal: [windoze]: FAILED! => {
                  "changed": true, 
                  "cmd": "C:\\Temp\\Software\\Oracle-Client\\client\\setup.exe -ignoreSysPrereqs -ignorePrereq -waitforcompletion -showProgress -silent -responseFile C:\\Temp\\Software\\Oracle-Client\\client\\response\\client.rsp", 
                  "delta": "0:00:10.592896", 
                  "end": "2018-11-22 12:34:33.774009", 
                  "msg": "non-zero return code", 
                  "rc": 1, 
                  "start": "2018-11-22 12:34:23.181113", 
                  "stderr": "", 
                  "stderr_lines": [], 
                  "stdout": "\r\n Exit code of OUI process 1=", 
                  "stdout_lines": [
                      "", 
                      " Exit code of OUI process 1="
                  ]
                  

                  }

                  选项 2

                  - name: "Install Oracle Client"
                    win_package:
                      path: C:\Temp\Software\Oracle-Client\client\setup.exe
                      creates_path: C:\app\client_1
                      arguments:
                      - "-silent -noconsole -waitforcompletion -responseFile C:\\Temp\\Software\\Oracle-Client\\client\\response\\client.rsp"
                      state: present
                  

                  我得到的错误是:

                  fatal: [windoze]: FAILED! => {
                  "changed": false, 
                  "exit_code": 1, 
                  "msg": "unexpected rc from install  C:\\Temp\\Software\\Oracle-Client\\client\\setup.exe: see rc, stdout and stderr for more details", 
                  "rc": 1, 
                  "reboot_required": false, 
                  "restart_required": false, 
                  "stderr": "", 
                  "stderr_lines": [], 
                  "stdout": "\r\n Exit code of OUI process 1=", 
                  "stdout_lines": [
                      "", 
                      " Exit code of OUI process 1="
                  ]
                  

                  }

                  选项 3

                  - name: "Install Oracle Client"
                    win_shell: "C:\\Temp\\Software\\Oracle-Client\\client\\setup.exe -silent -waitforcompletion -nowelcome -noconfig -debug -force -responseFile C:\\Temp\\Software\\Oracle-Client\\client\\response\\client.rsp"
                  

                  这次的结果是不同的,其中 RC 为 1,但实际上并没有在服务器上安装任何东西

                  The result is different this time where the RC is 1, but it doesn't actually install anything on the server

                  changed: [windoze] => {
                  "changed": true, 
                  "cmd": "C:\\Temp\\Software\\Oracle-Client\\client\\setup.exe -silent -waitforcompletion -nowelcome -noconfig -debug -force -responseFile C:\\Temp\\Software\\Oracle-Client\\client\\response\\client.rsp", 
                  "delta": "0:00:09.554881", 
                  "end": "2018-11-22 12:51:00.633519", 
                  "rc": 0, 
                  "start": "2018-11-22 12:50:51.078638", 
                  "stderr": "", 
                  "stderr_lines": [], 
                  "stdout": "\r\n Exit code of OUI process 1=", 
                  "stdout_lines": [
                      "", 
                      " Exit code of OUI process 1="
                  ]
                  

                  }

                  上述每个命令都在服务器上手动运行,所以我知道这不是命令本身的问题.似乎在运行安装程序时启动了一个 java 进程,这在通过 Ansible 调用时会导致此问题.有谁知道我如何通过 Ansible 成功安装它?

                  Each of the commands above work manually on the server, so I know that it is not an issue with the commands themselves. It appears that a java process starts when the installer is run which causes this issue when invoked via Ansible. Does anyone know how I can successfully install this via Ansible?

                  推荐答案

                  您需要使用 -waitforcompletion 选项,以获取错误 0.此选项仅支持本地执行(例如 bat).这是有效的:

                  You need use -waitforcompletion option, in order to get error 0. This option support only local execute (for example bat). This is working:

                  就我而言是:

                  - name: Execute bat file
                    script: files/run.bat
                    args:
                      creates: C:\app\oracle
                  

                  运行.bat

                  C:\OracleClient\client32\setup.exe -silent -nowait -noconsole -waitforcompletion -responseFile "C:\OracleClient\client.rsp"
                  

                  这里有更多信息

                  这篇关于在 Windows 机器上通过 Ansible 安装 Oracle 客户端 - 退出代码 259, 1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:尽管在 Ansible 中提升了权限,但仍无法运行脚本 下一篇:如何在ansible中为不同的主机使用另一个任务中的

                  相关文章

                  最新文章

                    <bdo id='r1XOz'></bdo><ul id='r1XOz'></ul>

                  <i id='r1XOz'><tr id='r1XOz'><dt id='r1XOz'><q id='r1XOz'><span id='r1XOz'><b id='r1XOz'><form id='r1XOz'><ins id='r1XOz'></ins><ul id='r1XOz'></ul><sub id='r1XOz'></sub></form><legend id='r1XOz'></legend><bdo id='r1XOz'><pre id='r1XOz'><center id='r1XOz'></center></pre></bdo></b><th id='r1XOz'></th></span></q></dt></tr></i><div id='r1XOz'><tfoot id='r1XOz'></tfoot><dl id='r1XOz'><fieldset id='r1XOz'></fieldset></dl></div>

                    <legend id='r1XOz'><style id='r1XOz'><dir id='r1XOz'><q id='r1XOz'></q></dir></style></legend>

                    <small id='r1XOz'></small><noframes id='r1XOz'>

                    <tfoot id='r1XOz'></tfoot>