frp
frp copied to clipboard
[Feature Request] DDNS IP更新后掉线
Describe the feature request
当服务端使用ddns ip变动后 client需要重启服务才能正常通信
Describe alternatives you've considered
使用定时重启可以解决但是会有断线时间
Affected area
- [ ] Docs
- [ ] Installation
- [ ] Performance and Scalability
- [ ] Security
- [X] User Experience
- [ ] Test and Release
- [ ] Developer Infrastructure
- [ ] Client Plugin
- [ ] Server Plugin
- [ ] Extensions
- [ ] Others
Hello @SingletC
Assuming that you FRP client is a windows machine I have written a powershell script for you which you can run as a batch file by saving it as a batch file with any name.
Run the batch scipt at regular intervals say every 5 min using windows task scheduler to automatically restart service if the IP address pointing to you DDNS changes and as a additional feature I have added automatically update DNS servers for current network adapter to cloudflare dns that is 1.1.1.1 & 1.0.0.1 and flush dns both are automatically done when the DDNS current IP address changes.
Hello @SingletC
Assuming that you FRP client is a windows machine I have written a powershell script for you which you can run as a batch file by saving it as a batch file with any name.
Run the batch scipt at regular intervals say every 5 min using windows task scheduler to automatically restart service if the IP address pointing to you DDNS changes and as a additional feature I have added automatically update DNS servers for current network adapter to cloudflare dns that is 1.1.1.1 & 1.0.0.1 and flush dns both are automatically done when the DDNS current IP address changes.
I much appreciate your help; I did not test the above code. But I assume it will work. It will be easy to let the client query the IP address of a domain instead of caching it. You can close the thread if this feature seems unnecessary.
@SingletC I am having issues sharing the code here give me some time I will post it here.
@SingletC Here you go a link to downlod my batch script.
https://www.zippyshare.day/ZnzuZ715lWYguC5/file
let me know if this works for you. @SingletC
我有一台frps(arm64)公网ip被运营商更新时,动态域名更新可能不及时,我的另外2台frpc(一台arm,一台arm64),通常会断线几分钟到十几分钟,然后自动重新连上,并不需要重启。
Issues go stale after 21d of inactivity. Stale issues rot after an additional 7d of inactivity and eventually close.