[GH-ISSUE #1915] Can neither reach client nor server #1396

Closed
opened 2026-05-05 07:47:58 -06:00 by gitea-mirror · 0 comments
Owner

Originally created by @sid115 on GitHub (Mar 16, 2023).
Original GitHub issue: https://github.com/debauchee/barrier/issues/1915

What happened?

SCENARIO 1:
When trying to start the server with a specified client address, the server fails to start.

SCENARIO 2:
Without specifying a client address, the server starts successfully, but the connection cannot be established.

Client IP: 192.168.178.41, hostname "PC"
Server IP: 192.168.178.22, hostname "ideapad"
See log output for detailed information on how the services are started.

Version

v2.4.0

Git commit hash (if applicable)

No response

If applicable, where did you install Barrier from?

Windows 10 Client: https://github.com/debauchee/barrier/releases/download/v2.4.0/BarrierSetup-2.4.0-release.exe
Arch Linux Server: https://archlinux.org/packages/community/x86_64/barrier/

What OSes are you seeing the problem on? (Check all that apply)

Linux, Windows

What OS versions are you using?

Server: Arch Linux 6.2.6-arch1-1
Client: Windows 10 22H2 (Build 19045)

Relevant log output

SCENARIO 1:
Starting server with:
barriers -a 192.168.178.41 -c ~/.config/barrier/barrier.conf -l ~/.local/state/barrier/test.log --restart -d DEBUG -f

Server log output:
[2023-03-16T19:24:35] DEBUG: opening configuration "/home/sid/.config/barrier/barrier.conf"
[2023-03-16T19:24:35] DEBUG: configuration read successfully
[2023-03-16T19:24:35] DEBUG: XOpenDisplay(":0")
[2023-03-16T19:24:35] DEBUG: xscreensaver window: 0x00000000
[2023-03-16T19:24:35] DEBUG: screen shape: 0,0 2560x1600 
[2023-03-16T19:24:35] DEBUG: window is 0x02400004
[2023-03-16T19:24:35] DEBUG: adopting new buffer
[2023-03-16T19:24:35] DEBUG: opened display
[2023-03-16T19:24:35] FATAL: failed to start server: cannot bind address: Cannot assign requested address

SCENARIO 2:
Starting server with:
barriers -c ~/.config/barrier/barrier.conf -l ~/.local/state/barrier/test.log --restart -d DEBUG -f

Server log output:
[2023-03-16T19:33:43] DEBUG: opening configuration "/home/sid/.config/barrier/barrier.conf"
[2023-03-16T19:33:43] DEBUG: configuration read successfully
[2023-03-16T19:33:43] DEBUG: XOpenDisplay(":0")
[2023-03-16T19:33:43] DEBUG: xscreensaver window: 0x00000000
[2023-03-16T19:33:43] DEBUG: screen shape: 0,0 2560x1600
[2023-03-16T19:33:43] DEBUG: window is 0x02400004
[2023-03-16T19:33:43] DEBUG: adopting new buffer
[2023-03-16T19:33:43] DEBUG: opened display
[2023-03-16T19:33:43] DEBUG: registered hotkey ScrollLock (id=ef14 mask=0000) as id=1
started server (IPv4), waiting for clients
[2023-03-16T19:33:43] DEBUG: event queue is ready
[2023-03-16T19:33:43] DEBUG: add pending events to buffer
[2023-03-16T19:33:43] DEBUG: screen "ideapad" shape changed

Client log output:
[2023-03-16T19:35:17] DEBUG: starting process
[2023-03-16T19:35:17] INFO: starting client
[2023-03-16T19:35:17] DEBUG: command: "C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800
[2023-03-16T19:35:17] INFO: config file: C:/Users/sid/AppData/Local/Temp/Barrier.YqMZMx
[2023-03-16T19:35:17] INFO: log level: DEBUG
[2023-03-16T19:35:17] DEBUG: start ipc handle data
[2023-03-16T19:35:17] DEBUG: ipc read: ICMD
[2023-03-16T19:35:17] DEBUG: finished ipc handle data
[2023-03-16T19:35:17] DEBUG: new command, elevate=0 command="C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800
[2023-03-16T19:35:17] INFO: service command updated
[2023-03-16T19:35:18] DEBUG: found desktop name: 
[2023-03-16T19:35:18] DEBUG: getting elevated token, at login screen
[2023-03-16T19:35:18] DEBUG: processes in session 1: csrss.exe, winlogon.exe, fontdrvhost.exe, dwm.exe, NVDisplay.Container.exe, sihost.exe, svchost.exe, taskhostw.exe, taskhostw.exe, ctfmon.exe, explorer.exe, svchost.exe, StartMenuExperienceHost.exe, RuntimeBroker.exe, SearchApp.exe, RuntimeBroker.exe, LockApp.exe, RuntimeBroker.exe, SecurityHealthSystray.exe, steam.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, TextInputHost.exe, dllhost.exe, RuntimeBroker.exe, powershell.exe, conhost.exe, ShellExperienceHost.exe, RuntimeBroker.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, ApplicationFrameHost.exe, SecHealthUI.exe, SecurityHealthHost.exe, mmc.exe, mmc.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, barrier.exe, msinfo32.exe, librewolf.exe, librewolf.exe, librewolf.exe, Element.exe, Element.exe, Element.exe, Element.exe, Element.exe, librewolf.exe, mmc.exe, 
[2023-03-16T19:35:18] DEBUG: found winlogon.exe in session 1
[2023-03-16T19:35:18] DEBUG: got token 1160, duplicating
[2023-03-16T19:35:18] DEBUG: duplicated, new token: 1164
[2023-03-16T19:35:18] INFO: starting new process as privileged user
[2023-03-16T19:35:18] DEBUG: screen shape: 0,0 2560x1080 
[2023-03-16T19:35:18] DEBUG: window is 0x0013044e
[2023-03-16T19:35:18] DEBUG: adopting new buffer
[2023-03-16T19:35:18] DEBUG: opened display
[2023-03-16T19:35:18] NOTE: started client
[2023-03-16T19:35:18] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800
[2023-03-16T19:35:18] DEBUG: Opening new socket: 94A2F640
[2023-03-16T19:35:18] DEBUG: Opening new socket: 94A34DF0
[2023-03-16T19:35:18] DEBUG: event queue is ready
[2023-03-16T19:35:18] DEBUG: Opening new socket: 86BA4CE0
[2023-03-16T19:35:18] DEBUG: accepted ipc client connection
[2023-03-16T19:35:18] DEBUG: start ipc handle data
[2023-03-16T19:35:18] DEBUG: ipc read: IHEL
[2023-03-16T19:35:18] DEBUG: finished ipc handle data
[2023-03-16T19:35:18] DEBUG: ipc hello, type=node
server status: active
[2023-03-16T19:35:19] DEBUG: started process, session=1, elevated: yes, command="C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800
[2023-03-16T19:35:33] DEBUG: Closing socket: 94A2F640
[2023-03-16T19:35:33] WARNING: failed to connect to server: Timed out
[2023-03-16T19:35:33] DEBUG: retry in 1 seconds
[2023-03-16T19:35:34] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800
[2023-03-16T19:35:34] DEBUG: Opening new socket: 94A34B20
[2023-03-16T19:35:49] DEBUG: Closing socket: 94A34B20
[2023-03-16T19:35:49] WARNING: failed to connect to server: Timed out
[2023-03-16T19:35:49] DEBUG: retry in 1 seconds
[2023-03-16T19:35:50] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800
[2023-03-16T19:35:50] DEBUG: Opening new socket: 94A350C0
[2023-03-16T19:36:05] DEBUG: Closing socket: 94A350C0
[2023-03-16T19:36:05] WARNING: failed to connect to server: Timed out
[2023-03-16T19:36:05] DEBUG: retry in 1 seconds
[2023-03-16T19:36:06] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800
[2023-03-16T19:36:06] DEBUG: Opening new socket: 94A351E0

Any other information

barrier server config:

section: screens
	ideapad:
		halfDuplexCapsLock = false
		halfDuplexNumLock = false
		halfDuplexScrollLock = false
		xtestIsXineramaUnaware = false
		preserveFocus = false
		switchCorners = none 
		switchCornerSize = 0
	PC:
		halfDuplexCapsLock = false
		halfDuplexNumLock = false
		halfDuplexScrollLock = false
		xtestIsXineramaUnaware = false
		preserveFocus = false
		switchCorners = none 
		switchCornerSize = 0
end

section: aliases
end

section: links
	PC:
		right = ideapad
	ideapad:
		left = PC
end

section: options
	relativeMouseMoves = false
	screenSaverSync = true
	win32KeepForeground = false
	clipboardSharing = true
	switchCorners = none 
	switchCornerSize = 0
end

Firewall on server:
sudo iptables -L --line-numbers

Chain INPUT (policy ACCEPT)
num  target     prot opt source               destination
1    ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:24800 ctstate NEW,ESTABLISHED

Chain FORWARD (policy ACCEPT)
num  target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
num  target     prot opt source               destination
1    ACCEPT     all  --  anywhere             anywhere
2    ACCEPT     tcp  --  anywhere             anywhere             tcp spt:24800 ctstate ESTABLISHED

Firewall on Client:
Windows Defender Firewall inbound rules for barrier.exe and barrierc.exe

Trying to reach server:
Test-NetConnection -Port 24800 -ComputerName 192.168.178.22 -InformationLevel Detailed

WARNING: TCP connect to (192.168.178.22 : 24800) failed

ComputerName            : 192.168.178.22
RemoteAddress           : 192.168.178.22
RemotePort              : 24800
NameResolutionResults   : 192.168.178.22
                          ideapad.fritz.box
MatchingIPsecRules      :
NetworkIsolationContext : Private Network
IsAdmin                 : False
InterfaceAlias          : Ethernet
SourceAddress           : 192.168.178.41
NetRoute (NextHop)      : 0.0.0.0
PingSucceeded           : True
PingReplyDetails (RTT)  : 0 ms
TcpTestSucceeded        : False

Trying to reach client:
nc -vz 192.168.178.41 24800

nc: connect to 192.168.178.41 port 24800 (tcp) failed: Connection refused

Originally created by @sid115 on GitHub (Mar 16, 2023). Original GitHub issue: https://github.com/debauchee/barrier/issues/1915 ### What happened? SCENARIO 1: When trying to start the server with a specified client address, the server fails to start. SCENARIO 2: Without specifying a client address, the server starts successfully, but the connection cannot be established. Client IP: 192.168.178.41, hostname "PC" Server IP: 192.168.178.22, hostname "ideapad" See log output for detailed information on how the services are started. ### Version v2.4.0 ### Git commit hash (if applicable) _No response_ ### If applicable, where did you install Barrier from? Windows 10 Client: https://github.com/debauchee/barrier/releases/download/v2.4.0/BarrierSetup-2.4.0-release.exe Arch Linux Server: https://archlinux.org/packages/community/x86_64/barrier/ ### What OSes are you seeing the problem on? (Check all that apply) Linux, Windows ### What OS versions are you using? Server: Arch Linux 6.2.6-arch1-1 Client: Windows 10 22H2 (Build 19045) ### Relevant log output ```shell SCENARIO 1: Starting server with: barriers -a 192.168.178.41 -c ~/.config/barrier/barrier.conf -l ~/.local/state/barrier/test.log --restart -d DEBUG -f Server log output: [2023-03-16T19:24:35] DEBUG: opening configuration "/home/sid/.config/barrier/barrier.conf" [2023-03-16T19:24:35] DEBUG: configuration read successfully [2023-03-16T19:24:35] DEBUG: XOpenDisplay(":0") [2023-03-16T19:24:35] DEBUG: xscreensaver window: 0x00000000 [2023-03-16T19:24:35] DEBUG: screen shape: 0,0 2560x1600 [2023-03-16T19:24:35] DEBUG: window is 0x02400004 [2023-03-16T19:24:35] DEBUG: adopting new buffer [2023-03-16T19:24:35] DEBUG: opened display [2023-03-16T19:24:35] FATAL: failed to start server: cannot bind address: Cannot assign requested address SCENARIO 2: Starting server with: barriers -c ~/.config/barrier/barrier.conf -l ~/.local/state/barrier/test.log --restart -d DEBUG -f Server log output: [2023-03-16T19:33:43] DEBUG: opening configuration "/home/sid/.config/barrier/barrier.conf" [2023-03-16T19:33:43] DEBUG: configuration read successfully [2023-03-16T19:33:43] DEBUG: XOpenDisplay(":0") [2023-03-16T19:33:43] DEBUG: xscreensaver window: 0x00000000 [2023-03-16T19:33:43] DEBUG: screen shape: 0,0 2560x1600 [2023-03-16T19:33:43] DEBUG: window is 0x02400004 [2023-03-16T19:33:43] DEBUG: adopting new buffer [2023-03-16T19:33:43] DEBUG: opened display [2023-03-16T19:33:43] DEBUG: registered hotkey ScrollLock (id=ef14 mask=0000) as id=1 started server (IPv4), waiting for clients [2023-03-16T19:33:43] DEBUG: event queue is ready [2023-03-16T19:33:43] DEBUG: add pending events to buffer [2023-03-16T19:33:43] DEBUG: screen "ideapad" shape changed Client log output: [2023-03-16T19:35:17] DEBUG: starting process [2023-03-16T19:35:17] INFO: starting client [2023-03-16T19:35:17] DEBUG: command: "C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800 [2023-03-16T19:35:17] INFO: config file: C:/Users/sid/AppData/Local/Temp/Barrier.YqMZMx [2023-03-16T19:35:17] INFO: log level: DEBUG [2023-03-16T19:35:17] DEBUG: start ipc handle data [2023-03-16T19:35:17] DEBUG: ipc read: ICMD [2023-03-16T19:35:17] DEBUG: finished ipc handle data [2023-03-16T19:35:17] DEBUG: new command, elevate=0 command="C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800 [2023-03-16T19:35:17] INFO: service command updated [2023-03-16T19:35:18] DEBUG: found desktop name: [2023-03-16T19:35:18] DEBUG: getting elevated token, at login screen [2023-03-16T19:35:18] DEBUG: processes in session 1: csrss.exe, winlogon.exe, fontdrvhost.exe, dwm.exe, NVDisplay.Container.exe, sihost.exe, svchost.exe, taskhostw.exe, taskhostw.exe, ctfmon.exe, explorer.exe, svchost.exe, StartMenuExperienceHost.exe, RuntimeBroker.exe, SearchApp.exe, RuntimeBroker.exe, LockApp.exe, RuntimeBroker.exe, SecurityHealthSystray.exe, steam.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, steamwebhelper.exe, TextInputHost.exe, dllhost.exe, RuntimeBroker.exe, powershell.exe, conhost.exe, ShellExperienceHost.exe, RuntimeBroker.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, ApplicationFrameHost.exe, SecHealthUI.exe, SecurityHealthHost.exe, mmc.exe, mmc.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, librewolf.exe, barrier.exe, msinfo32.exe, librewolf.exe, librewolf.exe, librewolf.exe, Element.exe, Element.exe, Element.exe, Element.exe, Element.exe, librewolf.exe, mmc.exe, [2023-03-16T19:35:18] DEBUG: found winlogon.exe in session 1 [2023-03-16T19:35:18] DEBUG: got token 1160, duplicating [2023-03-16T19:35:18] DEBUG: duplicated, new token: 1164 [2023-03-16T19:35:18] INFO: starting new process as privileged user [2023-03-16T19:35:18] DEBUG: screen shape: 0,0 2560x1080 [2023-03-16T19:35:18] DEBUG: window is 0x0013044e [2023-03-16T19:35:18] DEBUG: adopting new buffer [2023-03-16T19:35:18] DEBUG: opened display [2023-03-16T19:35:18] NOTE: started client [2023-03-16T19:35:18] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800 [2023-03-16T19:35:18] DEBUG: Opening new socket: 94A2F640 [2023-03-16T19:35:18] DEBUG: Opening new socket: 94A34DF0 [2023-03-16T19:35:18] DEBUG: event queue is ready [2023-03-16T19:35:18] DEBUG: Opening new socket: 86BA4CE0 [2023-03-16T19:35:18] DEBUG: accepted ipc client connection [2023-03-16T19:35:18] DEBUG: start ipc handle data [2023-03-16T19:35:18] DEBUG: ipc read: IHEL [2023-03-16T19:35:18] DEBUG: finished ipc handle data [2023-03-16T19:35:18] DEBUG: ipc hello, type=node server status: active [2023-03-16T19:35:19] DEBUG: started process, session=1, elevated: yes, command="C:/Program Files/Barrier/barrierc.exe" -f --no-tray --debug DEBUG --name PC --ipc --stop-on-desk-switch --disable-crypto --profile-dir "C:\Users\sid\AppData\Local\Barrier" [192.168.178.22]:24800 [2023-03-16T19:35:33] DEBUG: Closing socket: 94A2F640 [2023-03-16T19:35:33] WARNING: failed to connect to server: Timed out [2023-03-16T19:35:33] DEBUG: retry in 1 seconds [2023-03-16T19:35:34] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800 [2023-03-16T19:35:34] DEBUG: Opening new socket: 94A34B20 [2023-03-16T19:35:49] DEBUG: Closing socket: 94A34B20 [2023-03-16T19:35:49] WARNING: failed to connect to server: Timed out [2023-03-16T19:35:49] DEBUG: retry in 1 seconds [2023-03-16T19:35:50] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800 [2023-03-16T19:35:50] DEBUG: Opening new socket: 94A350C0 [2023-03-16T19:36:05] DEBUG: Closing socket: 94A350C0 [2023-03-16T19:36:05] WARNING: failed to connect to server: Timed out [2023-03-16T19:36:05] DEBUG: retry in 1 seconds [2023-03-16T19:36:06] NOTE: connecting to '192.168.178.22': 192.168.178.22:24800 [2023-03-16T19:36:06] DEBUG: Opening new socket: 94A351E0 ``` ### Any other information barrier server config: ``` section: screens ideapad: halfDuplexCapsLock = false halfDuplexNumLock = false halfDuplexScrollLock = false xtestIsXineramaUnaware = false preserveFocus = false switchCorners = none switchCornerSize = 0 PC: halfDuplexCapsLock = false halfDuplexNumLock = false halfDuplexScrollLock = false xtestIsXineramaUnaware = false preserveFocus = false switchCorners = none switchCornerSize = 0 end section: aliases end section: links PC: right = ideapad ideapad: left = PC end section: options relativeMouseMoves = false screenSaverSync = true win32KeepForeground = false clipboardSharing = true switchCorners = none switchCornerSize = 0 end ``` **Firewall on server:** `sudo iptables -L --line-numbers` ``` Chain INPUT (policy ACCEPT) num target prot opt source destination 1 ACCEPT tcp -- anywhere anywhere tcp dpt:24800 ctstate NEW,ESTABLISHED Chain FORWARD (policy ACCEPT) num target prot opt source destination Chain OUTPUT (policy ACCEPT) num target prot opt source destination 1 ACCEPT all -- anywhere anywhere 2 ACCEPT tcp -- anywhere anywhere tcp spt:24800 ctstate ESTABLISHED ``` **Firewall on Client:** Windows Defender Firewall inbound rules for barrier.exe and barrierc.exe **Trying to reach server:** `Test-NetConnection -Port 24800 -ComputerName 192.168.178.22 -InformationLevel Detailed` ``` WARNING: TCP connect to (192.168.178.22 : 24800) failed ComputerName : 192.168.178.22 RemoteAddress : 192.168.178.22 RemotePort : 24800 NameResolutionResults : 192.168.178.22 ideapad.fritz.box MatchingIPsecRules : NetworkIsolationContext : Private Network IsAdmin : False InterfaceAlias : Ethernet SourceAddress : 192.168.178.41 NetRoute (NextHop) : 0.0.0.0 PingSucceeded : True PingReplyDetails (RTT) : 0 ms TcpTestSucceeded : False ``` **Trying to reach client:** `nc -vz 192.168.178.41 24800` `nc: connect to 192.168.178.41 port 24800 (tcp) failed: Connection refused`
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/barrier#1396
No description provided.