My gradio space log has this error:
/lib/x86_64-linux-gnu/libm.so.6: version
GLIBC_2.29’ not found `
I use command strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC
:
GLIBC_2.2.5
GLIBC_2.4
GLIBC_2.15
GLIBC_2.18
GLIBC_2.23
GLIBC_2.24
GLIBC_2.25
GLIBC_2.26
GLIBC_2.27
GLIBC_2.28
GLIBC_PRIVATE
cause I couldn’t use sudo in hf space, build & install is impossible. so how to upgrade GLIBC?
hu @tumuyan can you share your Space? Another option is to setup your Space using Docker Docker Spaces
the repo is this RealSR - a Hugging Face Space by tumuyan
I try to build a docker, but it has another problem.
https://huggingface.co/spaces/tumuyan/docker-test2
Runtime error
launch timed out, space was not healthy after 30 min
Container logs:
Matplotlib created a temporary config/cache directory at /tmp/matplotlib-s31ufp1x because the default path (/.config/matplotlib) is not a writable directory; it is highly recommended to set the MPLCONFIGDIR environment variable to a writable directory, in particular to speed up the import of Matplotlib and to better support multiprocessing.
sr_name ['all', 'realcugan', 'realsr', 'waifu2x', 'realesrgan']
Running on local URL: http://127.0.0.1:7860
To create a public link, set `share=True` in `launch()`.
hi @tumuyan,
I can’t access your private Space, however it looks like your Dockerfile is missing a step to give writing permission to the running user.
You can read more about it here and see a full example here
Example:
FROM python:3.9
WORKDIR /code
COPY ./requirements.txt /code/requirements.txt
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
# ------ Add user and set permissions
RUN useradd -m -u 1000 user
USER user
ENV HOME=/home/user \
PATH=/home/user/.local/bin:$PATH
WORKDIR $HOME/app
COPY --chown=user . $HOME/app
# -----------
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
sorry, I set it to public now.
it is forked from
Docker Test - a Hugging Face Space by misza222 but it doesn’t have Add user steps.
Also the log shows gradio App is launched, but hf space shows it is building
hi @tumuyan I’ve sent you a PR tumuyan/docker-test2 · fix Dockerfile and app launch
Two issues, one was the above and the other was running app.launch()
on Gradio by default it launchs the app on 127.0.0.1
but internally on our Spaces you need to bind it to 0.0.0.0
.
thanks for your reply and pr.
it works now
1 Like