This morning at work when trying to log on to my computer I noticed not my username on login screen but the "admin". Well network IT guys were doing their job setting up their stuff. I changed login to my name and logged in successfully. All was fine until I tried to connect to my local Oracle XE database from my PHP application I was developing. Connection to Oracle on my Windows machine failed with error TNS:no listener.

What settings needs to be adjusted in Oracle XE after changing computer name on Windows.

tested to connect to Oracle in CMD using $ sqlplus - all good so database itself was running. So it must be just the listener, which is a separate process that runs on the database server computer, receives incoming client connection requests and manages the traffic of these requests to the database server. I tested listener then $ lsnrctl - tried commands status, start, something was not right ... then I realised the network IT guys must have changed something. Wait, I see, they changed my computer name from VLAD-PC to PC05.

That's it. Computer name is set as HOST in two Oracle config files: tnsnames.ora and listener.ora located somewhere like: C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN.

Edit both files (run notepad as administrator) and replace old computer name by new one (in my case VLAD-PC in my case by PC05).

Restart Oracle XE - from Start menu for Oracle Express Edition Start Stop Database and Start Database.

Luckily I had this experience before so fixing did not take long time but still took me some time to find out which files needs to be fixed. Finally I do have this blog which helps me next time and hope helps others too.

TNS:no listener error in Oracle XE after changing computer name的更多相关文章

  1. TNS-12541: TNS:no listener TNS-12560: TNS:protocol adapter error TNS-00511: No listener Linux Error:

    今天是2014-06-17.遇到一个很奇怪的问题,可能之前測试改动监听的原因,导致监听启动后自己主动关闭,特此记录一下整个处理过程, 监听配置文件信息例如以下: [oracle@dg1 admin]$ ...

  2. oracle ORA-12514: TNS: no listener 解决方案

    服务端:oracle 11g 客户端: pl/sql 问题描述: 用客户端 pl/sql 连接登录的时候,提示 "ORA-12514: TNS: no listener". 在服务 ...

  3. 修改Oracle XE Listener 占用的1521、8080端口

    修改Oracle XE Listener 占用的1521.8080端口今天在帮开发人员Demon安装oracleXE时,有这么一段提示: [sql]   Destination Folder: D:\ ...

  4. Oracle ORA-12541:TNS:no listener错误解决方法 (转)

    前天装好的Oracle,昨天突然不好用了,从Oracle的错误提示来看,是说TNS:no listener ,估计是某种服务没有启动,打开windows管理工具->服务,一看,有一个Oracle ...

  5. 登录oracle ORA-12541: TNS:no listener报错

    初次安装Oracle是通过VMware在虚拟机上安装的,安装Oracle过程,解锁了两个用户,分别是Scott和HR,也设置了密码,安装完成后输入sqlplus scott/admin123(scot ...

  6. oracle plsql 无法连接 报 ORA-12560: TNS:protocol adapter error

    ORA-12560: TNS:protocol adapter error 添加一个环境变量,名为TNS_ADMIN,值为 tnsnames.ora 文件所在路径.比如我的本机为:D:/instant ...

  7. TNS-12541: TNS:no listener TNS-12560 TNS-00511: No listener

        为了测试需要,系统管理员帮忙将一台ORACLE数据库服务器克隆到虚拟机上,我上去删除了root.oracle.tomcat账号下的crontab定时作业,然后启动了ORACLE数据库实例,删除 ...

  8. 启动监听报错:TNS-12537: TNS:connection closed TNS-12560: TNS:protocol adapter error TNS-00507: Connection closed Linux Error: 29: Illegal seek

    启动监听程序报错: 说明:在rhel5.8上安装完成oracle11g数据库后,使用netca创建完监听,启动监听时报错.还未使用dbca创建实例. [oracle@rusky-oracle11g ~ ...

  9. centos7.3上安装oracle xe 11g

    oracle -11g-xe是数据库是免费版本,支持标准版的大部分功能.oracle XE版本也称快捷版本.是个个人学习,熟悉oracle的简化版. oracle XE做为免费的Oracle数据库版本 ...

随机推荐

  1. vue spn如何做seo优化

    vue spn如何做seo优化 突然来了一个需求,对已有的项目做SEO优化,WHAT? 总所周知,spn对seo不够优化,因而官方考虑到直接使用ssr 一个不算解决办法的办法prerender-spa ...

  2. 050——VUE中使用js库控制vue过渡动作

    <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...

  3. 升级OPENSSH 和 OPENSSL

    升级OPENSSH 和 OPENSSL   首先安装telnet服务,防止在操作过程中导致ssh远程中断   # 安装Telnetyum install telnet-server -y chkcon ...

  4. ISE创建Microblaze软核(三)

    第七步 进入SDK开发环境 编译完成后弹出如下对话框,选择SDK的工作目录.在MicroblazeTutor中创建一个Workspace文件夹,并选择该文件夹为SDK的工作目录. 进入SDK主界面. ...

  5. iOS笔记之ScrollView

    ScrollView三个基本的要理解的属性: contentSize The size of the content view.所以很好理解,contentSize也就是scrollView可滚动的区 ...

  6. Beta阶段第2周/共2周 Scrum立会报告+燃尽图 12

    作业要求[https://edu.cnblogs.com/campus/nenu/2018fall/homework/2411] 版本控制:https://git.coding.net/liuyy08 ...

  7. nginx配置文件的性能优化

    1.nginx进程数,建议按照cpu数目来指定,一般跟cpu核数相同或为它的倍数.worker_processes 8; 2.为每个进程分配cpu,上例中将8个进程分配到8个cpu,当然可以写多个,或 ...

  8. Python3.x datetime模块

    1.时间间隔(timedelta) 指定时间长度之间计算差值 #!/usr/bin/env python __author__ = 'realtiger' """ @ve ...

  9. PAT 1021 个位数统计 C语言

    1021. 个位数统计 (15) 给定一个k位整数N = dk-1*10k-1 + ... + d1*101 + d0 (0<=di<=9, i=0,...,k-1, dk-1>0) ...

  10. 后端渲染html、前端模板渲染html,jquery的html

    作者:赵魏璇链接:https://www.zhihu.com/question/28725977/answer/116177149来源:知乎著作权归作者所有.商业转载请联系作者获得授权,非商业转载请注 ...