mac连接数据库报错,ORA-21561: OID generation failed
解决过程:
打开终端,查看hostname
hostname
发现hostname是local而不是localhost
查看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文件中不一致
修改hostname和hosts保持一致
sudo scutil --set HostName localhost