解决[gazebo_gui-3] process has died [pid 2238, exit code 134

执行gazebo时,会闪退,并出现

[gazebo_gui-3] process has died [pid 2238, exit code 134........(略)

尝试了两天,尝试了网上很多方法,包括安装新旧版本gazebo,现在给出两种比较可行的解决方法:
方法一:gazebo启用3D加速选项方面存在一些问题,可从VM设置中禁用设置3D加速选项。禁用该选项后,仿真环境运行会比较缓慢,但可以正常工作。如图所示:
解决[gazebo_gui-3] process has died [pid 2238, exit code 134_第1张图片
方法二:更改SVGA_VGPU10变量:
①先在终端执行

export SVGA_VGPU10=0

然后再执行roslaunch语句,比如我的是

roslaunch ur_gazebo ur3.launch

即可
解决[gazebo_gui-3] process has died [pid 2238, exit code 134_第2张图片

②其实,当更改SVGA_VGPU10变量时,其实只是在告诉系统OpenGL版本,尝试两种选择,然后看看哪个更适合。如果要使用此选项避免每次启动终端时都设置此变量,只需将此命令添加到.bashrc中即可。

export SVGA_VGPU10=0" >> ~/.bashrc

然后正常roslaunch

roslaunch ur_gazebo ur3.launch

解决问题!

你可能感兴趣的:(Ubuntu,ros日常)