安裝Oracle時出現如下錯誤
[oracle@localhost database]$ ./runInstaller
Starting Oracle Universal Installer...
Checking installer requirements...
Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2
Passed
All installer requirements met.
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2009-06-07_12-13-22PM. Please wait ...[oracle@localhost database]$ Exception in thread "main" java.lang.InternalError: Can't connect to X11 window server
using 'localhost:0.0' as the value of the DISPLAY variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at sun.awt.X11GraphicsEnvironment.<clinit>(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(Unknown Source)
at java.awt.Window.init(Unknown Source)
at java.awt.Window.<init>(Unknown Source)
at java.awt.Frame.<init>(Unknown Source)
at oracle.ewt.popup.PopupFrame.<init>(Unknown Source)
at oracle.ewt.lwAWT.BufferedFrame.<init>(Unknown Source)
at oracle.sysman.oio.oioc.OiocOneClickInstaller.<init>(OiocOneClickInstaller.java:378)
at oracle.sysman.oio.oioc.OiocOneClickInstaller.main(OiocOneClickInstaller.java:2091)
執行如下命令得以解決,而不是很多人說的export DISPLAY=localhost:0.0, 不知道爲什麼這樣,有誰知道告訴我,[email protected] ,非常感謝
[oracle@localhost database]$ export DISPLAY=:0
[oracle@localhost database]$ su
Password:
[root@localhost database]# xhost + localhost
localhost being added to access control list
PS: xhost + hostname /IP : 指定的host就可以讓Client端能使用當前服務器的X Server,即用服務器的顯示設備做爲終端來輸出。
原文出處:http://blog.csdn.net/furtherchan/article/details/4249207