Version `3.0.0` fails to start as a Windows service
Newest version 3.0.0 fails to start as a Windows service
Error Service Control Manager A timeout was reached (30000 milliseconds) while waiting for the IPBAN service to connect.
Error Service Control Manager The IPBAN service failed to start due to the following error: 1053
Just copying DigitalRuby.IPBan.exe and DigitalRuby.IPBanCore.xml from previous version 2.0.1 fixes it.
Ran this and it installed on my Windows 11 fine as a service:
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/DigitalRuby/IPBan/master/IPBanCore/Windows/Scripts/install_latest.ps1'))
Anything from the logfile.txt or event viewer you can share that might indicate the problem?
same here, service is installed successfully, but when restart vm, the service not start? dont know why im running windows server 2019
Without log files or event viewer entries, I'm at a loss here. I'm unable to replicate this on several Windows Servers, including 2016, 2019, 2022, along with Windows 10 & 11.
uploaded to you
Looks like a problem with your ipban.config file. Can you post it?
note that, ipban not start with windows, but i can manual start it (in services.msc) @@, dont know why
Have rebuilt release at https://github.com/DigitalRuby/IPBan/releases/tag/3.0.0 with latest .NET SDK. Let me know if it helps.
What powershell version are you running? And is it run as admin?
yes, i run powershell (admin priv) $ProgressPreference = 'SilentlyContinue'; [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/DigitalRuby/IPBan/master/IPBanCore/Windows/Scripts/install_latest.ps1'))
and replace all file from above built, the service is not start when windows start. i think you need set a delay from windows start?
This line from the script sets it to automatic (delayed) start:
& sc.exe create IPBAN type= own start= delayed-auto binPath= $INSTALL_EXE DisplayName= $SERVICE_NAME
Are you seeing it created with Automatic instead of Automatic (Delayed Start)?
yes, it shows "Delayed Start"
Might be worth trying 3.1.0 release to see if it works.
https://github.com/DigitalRuby/IPBan/releases/tag/3.1.0