Automatically reclaim my IRC nickname (without underscores) globally?

I use XChat (2.8.6). It runs 24/7. I think whenever my internet connection is reset (at least every 24 hours), my nickname gets an underscore (_) appended:

My nick john becomes john_, then it becomes john__, then john___ … and so on.

When I click left to the chat text field on my nickname, I can enter a new name. At the moment, I re-enter "john" there everytime and for each server. Which is annoying. Is there a way to change my nickname globally (= for all servers) back to the registered "normal" form (without underscores) automatically?


Solution 1:

I believe it happens because the IRC server still thinks for a while that you are online when your internet connection is reset and won't allow you to log in with the same nick. You can explicitly reclaim your stale nick by using the nickserv ghost command - manually or by running a script in your IRC client.

Also, you can try using an IRC bouncer - run it on a remote host that's always online.