I am new to the environment and I could not launch the environment successfully in the ubuntu server with multiple nvidia graphics cards. The X-server is inactive. I notice that many people have the same questions with me and someone solved that with vncserver, I tried but it didn't work.
Here is my operation:
I install the environment in the Ubuntu server, and the X-server status is inactive. Then I install vncserver in Ubuntu server and I can use MobaXterm (software in Windows) in my PC to connect it and the screen shows normally, like the following picture:
I test with the gym environment, it works fine:
But it failed when I launched the MineRL environment,
python minerl.py
Traceback (most recent call last):
File “test.py”, line 23, in
hello_world()
File “test.py”, line 6, in hello_world
env = gym.make(‘MineRLNavigateDense-v0’)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/gym/envs/registration.py”, line 156, in make
return registry.make(id, **kwargs)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/gym/envs/registration.py”, line 101, in make
env = spec.make(kwargs)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/gym/envs/registration.py”, line 73, in make
env = cls(_kwargs)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/minerl/env/core.py”, line 133, in init
self.instance = self._get_new_instance(port)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/minerl/env/core.py”, line 155, in _get_new_instance
instance.launch()
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/minerl/env/malmo.py”, line 466, in launch
_check_for_launch_errors(line)
File “/mnt/home/lll/anaconda3/envs/minecraft/lib/python3.6/site-packages/minerl/env/malmo.py”, line 753, in _check_for_launch_errors
"ERROR! MineRL could not detect an X Server, Monitor, or Virtual Monitor! "
RuntimeError: ERROR! MineRL could not detect an X Server, Monitor, or Virtual Monitor!
In order to run minerl environments WITHOUT A HEAD use a software renderer such as ‘xvfb’:
xvfb-run python3
! NOTE: xvfb conflicts with NVIDIA-drivers!
! To run headless MineRL on a system with NVIDIA-drivers, please start a
! vnc server of your choosing and then `export DISPLAY=:<insert ur vnc server #>
If you’re receiving this error and there is a monitor attached, make sure your current displayvariable is set correctly:
DISPLAY=:0 python3
! NOTE: For this to work your account must be logged on the physical monitor.
If none of these steps work, please complain in the discord!
If all else fails, JUST PUT THIS IN A DOCKER CONTAINER! :slight_smile:
I am new to the environment and I could not launch the environment successfully in the ubuntu server with multiple nvidia graphics cards. The X-server is inactive. I notice that many people have the same questions with me and someone solved that with vncserver, I tried but it didn't work.
Here is my operation:
I install the environment in the Ubuntu server, and the X-server status is inactive. Then I install vncserver in Ubuntu server and I can use MobaXterm (software in Windows) in my PC to connect it and the screen shows normally, like the following picture: I test with the gym environment, it works fine: But it failed when I launched the MineRL environment,
Any suggestions will be appreciated!