rviz 分段错误(核心已转储)
rviz Segmentation fault (core dumped)
当我尝试使用 rviz 时,出现错误 "Segmentation fault (core dumped)"。详细信息如下所示。我现在用的是两张显卡,一张GTX-750,一张K40,不知道是不是下面这个问题的原因,以及如何解决。
czhang@kaffe:~$ rosrun rviz rviz -l
[ INFO] [1465022465.168948335]: rviz version 1.11.14
[ INFO] [1465022465.169027675]: compiled against Qt version 4.8.6
[ INFO] [1465022465.169046113]: compiled against OGRE version 1.8.1 (Byatis)
[ INFO] [1465022465.324312645]: Creating resource group General
[ INFO] [1465022465.324429908]: Creating resource group Internal
[ INFO] [1465022465.324496607]: Creating resource group Autodetect
[ INFO] [1465022465.324629864]: SceneManagerFactory for type 'DefaultSceneManager' registered.
[ INFO] [1465022465.324883178]: Registering ResourceManager for type Material
[ INFO] [1465022465.324940378]: Registering ResourceManager for type Mesh
[ INFO] [1465022465.324987032]: Registering ResourceManager for type Skeleton
[ INFO] [1465022465.325053591]: MovableObjectFactory for type 'ParticleSystem' registered.
[ INFO] [1465022465.325103877]: OverlayElementFactory for type Panel registered.
[ INFO] [1465022465.325142848]: OverlayElementFactory for type BorderPanel registered.
[ INFO] [1465022465.325179725]: OverlayElementFactory for type TextArea registered.
[ INFO] [1465022465.325225052]: Registering ResourceManager for type Font
[ INFO] [1465022465.325272474]: ArchiveFactory for archive type FileSystem registered.
[ INFO] [1465022465.325308163]: ArchiveFactory for archive type Zip registered.
[ INFO] [1465022465.325345667]: ArchiveFactory for archive type EmbeddedZip registered.
[ INFO] [1465022465.325379959]: DDS codec registering
[ INFO] [1465022465.325428150]: FreeImage version: 3.15.4
[ INFO] [1465022465.325464467]: This program uses FreeImage, a free, open source image library supporting all common bitmap formats. See http://freeimage.sourceforge.net for details
[ INFO] [1465022465.325678042]: Supported formats: bmp,ico,jpg,jif,jpeg,jpe,jng,koa,iff,lbm,mng,pbm,pbm,pcd,pcx,pgm,pgm,png,ppm,ppm,ras,tga,targa,tif,tiff,wap,wbmp,wbm,psd,cut,xbm,xpm,gif,hdr,g3,sgi,exr,j2k,j2c,jp2,pfm,pct,pict,pic,3fr,arw,bay,bmq,cap,cine,cr2,crw,cs1,dc2,dcr,drf,dsc,dng,erf,fff,ia,iiq,k25,kc2,kdc,mdc,mef,mos,mrw,nef,nrw,orf,pef,ptx,pxn,qtk,raf,raw,rdc,rw2,rwl,rwz,sr2,srf,srw,sti
[ INFO] [1465022465.325735871]: Registering ResourceManager for type HighLevelGpuProgram
[ INFO] [1465022465.325787693]: Registering ResourceManager for type Compositor
[ INFO] [1465022465.326052531]: MovableObjectFactory for type 'Entity' registered.
[ INFO] [1465022465.326105890]: MovableObjectFactory for type 'Light' registered.
[ INFO] [1465022465.326143255]: MovableObjectFactory for type 'BillboardSet' registered.
[ INFO] [1465022465.326182366]: MovableObjectFactory for type 'ManualObject' registered.
[ INFO] [1465022465.326236493]: MovableObjectFactory for type 'BillboardChain' registered.
[ INFO] [1465022465.326289991]: MovableObjectFactory for type 'RibbonTrail' registered.
[ INFO] [1465022465.326421572]: *-*-* OGRE Initialising
[ INFO] [1465022465.326473744]: *-*-* Version 1.8.1 (Byatis)
[ INFO] [1465022465.326532760]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/RenderSystem_GL
[ INFO] [1465022465.329155160]: Installing plugin: GL RenderSystem
[ INFO] [1465022465.329216970]: OpenGL Rendering Subsystem created.
[ INFO] [1465022465.337273651]: Plugin successfully installed
[ INFO] [1465022465.337361511]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/Plugin_OctreeSceneManager
[ INFO] [1465022465.338621448]: Installing plugin: Octree Scene Manager
[ INFO] [1465022465.338670756]: Plugin successfully installed
[ INFO] [1465022465.338705118]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/Plugin_ParticleFX
[ INFO] [1465022465.340275569]: Installing plugin: ParticleFX
[ INFO] [1465022465.340333816]: Particle Emitter Type 'Point' registered
[ INFO] [1465022465.340369435]: Particle Emitter Type 'Box' registered
[ INFO] [1465022465.340403169]: Particle Emitter Type 'Ellipsoid' registered
[ INFO] [1465022465.340455829]: Particle Emitter Type 'Cylinder' registered
[ INFO] [1465022465.340488375]: Particle Emitter Type 'Ring' registered
[ INFO] [1465022465.340527067]: Particle Emitter Type 'HollowEllipsoid' registered
[ INFO] [1465022465.340564223]: Particle Affector Type 'LinearForce' registered
[ INFO] [1465022465.340608572]: Particle Affector Type 'ColourFader' registered
[ INFO] [1465022465.340643143]: Particle Affector Type 'ColourFader2' registered
[ INFO] [1465022465.340681835]: Particle Affector Type 'ColourImage' registered
[ INFO] [1465022465.340714102]: Particle Affector Type 'ColourInterpolator' registered
[ INFO] [1465022465.340749023]: Particle Affector Type 'Scaler' registered
[ INFO] [1465022465.340788204]: Particle Affector Type 'Rotator' registered
[ INFO] [1465022465.340822985]: Particle Affector Type 'DirectionRandomiser' registered
[ INFO] [1465022465.340856509]: Particle Affector Type 'DeflectorPlane' registered
[ INFO] [1465022465.340892197]: Plugin successfully installed
[ INFO] [1465022465.340944159]: CPU Identifier & Features
[ INFO] [1465022465.340975797]: -------------------------
[ INFO] [1465022465.341024966]: * CPU ID: GenuineIntel: Intel(R) Xeon(R) CPU E5-2620 v3 @ 2.40GHz
[ INFO] [1465022465.341055626]: * SSE: yes
[ INFO] [1465022465.341088102]: * SSE2: yes
[ INFO] [1465022465.341115061]: * SSE3: yes
[ INFO] [1465022465.341142159]: * MMX: yes
[ INFO] [1465022465.341169188]: * MMXEXT: yes
[ INFO] [1465022465.341198382]: * 3DNOW: no
[ INFO] [1465022465.341225271]: * 3DNOWEXT: no
[ INFO] [1465022465.341252090]: * CMOV: yes
[ INFO] [1465022465.341279817]: * TSC: yes
[ INFO] [1465022465.341307055]: * FPU: yes
[ INFO] [1465022465.341335899]: * PRO: yes
[ INFO] [1465022465.341365232]: * HT: no
[ INFO] [1465022465.341394426]: -------------------------
[ INFO] [1465022465.341426693]: ******************************
*** Starting GLX Subsystem ***
******************************
[ INFO] [1465022465.341480959]: Registering ResourceManager for type Texture
[ INFO] [1465022465.341578667]: GLRenderSystem::_createRenderWindow "OgreWindow(0)", 1x1 windowed miscParams: FSAA=4 externalGLControl= macAPI=carbon parentWindowHandle=56623105
Segmentation fault (core dumped)
而我运行gdb的时候,其实我对此知之甚少,得到的结果如下。
Starting program: /opt/ros/indigo/lib/rviz/rviz
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[ INFO] [1465023839.514368832]: rviz version 1.11.14
[ INFO] [1465023839.514489727]: compiled against Qt version 4.8.6
[ INFO] [1465023839.514521295]: compiled against OGRE version 1.8.1 (Byatis)
[New Thread 0x7fffdf758700 (LWP 22754)]
[New Thread 0x7fffdef57700 (LWP 22755)]
[New Thread 0x7fffde756700 (LWP 22756)]
[New Thread 0x7fffddf55700 (LWP 22761)]
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb)
我能做什么?我试过将 OGRE_RTT_MODE 更改为 Copy 或 FBO 的方法,但仍然
检查 RVIZ :
默认建议将使用不带参数的 RVIZ,
$ rosrun rviz rviz
如果这也不起作用,可能是因为配置文件错误。所以,删除 ~/.rviz folder
并重新开始。我曾经遇到过同样的问题,这解决了它。
另外,如果您最近更新了您的 ROS 发行版,您可能还需要更新您的显卡。如果没有,请尝试 RVIZ troubleshouting page.
中的解决方案
检查食人魔:
在终端中,运行以下命令:
$ glxgears
这是一个很好的测试,可以查看 OpenGL 是否在 system/driver 级别为您工作。 (你会得到一个漂亮的 window 机械的东西)
还有
$ glxinfo | grep 'OpenGL renderer'
应该不是说'software rasterizer',应该是你显卡的型号
如果这些都不起作用,则意味着您的显卡已过时并且 Ogre 无法正常工作。 (这使得它独立于 Rviz)。
卸载 rviz 并从源代码重建它为我解决了这个问题。
正在删除 rviz:
sudo apt-get remove ros-noetic-rviz
从源构建:
git clone https://github.com/ros-visualization/rviz
catkin build rviz
当我尝试使用 rviz 时,出现错误 "Segmentation fault (core dumped)"。详细信息如下所示。我现在用的是两张显卡,一张GTX-750,一张K40,不知道是不是下面这个问题的原因,以及如何解决。
czhang@kaffe:~$ rosrun rviz rviz -l
[ INFO] [1465022465.168948335]: rviz version 1.11.14
[ INFO] [1465022465.169027675]: compiled against Qt version 4.8.6
[ INFO] [1465022465.169046113]: compiled against OGRE version 1.8.1 (Byatis)
[ INFO] [1465022465.324312645]: Creating resource group General
[ INFO] [1465022465.324429908]: Creating resource group Internal
[ INFO] [1465022465.324496607]: Creating resource group Autodetect
[ INFO] [1465022465.324629864]: SceneManagerFactory for type 'DefaultSceneManager' registered.
[ INFO] [1465022465.324883178]: Registering ResourceManager for type Material
[ INFO] [1465022465.324940378]: Registering ResourceManager for type Mesh
[ INFO] [1465022465.324987032]: Registering ResourceManager for type Skeleton
[ INFO] [1465022465.325053591]: MovableObjectFactory for type 'ParticleSystem' registered.
[ INFO] [1465022465.325103877]: OverlayElementFactory for type Panel registered.
[ INFO] [1465022465.325142848]: OverlayElementFactory for type BorderPanel registered.
[ INFO] [1465022465.325179725]: OverlayElementFactory for type TextArea registered.
[ INFO] [1465022465.325225052]: Registering ResourceManager for type Font
[ INFO] [1465022465.325272474]: ArchiveFactory for archive type FileSystem registered.
[ INFO] [1465022465.325308163]: ArchiveFactory for archive type Zip registered.
[ INFO] [1465022465.325345667]: ArchiveFactory for archive type EmbeddedZip registered.
[ INFO] [1465022465.325379959]: DDS codec registering
[ INFO] [1465022465.325428150]: FreeImage version: 3.15.4
[ INFO] [1465022465.325464467]: This program uses FreeImage, a free, open source image library supporting all common bitmap formats. See http://freeimage.sourceforge.net for details
[ INFO] [1465022465.325678042]: Supported formats: bmp,ico,jpg,jif,jpeg,jpe,jng,koa,iff,lbm,mng,pbm,pbm,pcd,pcx,pgm,pgm,png,ppm,ppm,ras,tga,targa,tif,tiff,wap,wbmp,wbm,psd,cut,xbm,xpm,gif,hdr,g3,sgi,exr,j2k,j2c,jp2,pfm,pct,pict,pic,3fr,arw,bay,bmq,cap,cine,cr2,crw,cs1,dc2,dcr,drf,dsc,dng,erf,fff,ia,iiq,k25,kc2,kdc,mdc,mef,mos,mrw,nef,nrw,orf,pef,ptx,pxn,qtk,raf,raw,rdc,rw2,rwl,rwz,sr2,srf,srw,sti
[ INFO] [1465022465.325735871]: Registering ResourceManager for type HighLevelGpuProgram
[ INFO] [1465022465.325787693]: Registering ResourceManager for type Compositor
[ INFO] [1465022465.326052531]: MovableObjectFactory for type 'Entity' registered.
[ INFO] [1465022465.326105890]: MovableObjectFactory for type 'Light' registered.
[ INFO] [1465022465.326143255]: MovableObjectFactory for type 'BillboardSet' registered.
[ INFO] [1465022465.326182366]: MovableObjectFactory for type 'ManualObject' registered.
[ INFO] [1465022465.326236493]: MovableObjectFactory for type 'BillboardChain' registered.
[ INFO] [1465022465.326289991]: MovableObjectFactory for type 'RibbonTrail' registered.
[ INFO] [1465022465.326421572]: *-*-* OGRE Initialising
[ INFO] [1465022465.326473744]: *-*-* Version 1.8.1 (Byatis)
[ INFO] [1465022465.326532760]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/RenderSystem_GL
[ INFO] [1465022465.329155160]: Installing plugin: GL RenderSystem
[ INFO] [1465022465.329216970]: OpenGL Rendering Subsystem created.
[ INFO] [1465022465.337273651]: Plugin successfully installed
[ INFO] [1465022465.337361511]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/Plugin_OctreeSceneManager
[ INFO] [1465022465.338621448]: Installing plugin: Octree Scene Manager
[ INFO] [1465022465.338670756]: Plugin successfully installed
[ INFO] [1465022465.338705118]: Loading library /usr/lib/x86_64-linux-gnu/OGRE-1.8.0/Plugin_ParticleFX
[ INFO] [1465022465.340275569]: Installing plugin: ParticleFX
[ INFO] [1465022465.340333816]: Particle Emitter Type 'Point' registered
[ INFO] [1465022465.340369435]: Particle Emitter Type 'Box' registered
[ INFO] [1465022465.340403169]: Particle Emitter Type 'Ellipsoid' registered
[ INFO] [1465022465.340455829]: Particle Emitter Type 'Cylinder' registered
[ INFO] [1465022465.340488375]: Particle Emitter Type 'Ring' registered
[ INFO] [1465022465.340527067]: Particle Emitter Type 'HollowEllipsoid' registered
[ INFO] [1465022465.340564223]: Particle Affector Type 'LinearForce' registered
[ INFO] [1465022465.340608572]: Particle Affector Type 'ColourFader' registered
[ INFO] [1465022465.340643143]: Particle Affector Type 'ColourFader2' registered
[ INFO] [1465022465.340681835]: Particle Affector Type 'ColourImage' registered
[ INFO] [1465022465.340714102]: Particle Affector Type 'ColourInterpolator' registered
[ INFO] [1465022465.340749023]: Particle Affector Type 'Scaler' registered
[ INFO] [1465022465.340788204]: Particle Affector Type 'Rotator' registered
[ INFO] [1465022465.340822985]: Particle Affector Type 'DirectionRandomiser' registered
[ INFO] [1465022465.340856509]: Particle Affector Type 'DeflectorPlane' registered
[ INFO] [1465022465.340892197]: Plugin successfully installed
[ INFO] [1465022465.340944159]: CPU Identifier & Features
[ INFO] [1465022465.340975797]: -------------------------
[ INFO] [1465022465.341024966]: * CPU ID: GenuineIntel: Intel(R) Xeon(R) CPU E5-2620 v3 @ 2.40GHz
[ INFO] [1465022465.341055626]: * SSE: yes
[ INFO] [1465022465.341088102]: * SSE2: yes
[ INFO] [1465022465.341115061]: * SSE3: yes
[ INFO] [1465022465.341142159]: * MMX: yes
[ INFO] [1465022465.341169188]: * MMXEXT: yes
[ INFO] [1465022465.341198382]: * 3DNOW: no
[ INFO] [1465022465.341225271]: * 3DNOWEXT: no
[ INFO] [1465022465.341252090]: * CMOV: yes
[ INFO] [1465022465.341279817]: * TSC: yes
[ INFO] [1465022465.341307055]: * FPU: yes
[ INFO] [1465022465.341335899]: * PRO: yes
[ INFO] [1465022465.341365232]: * HT: no
[ INFO] [1465022465.341394426]: -------------------------
[ INFO] [1465022465.341426693]: ******************************
*** Starting GLX Subsystem ***
******************************
[ INFO] [1465022465.341480959]: Registering ResourceManager for type Texture
[ INFO] [1465022465.341578667]: GLRenderSystem::_createRenderWindow "OgreWindow(0)", 1x1 windowed miscParams: FSAA=4 externalGLControl= macAPI=carbon parentWindowHandle=56623105
Segmentation fault (core dumped)
而我运行gdb的时候,其实我对此知之甚少,得到的结果如下。
Starting program: /opt/ros/indigo/lib/rviz/rviz
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[ INFO] [1465023839.514368832]: rviz version 1.11.14
[ INFO] [1465023839.514489727]: compiled against Qt version 4.8.6
[ INFO] [1465023839.514521295]: compiled against OGRE version 1.8.1 (Byatis)
[New Thread 0x7fffdf758700 (LWP 22754)]
[New Thread 0x7fffdef57700 (LWP 22755)]
[New Thread 0x7fffde756700 (LWP 22756)]
[New Thread 0x7fffddf55700 (LWP 22761)]
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb)
我能做什么?我试过将 OGRE_RTT_MODE 更改为 Copy 或 FBO 的方法,但仍然
检查 RVIZ :
默认建议将使用不带参数的 RVIZ,
$ rosrun rviz rviz
如果这也不起作用,可能是因为配置文件错误。所以,删除 ~/.rviz folder
并重新开始。我曾经遇到过同样的问题,这解决了它。
另外,如果您最近更新了您的 ROS 发行版,您可能还需要更新您的显卡。如果没有,请尝试 RVIZ troubleshouting page.
中的解决方案检查食人魔:
在终端中,运行以下命令:
$ glxgears
这是一个很好的测试,可以查看 OpenGL 是否在 system/driver 级别为您工作。 (你会得到一个漂亮的 window 机械的东西)
还有
$ glxinfo | grep 'OpenGL renderer'
应该不是说'software rasterizer',应该是你显卡的型号
如果这些都不起作用,则意味着您的显卡已过时并且 Ogre 无法正常工作。 (这使得它独立于 Rviz)。
卸载 rviz 并从源代码重建它为我解决了这个问题。
正在删除 rviz:
sudo apt-get remove ros-noetic-rviz
从源构建:
git clone https://github.com/ros-visualization/rviz
catkin build rviz