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

Proxies fail to start "bind: can't assign requested address" #7317

Open
1 task done
Bouke opened this issue Jan 29, 2025 · 4 comments
Open
1 task done

Proxies fail to start "bind: can't assign requested address" #7317

Bouke opened this issue Jan 29, 2025 · 4 comments
Labels
area-orchestrator untriaged New issue has not been triaged

Comments

@Bouke
Copy link

Bouke commented Jan 29, 2025

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

When I run the starter app template, the proxies aren't started. The webfrontend and apiservice are started and running just fine, but the proxies aren't listening. The logs show an error about not being able to assign the requested address. As a result, the service reference to apiservice in webfrontend is not working, and the 'Weather' page fails.

Expected Behavior

The proxies to be working.

Steps To Reproduce

> mkdir AspireTest
> cd AspireTest
> dotnet new aspire-starter
> cd AspireTest.AppHost
> dotnet run

Exceptions (if any)

~/D/A/AspireTest.AppHost ❱ dotnet run
Using launch settings from /Users/bouke/Developer/AspireTest/AspireTest.AppHost/Properties/launchSettings.json...
Building...
info: Aspire.Hosting.DistributedApplication[0]
      Aspire version: 9.0.0+01ed51919f8df692ececce51048a140615dc759d
info: Aspire.Hosting.DistributedApplication[0]
      Distributed application starting.
info: Aspire.Hosting.DistributedApplication[0]
      Application host directory is: /Users/bouke/Developer/AspireTest/AspireTest.AppHost
info: Aspire.Hosting.DistributedApplication[0]
      Now listening on: https://localhost:17198
info: Aspire.Hosting.DistributedApplication[0]
      Login to the dashboard at https://localhost:17198/login?t=feba1d44409784a6c32e9198cea00515
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"webfrontend-https"}, "Reconciliation": 5, "error": "could not start the proxy for the service: listen tcp [fe80::1]:7155: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"webfrontend-http"}, "Reconciliation": 6, "error": "could not start the proxy for the service: listen tcp [fe80::1]:5035: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"apiservice-https"}, "Reconciliation": 7, "error": "could not start the proxy for the service: listen tcp [fe80::1]:7520: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"apiservice-http"}, "Reconciliation": 8, "error": "could not start the proxy for the service: listen tcp [fe80::1]:5310: bind: can't assign requested address"}
info: Aspire.Hosting.DistributedApplication[0]
      Distributed application started. Press Ctrl+C to shut down.
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"apiservice-https"}, "Reconciliation": 9, "error": "could not start the proxy for the service: listen tcp [fe80::1]:7520: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"apiservice-http"}, "Reconciliation": 10, "error": "could not start the proxy for the service: listen tcp [fe80::1]:5310: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"webfrontend-https"}, "Reconciliation": 11, "error": "could not start the proxy for the service: listen tcp [fe80::1]:7155: bind: can't assign requested address"}
fail: Aspire.Hosting.Dcp.dcpctrl.ServiceReconciler[0]
      could not start the proxy	{"ServiceName": {"name":"webfrontend-http"}, "Reconciliation": 12, "error": "could not start the proxy for the service: listen tcp [fe80::1]:5035: bind: can't assign requested address"}

.NET Version info

.NET SDK:
 Version:           9.0.100
 Commit:            59db016f11
 Workload version:  9.0.100-manifests.693890c1
 MSBuild version:   17.12.7+5b8665660

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  15.1
 OS Platform: Darwin
 RID:         osx-arm64
 Base Path:   /usr/local/share/dotnet/sdk/9.0.100/

.NET workloads installed:
There are no installed workloads to display.
Configured to use loose manifests when installing new manifests.

Host:
  Version:      9.0.0
  Architecture: arm64
  Commit:       9d5a6a9aa4

.NET SDKs installed:
(...)
  8.0.404 [/usr/local/share/dotnet/sdk]
  9.0.100 [/usr/local/share/dotnet/sdk]

.NET runtimes installed:
(...)
  Microsoft.NETCore.App 8.0.11 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 9.0.0 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
  x64   [/usr/local/share/dotnet]
    registered at [/etc/dotnet/install_location_x64]

Environment variables:
  Not set

global.json file:
  Not found

Anything else?

I found another bug report about port binding, which is reportedly fixed (#6693), so I also tried with the latest preview build (9.1.0-preview.1.25079.2), but that doesn't fix it.

@joperezr joperezr added the untriaged New issue has not been triaged label Jan 29, 2025
@davidfowl
Copy link
Member

@Bouke Bouke changed the title Wrong ports listed for endpoints, references broken Proxies fail to start "bind: can't assign requested address" Jan 30, 2025
@Bouke
Copy link
Author

Bouke commented Jan 30, 2025

@davidfowl thank you for the pointer, I am indeed new to Aspire and trying out the starter app template to figure out what's what and what Aspire can do for me. I've updated the description to better show the problem I'm running into, which are (apparently) the proxies that fail to start.

@davidfowl
Copy link
Member

cc @danegsta

@karolz-ms
Copy link
Member

@Bouke I assume you are sure there is no more than one instance of the application running.

What is the networking stack configuration of your machine? Is it IPv6-only? Dual IPv4 and IPv6? Do you have any proxy/VPN software running on the machine? Does the errors disappear if you sed DCP_IP_VERSION_PREFERENCE=v4 environment variable?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-orchestrator untriaged New issue has not been triaged
Projects
None yet
Development

No branches or pull requests

4 participants