祝大家新年快乐,有任何问题可与我联系:
在使用oracle的dbca向导装数据库的时候,到最后一步提示“ora-12532 tns:invalid argument”错误,重试了好几次都没成功。
从网上找到的解决方法大部分都说与防火墙有关,要么就是停掉防火墙,要么就是设置权限,如:
1、停掉防火墙
service iptables stop
2、添加防火墙配置
vi /etc/sysconfig/iptables
-A INPUT -p tcp -m state --state NEW -m tcp --dport 1521 -j ACCEPT
:wq
重启防火墙
service iptables restart
保存配置,以便linux重启后依然有效
service iptables save
但是以上方法对我都无效(我也是无语了,为了这个弄了快一天的时间),最后终于在stackoverflow(https://stackoverflow.com/questions/4646752/ora-12532-tnsinvalid-argument)上找到了答案:
Likely causes:
Invalid TNS names configuration (check the tnsnames.ora files)
Prolematic characters in the password (in particular the @ sign can cause problems)
Too strict firewall rules (unable to connect to port 1521)
看到第二点突然明白了,我密码中有特殊字符@,修改密码后一切OK。
特此记录下,希望能为大家节省宝贵的时间。
~谢谢打赏~手机请长按图片~
赞 赏