You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

CentOS7.9新Anaconda3环境安装Geopandas遇UnsatisfiableError求助

解决CentOS 7.9下Anaconda安装Geopandas的glibc冲突问题

问题场景

CentOS 7.9系统,新安装Anaconda3(conda 4.13.0),执行conda install geopandas时触发UnsatisfiableError,核心冲突是系统自带的glibc 2.17与geopandas依赖的高版本libgcc-ng不兼容。具体报错如下:

$conda install geopandas
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment:
Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort. failed

UnsatisfiableError: The following specifications were found to be incompatible with each other:

Output in format: Requested package -> Available versionsThe following specifications were found to be incompatible with your system:

  • feature:/linux-64::__glibc==2.17=0
  • python=3.9 -> libgcc-ng[version='>=7.5.0'] -> __glibc[version='>=2.17']

Your installed version is: 2.17

可行解决方案

  • 创建低Python版本的虚拟环境
    CentOS7的glibc 2.17无法满足Python3.9依赖的高版本libgcc-ng,切换到Python3.8或3.7版本可规避冲突:

    1. 创建虚拟环境:conda create -n geo_env python=3.8
    2. 激活环境:conda activate geo_env
    3. 安装geopandas:conda install geopandas
  • 使用conda-forge源安装兼容版本
    conda-forge源提供更多兼容旧系统的包版本,指定与glibc2.17匹配的geopandas版本:

    1. 添加conda-forge通道并设置优先级:
      conda config --add channels conda-forge
      conda config --set channel_priority strict
      
    2. 安装兼容版本:conda install geopandas=0.10.2
  • 混合conda+pip安装
    先用conda安装兼容的底层依赖,再用pip安装geopandas:

    1. 安装基础依赖:conda install gdal=3.0.4 shapely=1.7.1 fiona=1.8.20 pyproj=3.0.1
    2. pip安装geopandas:pip install geopandas

内容的提问来源于stack exchange,提问作者ebeb

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.22 21:36:25