How do I configure a port in my .conf file?
Windows 10


Run netstat -ab &gt;file.txt then notepad file.txt and search on 5040. I suspect you will find CDPSvc immediately underneath - on my machine this "Connected Devices Platform Service" is already using your port. 

If that's so, search on 5041, then 5042 and continue up until search can't find it. That port is free: change your rpcport to match it.