mirror of
https://github.com/fatedier/frp.git
synced 2026-05-15 08:05:49 -06:00
[GH-ISSUE #4743] ssh tunnel config error while systemctl #3746
Labels
No labels
In Progress
WIP
WaitingForInfo
bug
doc
duplicate
easy
enhancement
future
help wanted
invalid
lifecycle/stale
need-issue-template
need-usage-help
no plan
proposal
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/frp#3746
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @itsKV on GitHub (Apr 6, 2025).
Original GitHub issue: https://github.com/fatedier/frp/issues/4743
Bug Description
Using
sshTunnelGateway.bindPort = 2200in toml file fails the frps systemctl service to start. But executing the frps binary directly with the same toml file runs successfully.Is there any wrong from me ?
Following is the frps.service file content.
frpc Version
0.61.2
frps Version
0.61.2
System Architecture
linux/arm64
Configurations
Logs
No response
Steps to reproduce
No response
Affected area
@fatedier commented on GitHub (Apr 7, 2025):
Do you think I can draw any conclusions from the information you provided? There isn't even any infromation about the failure.
@itsKV commented on GitHub (Apr 9, 2025):
Hello fatedier,
I am sorry for not being clear at first.
The issue is, when I start frps by running binary directly from command, starts the frps successfully and works fine. Following is the screenshot of running the binary.
But when I execute frps with same config from systemctl service manager using command
sudo systemctl start frps, the service starts but fails immediately. I can confirm the failure withstatuscommand. Following is the screenshot.I don't understand why binary executes but the same with the service fails.
When I comment out the
sshTunnelGateway.bindPort = 2200command from toml file, the systemctl service does not give any issue and runs smoothly.@fatedier commented on GitHub (Apr 9, 2025):
Check the system logs for more detailed error messages. You can use journalctl -u frps to view the logs for the frps service.
@itsKV commented on GitHub (Apr 12, 2025):
Troubleshooting with
journalctl -u frpshelped a lot. I found that with default configuration, frps was writing at./.autogen_ssh_keylocation which is restricted with the given systemctl config.I tweaked the
autoGenPrivateKeyPathlocation and removedDynamicUser=yesswitch from systemctl config file.This cleared the issue and frps service started successfully.