如何通过vnc远程桌面安装linux下的oracle

教程发布:风哥 教程分类:ITPUX技术网 更新日期:2022-02-12 浏览学习:922

如何通过vnc远程桌面安装linux下的oracle

linux 版本:redhat 企业版 4
在安装包有vnc-server-4.0-8.1.i386.rpm
在操作系统安装完成后一般会自动安装的所以不需要再次安装

1.把vncserver 装在oracle用户下
[root@rac1 user01]# su - oracle
[oracle@rac1 ~]$ pwd
/home/oracle
[oracle@rac1 ~]$ vncserver
You will require a password to access your desktops.
Password: --这里输入密码oracle
Verify: --验证密码oracle
xauth: creating new authority file /home/oracle/.Xauthority
New 'rac1.cn:2 (oracle)' desktop is rac1.cn:2 红色2代表端口号 vnc客户端登录时需要用到
Creating default startup script. /home/oracle/.vnc/xstartup
Starting applications specified in /home/oracle/.vnc/xstartup
Log file is /home/oracle/.vnc/rac1.cn:2.log

2.打开防火墙 用root用户登录
vi /etc/sysconfig/iptables
找到下面语句
A RH-Firewall-1-INPUT -j REJECT --reject-with icmp-host-prohibited
修改为
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 5900:5903 -j ACCEPT
表示端口为5900到5903可以访问
用root身份重新启动防火墙
[root@rac2 ~]# /sbin/service iptables restart
Flushing firewall rules: [ OK ]
Setting chains to policy ACCEPT: filter [ OK ]
Unloading iptables modules: [ OK ]
Applying iptables firewall rules: [ OK ]
默认登录的是twm窗口不好看 需要设置成gnome模式
vi /home/oracle/.vnc/xstartup 如下所示:
#!/bin/sh
# Uncomment the following two lines for normal desktop:
unset SESSION_MANAGER
exec /etc/X11/xinit/xinitrc
startkde &
wq 保存退出
unset 和exec前面的#要去掉
最后一行换成startkde
重新启动VNC server
[oracle@rac1 ~]$ /sbin/service vncserver restart
Shutting down VNC server: [ OK ]
rm: cannot remove `/var/lock/subsys/vncserver': Permission denied
Starting VNC server: [ OK ]
touch: cannot touch `/var/lock/subsys/vncserver': Permission denied

重新启动linux 服务器后
在windows xp 安装vnc for windows 客户端
装完后选择 run vnc viewser
server 栏输入 192.168.1.242:2 就是vncserver 生成的端口号
就ok了 就可以实现远程安装了

本文标签:
网站声明:本文由风哥整理发布,转载请保留此段声明,本站所有内容将不对其使用后果做任何承诺,请读者谨慎使用!
【上一篇】
【下一篇】