Trying to get firefox running on CentOS 6 minimal iso - can't open display
Try doing this:
$ export DISPLAY=10.0.5.52:0
Then run Firefox again. Also be sure to run xhost +
on the host 10.0.5.52 so that it's able to accept X applications being "sent" to it from other servers. This method is considered poor from a security stand point but is perfectly fine to use to confirm things are working properly. With that working, spend a bit more time considering your security posture in this use case and do something a bit more explicit using xhost +someremoteserver
instead.
Also you could use ssh
to tunnel the X application instead of using xhost
. There's typically a bit of a performance hit but it's often tolerable and worth it in my opinion.
$ ssh -X someremoteserver firefox
excerpt from ssh man page
-X Enables X11 forwarding. This can also be specified on a per-host
basis in a configuration file.
Related videos on Youtube
Jazzmine
Updated on September 18, 2022Comments
-
Jazzmine over 1 year
I've got minimal CentOS 6 running on an Oracle VirtualBox on a Mac. I'm trying to get Firefox up and running so I can download some web files into the VM.
I installed Firefox (
yum --enablerepo=remi install firefox
). I also installed Xserver (yum install xorg-x11-server-Xvfb
) as I wasn't sure if it was included in the minimal OS install.I then
export DISPLAY=10.0.5.52
and then tried to startfirefox
but it said:Error: can't open display: 10.0.5.52.
What do I need to do to get
firefox
to display?-
Mark Plotnick almost 10 yearsDo you want Firefox to place its windows on the Mac or inside the CentOS window?
-
debal over 7 yearswhy not download files using
wget
-
MikeA over 5 yearsXvfb is a virtual frame buffer and is not going to help you. wget/curl is your best bet if you want to stick as close as you can to the minimal package group you installed initially.
-
-
slm almost 10 years@Jazzmine - you have to run the command
xhost +
on 10.0.5.52 as well. The permission denied is the other server disallowing the Firefox window from being sent. -
Jazzmine almost 10 yearsOk, I just ran xhost + on the guest (VM) terminal and it automatically responded with xhost: Unable to open display "10.0.5.52:0"
-
Jazzmine almost 10 yearsAnd a little bit more info: i got my ip address from the VM's ifconfig command and selected the inet ip address. Sound good?
-
slm almost 10 years@Jazzmine - you ran
xhost +
on the host with the actual desktop, right?