USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT
root pts/1 192.168.91.1 23:08 34:10 1.61s 1.56s -bash
root :0 - 23:49 ?xdm? 2:49 0.58s /usr/bin/gnome-session
root pts/2 192.168.91.1 05:14 1.00s 0.15s 0.11s w
[root@localhost database]# xhost +
access control disabled, clients can connect from any host
[root@localhost database]# export DISPLAY=192.168.91.1
[root@localhost database]# su - oracle
[oracle@localhost ~]$ cd /oraapp/database/
oracle003
安装配置创建数据库: Linux redhat5.5下安装oracle 11g:http://blog.csdn.net/yakson/article/details/9012129 创建数据库:dbca 创建监听:netca 开启EM:emctl start dbconsole 查看监听情况:lsnrctl status 开启监听:lsnrctl start
注意事项: 1.
【ERROR】while loading shared libraries: /u01/app/oracle/product/11.2.0/lib/libclntsh.so.11.1: cannot问题: [oracle@mydb]$ lsnrctl status lsnrctl: error while loading shared libraries: /u01/app/oracle/product/11.2.0/lib/libclntsh.so.11.1: cannot restore segment prot after reloc: Permission denied 解答: 什么原因导致这些错误呢?原凶就是在安装LINUX时开启了SELinux,记得关闭SELinux 解决方法: (1)查看selinux的状态为Enforcing模式(setenforce 1设置SELinux 成为Enforcing模式,即开启SElinux) [root@mydb]# getenforce Enforcing (2)setenforce 0 设置SELinux 成为permissive模式(即临时关闭SElinux) [root@mydb]# setenforce 0 (3)查看selinux的状态为Permissive模式(setenforce 0设置SELinux 成为Permissive模式) [root@mydb]# getenforce Permissive 5、查看Selinux的配置文件是否修改 [root@mydb bin]# vi /etc/sysconfig/selinux # This file controls the state of SELinux on the system. # SELINUX= can take one of these three values: # enforcing - SELinux security policy is enforced. # permissive - SELinux prints warnings instead of enforcing. # disabled - SELinux is fully disabled. SELINUX=disabled # SELINUXTYPE= type of policy in use. Possible values are: # targeted - Only targeted network daemons are protected. # strict - Full SELinux protection. SELINUXTYPE=targeted注意:
|
2.
| linux下如何关闭防火墙?如何查看防火墙当前的状态 http://blog.csdn.net/liqfyiyi/article/details/7698032 从配置菜单关闭防火墙是不起作用的,索性在安装的时候就不要装防火墙 查看防火墙状态: /etc/init.d/iptables status 暂时关闭防火墙: /etc/init.d/iptables stop 禁止防火墙在系统启动时启动 /sbin/chkconfig --level 2345 iptables off 重启iptables: /etc/init.d/iptables restart 题外话: BT或者骡子速度慢用不着关防火墙,只要把相应端口开放就可以了 在文件 /etc/sysconfig/iptables 在系统原始配置的:RH-Firewall-1-INPUT规则链增加类似这样的行: -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 39764 -j ACCEPT -A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 39764 -j ACCEPT 如果发现原有-j REJECT一类的语句,上面两句要放在它的前面 重启后生效 开启: chkconfig iptables on 关闭: chkconfig iptables off 或者 /sbin/chkconfig --level 2345 iptables off 2) 即时生效,重启后失效 service 方式 开启: service iptables start 关闭: service iptables stop iptables方式 查看防火墙状态: /etc/init.d/iptables status 暂时关闭防火墙: /etc/init.d/iptables stop 重启iptables: /etc/init.d/iptables restart |
3.
| 让listener能够识别出数据库: 1. sqlplus /as sysdba 2. alter system register 3. lsnrctl start 4. lsnrctl status |
4. 通过浏览器链接不到EM
| http: nmehl_connect_internal: connect failed to (localhost.localdomain:1158) 今天打开oracle em后发现无法使用IE浏览器登录,emctl 进入日志后,发现emdctl.trc文件报以下警告信息: 2013-07-24 09:46:40,320 Thread-4124116736 WARN http: nmehl_connect_internal: connect failed to (vmware2:1158): Connection refu |