Skip to content
New issue

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

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

Already on GitHub? # to your account

Error starting userland proxy: listen tcp4 0.0.0.0:5432: bind: address already in use #1905

Open
dentroai opened this issue Jan 30, 2025 · 1 comment

Comments

@dentroai
Copy link

Describe the bug
Trying to run r2r locally with r2r serve --docker --full inside a virtual environment.
It pulls all containers, but then fails:

r2r serve --docker --full
Warning: encountered ImportError: `No module named 'litellm'`, likely due to core dependencies not being installed. This will not affect your use of SDK, but use of `r2r serve` may not be available.
Spinning up an R2R deployment...
Running on 0.0.0.0:7272, with docker=True
Running the full R2R setup which includes `Hatchet` and `Unstructured.io`.
Using image: ragtoriches/prod:3.3.31
Warning: Docker Compose version 2.23.3 is outdated. Please upgrade to version 2.25.0 or higher.
Pulling Docker images...
Calling `docker compose -f /home/dachsteinhustler/magic/research/r2r/.venv/lib/python3.12/site-packages/cli/utils/../../r2r/compose.full.yaml --project-name r2r-full --profile postgres pull`
WARN[0000] The "HUGGINGFACE_API_KEY" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_CLIENT_ID" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_CLIENT_SECRET" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_REDIRECT_URI" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_CLIENT_ID" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_CLIENT_SECRET" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_REDIRECT_URI" variable is not set. Defaulting to a blank string. 
WARN[0000] The "SERPER_API_KEY" variable is not set. Defaulting to a blank string. 
WARN[0000] The "SENDGRID_API_KEY" variable is not set. Defaulting to a blank string. 
[+] Pulling 13/13
 ✔ setup-token Skipped - Image is already being pulled by hatchet-setup-config                                                                   0.0s 
 ✔ hatchet-postgres Skipped - Image is already being pulled by hatchet-create-db                                                                 0.0s 
 ✔ hatchet-create-db Pulled                                                                                                                      1.7s 
 ✔ postgres Pulled                                                                                                                               2.1s 
 ✔ hatchet-dashboard Pulled                                                                                                                      1.1s 
 ✔ hatchet-migration Pulled                                                                                                                      1.1s 
 ✔ unstructured Pulled                                                                                                                           2.1s 
 ✔ r2r-dashboard Pulled                                                                                                                          2.1s 
 ✔ r2r Pulled                                                                                                                                    2.0s 
 ✔ graph_clustering Pulled                                                                                                                       1.9s 
 ✔ hatchet-rabbitmq Pulled                                                                                                                       2.0s 
 ✔ hatchet-engine Pulled                                                                                                                         1.1s 
 ✔ hatchet-setup-config Pulled                                                                                                                   1.2s 
Starting Docker Compose setup...
Calling `docker compose -f /home/dachsteinhustler/magic/research/r2r/.venv/lib/python3.12/site-packages/cli/utils/../../r2r/compose.full.yaml --project-name r2r-full --profile postgres up -d`
WARN[0000] The "HUGGINGFACE_API_KEY" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_CLIENT_ID" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_CLIENT_SECRET" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GOOGLE_REDIRECT_URI" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_CLIENT_ID" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_CLIENT_SECRET" variable is not set. Defaulting to a blank string. 
WARN[0000] The "GITHUB_REDIRECT_URI" variable is not set. Defaulting to a blank string. 
WARN[0000] The "SERPER_API_KEY" variable is not set. Defaulting to a blank string. 
WARN[0000] The "SENDGRID_API_KEY" variable is not set. Defaulting to a blank string. 
[+] Running 6/7
 ✔ Container r2r-full-r2r-dashboard-1      Running                                                                                               0.0s 
 ✔ Container r2r-full-graph_clustering-1   Running                                                                                               0.0s 
 ✔ Container r2r-full-unstructured-1       Running                                                                                               0.0s 
 ✔ Container r2r-full-hatchet-postgres-1   Running                                                                                               0.0s 
 ✔ Container r2r-full-hatchet-create-db-1  Started                                                                                               0.0s 
 ✔ Container r2r-full-hatchet-rabbitmq-1   Running                                                                                               0.0s 
 ⠸ Container r2r-full-postgres-1           Starting                                                                                              0.3s 
Error response from daemon: driver failed programming external connectivity on endpoint r2r-full-postgres-1 (2c5897ac0c8bd028bc614ca88e3376f8292e9572baa0e44bd7d6549b6a4bb415): Error starting userland proxy: listen tcp4 0.0.0.0:5432: bind: address already in use
Waiting for all services to become healthy...
r2r does not have a health check defined.
Navigating to R2R application at http://localhost:7273.

When navigating to http://localhost:7273 the website is shown, but it can't connect to the backend as it's down.

However, lsof -i :5432 shows that no precoss runs on this address.

To Reproduce
run r2r serve --docker --full

Expected behavior
The application starts correctly

Desktop (please complete the following information):

  • OS: Linux
@jaggars
Copy link

jaggars commented Feb 3, 2025

i cant get the 3.3.32 version to get pass, " Waiting for all services to become healthy..."
..
just stalls and times out, just to re-install and do the same thing,

pip install r2r==3.3.28

worked for me.

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

No branches or pull requests

2 participants