mac连接数据库报错,ORA-21561OID generation failed


mac连接数据库报错,ORA-21561: OID generation failed

解决过程:

  1. 打开终端,查看hostname

    hostname

    发现hostname是local而不是localhost

  2. 查看hosts文件

    cd /etc
    open hosts

    内容为:

    ##
    # Host Database
    #
    # localhost is used to configure the loopback interface
    # when the system is booting.  Do not change this entry.
    ##
    127.0.0.1	localhost
    255.255.255.255	broadcasthost
    ::1             localhost
    # Added by Docker Desktop
    # To allow the same kube context to work on the host and the container:
    127.0.0.1 kubernetes.docker.internal
    # End of section

    hostname和hosts文件中不一致

  3. 修改hostname和hosts保持一致

    sudo scutil --set HostName localhost

文章作者: 海东青
版权声明: 本博客所有文章除特別声明外,均采用 CC BY 4.0 许可协议。转载请注明来源 海东青 !
  目录