Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glibc warning and install wheel #11348

Open
busFred opened this issue Mar 19, 2025 · 7 comments
Open

glibc warning and install wheel #11348

busFred opened this issue Mar 19, 2025 · 7 comments
Assignees

Comments

@busFred
Copy link

busFred commented Mar 19, 2025

I'm not sure if this is more of a question or issue but i'm getting warning when importing xgboost.

(tmplafa) ~/Documents/research/afa/template-afa$ python
Python 3.13.2 | packaged by Anaconda, Inc. | (main, Feb  6 2025, 18:56:02) [GCC 11.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import xgboost as xgbst
/home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages/xgboost/core.py:377: FutureWarning: Your system has an old version of glibc (< 2.28). We will stop supporting Linux distros with glibc older than 2.28 after **May 31, 2025**. Please upgrade to a recent Linux distro (with glibc >= 2.28) to use future versions of XGBoost.
Note: You have installed the 'manylinux2014' variant of XGBoost. Certain features such as GPU algorithms or federated learning are not available. To use these features, please upgrade to a recent Linux distro with glibc 2.28+, and install the 'manylinux_2_28' variant.
  warnings.warn(

I followed instruction found on google to check glibc version installed on my system, which is higher (2.39>2.28) than what xgboost consider as old version of glibc.

(tmplafa) ~/Documents/research/afa/template-afa$ ldd --version
ldd (Ubuntu GLIBC 2.39-0ubuntu8.4) 2.39
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.
(tmplafa) ~/Documents/research/afa/template-afa$ strings /usr/lib/x86_64-linux-gnu/libc.so.6|grep GLIBC_
GLIBC_2.2.5
GLIBC_2.2.6
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_2.5
GLIBC_2.6
GLIBC_2.7
GLIBC_2.8
GLIBC_2.9
GLIBC_2.10
GLIBC_2.11
GLIBC_2.12
GLIBC_2.13
GLIBC_2.14
GLIBC_2.15
GLIBC_2.16
GLIBC_2.17
GLIBC_2.18
GLIBC_2.22
GLIBC_2.23
GLIBC_2.24
GLIBC_2.25
GLIBC_2.26
GLIBC_2.27
GLIBC_2.28
GLIBC_2.29
GLIBC_2.30
GLIBC_2.31
GLIBC_2.32
GLIBC_2.33
GLIBC_2.34
GLIBC_2.35
GLIBC_2.36
GLIBC_2.38
GLIBC_2.39
GLIBC_ABI_DT_RELR
GLIBC_PRIVATE
(tmplafa) hungtien@hungtien-T480s-Linux:~/Documents/research/afa/template-afa$ 

I also tried reinstalling xgboost-cpu with pip but it still installs the the manylinux2014 variant.

(tmplafa) ~/Documents/research/afa/template-afa$ pip uninstall xgboost-cpu
Found existing installation: xgboost-cpu 3.0.0
Uninstalling xgboost-cpu-3.0.0:
  Would remove:
    /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages/xgboost/*
    /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages/xgboost_cpu-3.0.0.dist-info/*
    /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages/xgboost_cpu.libs/libgomp-a34b3233.so.1.0.0
Proceed (Y/n)? y
  Successfully uninstalled xgboost-cpu-3.0.0
(tmplafa) ~/Documents/research/afa/template-afa$ pip install xgboost-cpu --no-cache-dir
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Collecting xgboost-cpu
  Downloading xgboost_cpu-3.0.0-py3-none-manylinux2014_x86_64.whl.metadata (2.6 kB)
Requirement already satisfied: numpy in /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages (from xgboost-cpu) (2.1.3)
Requirement already satisfied: scipy in /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages (from xgboost-cpu) (1.15.2)
Downloading xgboost_cpu-3.0.0-py3-none-manylinux2014_x86_64.whl (4.9 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.9/4.9 MB 36.0 MB/s eta 0:00:00
Installing collected packages: xgboost-cpu
Successfully installed xgboost-cpu-3.0.0
@hcho3
Copy link
Collaborator

hcho3 commented Mar 19, 2025

The warning should not be displayed for xgboost-cpu. We will make a new release to remove the warning.

@hcho3 hcho3 self-assigned this Mar 19, 2025
@trivialfis
Copy link
Member

Could you please check:

ls -la ~/anaconda3/envs/tmplafa/x86_64-conda-linux-gnu/sysroot/lib64/libc.so.6

(or something similar) for which glibc it links to? I believe it judges your libc based on the one in conda env instead of the one in the system.

@busFred
Copy link
Author

busFred commented Mar 19, 2025

Could you please check:

ls -la ~/anaconda3/envs/tmplafa/x86_64-conda-linux-gnu/sysroot/lib64/libc.so.6

(or something similar) for which glibc it links to? I believe it judges your libc based on the one in conda env instead of the one in the system.

I don't have [...]/sysroot/lib64 under my conda environment, but the closest thing I could find through doing a search for libc over the entire conda environment directory gives me the following
Image

I also try to look into the content of that libc10.so file:

(tmplafa) ~/Documents/research/afa/template-afa$ ls -la ~/anaconda3/envs/tmplafa/lib/python3.13/site-packages/torch/lib/libc10.so
-rwxrwxr-x 1 hungtien hungtien 1455209 Feb  7 12:35 /home/hungtien/anaconda3/envs/tmplafa/lib/python3.13/site-packages/torch/lib/libc10.so
(tmplafa) ~/Documents/research/afa/template-afa$ strings ~/anaconda3/envs/tmplafa/lib/python3.13/site-packages/torch/lib/libc10.so | grep GLIBC_
memset@@GLIBC_2.2.5
backtrace@@GLIBC_2.2.5
posix_memalign@@GLIBC_2.2.5
close@@GLIBC_2.2.5
abort@@GLIBC_2.2.5
memchr@@GLIBC_2.2.5
pthread_getname_np@@GLIBC_2.12
clock_gettime@@GLIBC_2.17
toupper@@GLIBC_2.2.5
read@@GLIBC_2.2.5
malloc@@GLIBC_2.2.5
sigfillset@@GLIBC_2.2.5
pthread_setname_np@@GLIBC_2.12
strerror_r@@GLIBC_2.2.5
gettext@@GLIBC_2.2.5
unlink@@GLIBC_2.2.5
rmdir@@GLIBC_2.2.5
pthread_cond_timedwait@@GLIBC_2.3.2
__cxa_atexit@@GLIBC_2.2.5
sysconf@@GLIBC_2.2.5
getpid@@GLIBC_2.2.5
backtrace_symbols@@GLIBC_2.2.5
free@@GLIBC_2.2.5
strlen@@GLIBC_2.2.5
pthread_create@@GLIBC_2.2.5
opendir@@GLIBC_2.2.5
mkstemp64@@GLIBC_2.2.5
__cxa_finalize@@GLIBC_2.2.5
__tls_get_addr@@GLIBC_2.3
syscall@@GLIBC_2.2.5
pthread_self@@GLIBC_2.2.5
strerror@@GLIBC_2.2.5
open64@@GLIBC_2.2.5
sigaction@@GLIBC_2.2.5
strtol@@GLIBC_2.2.5
raise@@GLIBC_2.2.5
memmove@@GLIBC_2.2.5
vsnprintf@@GLIBC_2.2.5
setenv@@GLIBC_2.2.5
getenv@@GLIBC_2.2.5
__errno_location@@GLIBC_2.2.5
qsort@@GLIBC_2.2.5
madvise@@GLIBC_2.2.5
isalpha@@GLIBC_2.2.5
__stack_chk_fail@@GLIBC_2.4
strcmp@@GLIBC_2.2.5
tolower@@GLIBC_2.2.5
clog@@GLIBC_2.2.5
pthread_rwlock_rdlock@@GLIBC_2.2.5
pthread_once@@GLIBC_2.2.5
mkdtemp@@GLIBC_2.2.5
memcmp@@GLIBC_2.2.5
calloc@@GLIBC_2.2.5
pthread_rwlock_wrlock@@GLIBC_2.2.5
strncpy@@GLIBC_2.2.5
localtime_r@@GLIBC_2.2.5
dlsym@@GLIBC_2.2.5
stderr@@GLIBC_2.2.5
sigemptyset@@GLIBC_2.2.5
__pthread_key_create@@GLIBC_2.2.5
strtoll@@GLIBC_2.2.5
pthread_rwlock_unlock@@GLIBC_2.2.5
pthread_mutex_lock@@GLIBC_2.2.5
realloc@@GLIBC_2.2.5
perror@@GLIBC_2.2.5
fprintf@@GLIBC_2.2.5
write@@GLIBC_2.2.5
pthread_mutex_unlock@@GLIBC_2.2.5
memcpy@@GLIBC_2.14
open@@GLIBC_2.2.5
strtod@@GLIBC_2.2.5
readdir64@@GLIBC_2.2.5
time@@GLIBC_2.2.5
GLIBC_2.2.5
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.12
GLIBC_2.14
GLIBC_2.4
GLIBC_2.17

BTW, based on the location of libc10.so, it seems to be installed by pytorch

@trivialfis
Copy link
Member

Thank you for sharing, how about conda list | grep "sysroot"?

Here's my version:

$ conda list | grep "sysroot"
sysroot_linux-64          2.28                 h8bc681e_7    conda-forge

@busFred
Copy link
Author

busFred commented Mar 19, 2025

Mine shows nothing... but here is my full conda list

(tmplafa) ~/Documents/research/afa/template-afa$ conda list
# packages in environment at /home/hungtien/anaconda3/envs/tmplafa:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
_openmp_mutex             5.1                       1_gnu  
absl-py                   2.1.0                    pypi_0    pypi
aiohappyeyeballs          2.4.5                    pypi_0    pypi
aiohttp                   3.11.12                  pypi_0    pypi
aiosignal                 1.3.2                    pypi_0    pypi
antlr4-python3-runtime    4.9.3                    pypi_0    pypi
aplr                      10.8.0                   pypi_0    pypi
asttokens                 3.0.0                    pypi_0    pypi
attrs                     25.1.0                   pypi_0    pypi
bleach                    6.2.0                    pypi_0    pypi
blinker                   1.9.0                    pypi_0    pypi
bzip2                     1.0.8                h5eee18b_6  
ca-certificates           2024.12.31           h06a4308_0  
certifi                   2025.1.31                pypi_0    pypi
charset-normalizer        3.4.1                    pypi_0    pypi
click                     8.1.8                    pypi_0    pypi
cloudpickle               3.1.1                    pypi_0    pypi
comm                      0.2.2                    pypi_0    pypi
contourpy                 1.3.1                    pypi_0    pypi
cycler                    0.12.1                   pypi_0    pypi
dash                      2.18.2                   pypi_0    pypi
dash-core-components      2.0.0                    pypi_0    pypi
dash-cytoscape            1.0.2                    pypi_0    pypi
dash-html-components      2.0.0                    pypi_0    pypi
dash-table                5.0.0                    pypi_0    pypi
debugpy                   1.8.12                   pypi_0    pypi
decorator                 5.1.1                    pypi_0    pypi
dill                      0.3.9                    pypi_0    pypi
executing                 2.2.0                    pypi_0    pypi
exp-datasets              0.0.0                    pypi_0    pypi
exp-models                0.0.0                    pypi_0    pypi
expat                     2.6.4                h6a678d5_0  
external                  0.0.0                    pypi_0    pypi
farama-notifications      0.0.4                    pypi_0    pypi
filelock                  3.17.0                   pypi_0    pypi
flask                     3.0.3                    pypi_0    pypi
fonttools                 4.56.0                   pypi_0    pypi
frozenlist                1.5.0                    pypi_0    pypi
fsspec                    2025.2.0                 pypi_0    pypi
gevent                    24.11.1                  pypi_0    pypi
greenlet                  3.1.1                    pypi_0    pypi
grpcio                    1.70.0                   pypi_0    pypi
gymnasium                 1.1.1                    pypi_0    pypi
hydra-core                1.3.2                    pypi_0    pypi
hydra-joblib-launcher     1.2.0                    pypi_0    pypi
hydra-submitit-launcher   1.2.0                    pypi_0    pypi
idna                      3.10                     pypi_0    pypi
imageio                   2.37.0                   pypi_0    pypi
imbalanced-learn          0.13.0                   pypi_0    pypi
importlib-metadata        8.6.1                    pypi_0    pypi
internal                  0.0.0                    pypi_0    pypi
interpret                 0.6.9                    pypi_0    pypi
interpret-core            0.6.9                    pypi_0    pypi
ipykernel                 6.29.5                   pypi_0    pypi
ipython                   8.32.0                   pypi_0    pypi
ipywidgets                8.1.5                    pypi_0    pypi
itsdangerous              2.2.0                    pypi_0    pypi
jedi                      0.19.2                   pypi_0    pypi
jinja2                    3.1.5                    pypi_0    pypi
joblib                    1.4.2                    pypi_0    pypi
jsonpickle                4.0.1                    pypi_0    pypi
jupyter-client            8.6.3                    pypi_0    pypi
jupyter-core              5.7.2                    pypi_0    pypi
jupyterlab-widgets        3.0.13                   pypi_0    pypi
kaggle                    1.7.4.2                  pypi_0    pypi
kiwisolver                1.4.8                    pypi_0    pypi
lazy-loader               0.4                      pypi_0    pypi
ld_impl_linux-64          2.40                 h12ee557_0  
libffi                    3.4.4                h6a678d5_1  
libgcc-ng                 11.2.0               h1234567_1  
libgomp                   11.2.0               h1234567_1  
libmpdec                  4.0.0                h5eee18b_0  
libstdcxx-ng              11.2.0               h1234567_1  
libuuid                   1.41.5               h5eee18b_0  
lightning                 2.5.0.post0              pypi_0    pypi
lightning-utilities       0.12.0                   pypi_0    pypi
llvmlite                  0.44.0                   pypi_0    pypi
markdown                  3.7                      pypi_0    pypi
markupsafe                3.0.2                    pypi_0    pypi
matplotlib                3.10.1                   pypi_0    pypi
matplotlib-inline         0.1.7                    pypi_0    pypi
mpmath                    1.3.0                    pypi_0    pypi
multidict                 6.1.0                    pypi_0    pypi
multiprocess              0.70.17                  pypi_0    pypi
narwhals                  1.25.2                   pypi_0    pypi
ncurses                   6.4                  h6a678d5_0  
nest-asyncio              1.6.0                    pypi_0    pypi
networkx                  3.4.2                    pypi_0    pypi
numba                     0.61.0                   pypi_0    pypi
numpy                     2.1.3                    pypi_0    pypi
nvidia-cublas-cu12        12.4.5.8                 pypi_0    pypi
nvidia-cuda-cupti-cu12    12.4.127                 pypi_0    pypi
nvidia-cuda-nvrtc-cu12    12.4.127                 pypi_0    pypi
nvidia-cuda-runtime-cu12  12.4.127                 pypi_0    pypi
nvidia-cudnn-cu12         9.1.0.70                 pypi_0    pypi
nvidia-cufft-cu12         11.2.1.3                 pypi_0    pypi
nvidia-curand-cu12        10.3.5.147               pypi_0    pypi
nvidia-cusolver-cu12      11.6.1.9                 pypi_0    pypi
nvidia-cusparse-cu12      12.3.1.170               pypi_0    pypi
nvidia-cusparselt-cu12    0.6.2                    pypi_0    pypi
nvidia-nccl-cu12          2.21.5                   pypi_0    pypi
nvidia-nvjitlink-cu12     12.4.127                 pypi_0    pypi
nvidia-nvtx-cu12          12.4.127                 pypi_0    pypi
omegaconf                 2.3.0                    pypi_0    pypi
openssl                   3.0.15               h5eee18b_0  
orjson                    3.10.15                  pypi_0    pypi
packaging                 24.2                     pypi_0    pypi
pandas                    2.2.3                    pypi_0    pypi
parso                     0.8.4                    pypi_0    pypi
pexpect                   4.9.0                    pypi_0    pypi
pillow                    11.1.0                   pypi_0    pypi
pip                       24.2            py313h06a4308_0  
platformdirs              4.3.6                    pypi_0    pypi
plotly                    6.0.0                    pypi_0    pypi
prompt-toolkit            3.0.50                   pypi_0    pypi
propcache                 0.2.1                    pypi_0    pypi
protobuf                  5.29.3                   pypi_0    pypi
psutil                    6.1.1                    pypi_0    pypi
ptyprocess                0.7.0                    pypi_0    pypi
pure-eval                 0.2.3                    pypi_0    pypi
pyarrow                   19.0.1                   pypi_0    pypi
pygments                  2.19.1                   pypi_0    pypi
pygraphviz                1.14                     pypi_0    pypi
pyparsing                 3.2.1                    pypi_0    pypi
python                    3.13.2          hf623796_100_cp313  
python-dateutil           2.9.0.post0              pypi_0    pypi
python-graphviz           0.20.3                   pypi_0    pypi
python-slugify            8.0.4                    pypi_0    pypi
python_abi                3.13                    0_cp313  
pytorch-lightning         2.5.0.post0              pypi_0    pypi
pytz                      2025.1                   pypi_0    pypi
pyvis                     0.3.2                    pypi_0    pypi
pyyaml                    6.0.2                    pypi_0    pypi
pyzmq                     26.2.1                   pypi_0    pypi
readline                  8.2                  h5eee18b_0  
requests                  2.32.3                   pypi_0    pypi
retrying                  1.3.4                    pypi_0    pypi
salib                     1.5.1                    pypi_0    pypi
scikit-image              0.25.2                   pypi_0    pypi
scikit-learn              1.6.1                    pypi_0    pypi
scipy                     1.15.2                   pypi_0    pypi
setuptools                75.8.0          py313h06a4308_0  
shap                      0.46.0                   pypi_0    pypi
six                       1.17.0                   pypi_0    pypi
sklearn-compat            0.1.3                    pypi_0    pypi
slicer                    0.0.8                    pypi_0    pypi
sqlite                    3.45.3               h5eee18b_0  
stack-data                0.6.3                    pypi_0    pypi
standard-imghdr           3.13.0                   pypi_0    pypi
submitit                  1.5.2                    pypi_0    pypi
swig                      4.3.0                    pypi_0    pypi
sympy                     1.13.1                   pypi_0    pypi
tabulate                  0.9.0                    pypi_0    pypi
tensorboard               2.19.0                   pypi_0    pypi
tensorboard-data-server   0.7.2                    pypi_0    pypi
tensordict                0.7.2                    pypi_0    pypi
text-unidecode            1.3                      pypi_0    pypi
threadpoolctl             3.5.0                    pypi_0    pypi
tifffile                  2025.2.18                pypi_0    pypi
tk                        8.6.14               h39e8969_0  
torch                     2.6.0                    pypi_0    pypi
torchmetrics              1.6.3                    pypi_0    pypi
torchrl                   0.7.2                    pypi_0    pypi
torchvision               0.21.0                   pypi_0    pypi
tornado                   6.4.2                    pypi_0    pypi
tqdm                      4.67.1                   pypi_0    pypi
traitlets                 5.14.3                   pypi_0    pypi
triton                    3.2.0                    pypi_0    pypi
typing-extensions         4.12.2                   pypi_0    pypi
tzdata                    2025.1                   pypi_0    pypi
ucimlrepo                 0.0.7                    pypi_0    pypi
urllib3                   2.3.0                    pypi_0    pypi
wcwidth                   0.2.13                   pypi_0    pypi
webencodings              0.5.1                    pypi_0    pypi
werkzeug                  3.0.6                    pypi_0    pypi
wheel                     0.44.0          py313h06a4308_0  
widgetsnbextension        4.0.13                   pypi_0    pypi
xgboost-cpu               3.0.0                    pypi_0    pypi
xz                        5.4.6                h5eee18b_1  
yarl                      1.18.3                   pypi_0    pypi
zipp                      3.21.0                   pypi_0    pypi
zlib                      1.2.13               h5eee18b_1  
zope-event                5.0                      pypi_0    pypi
zope-interface            7.2                      pypi_0    pypi

@trivialfis
Copy link
Member

@hcho3 Do you have any insight? Despite the xgboost-cpu, xgboost itself should not choose the 2014 version. I think that's the more significant issue.

@trivialfis
Copy link
Member

Okay, my bad. Rereading the issue, I see that you are installing xgboost-cpu instead of xgboost. I thought you were installing xgboost and ran into a warning. Then try the xgboost-cpu.

Yes, we should create a patch release to fix that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants