Saturday, 7 September 2013

Configuring ZNC on a Server

Well it was the first time I was configuring something on a web server. Till now all I did was configured different podium, interfaces on localhost only. But this time I thought it would fun if I get a chance to deploy something on actual web server. To my surprise my mentor Mr. Satyakaam  gave me an assignment (not an assignment literally) to install and configure ZNC on web server.

     To give you a brief intro about ZNC is a IRC bouncer which is used to relay traffic and connection in IRC channels. So all I did is  read all the documentation related to ZNC implementation and configuration, and I also peeped into their source code, and found it that it was quite easy to understand in fact. But I was unaware that I'll have to deal with so many things, in order to configure the ZNC. So after downloading the .tar file on the server, I extracted it and did all the steps as described in the wiki page of the ZNC official documentation. But to my surprise I was unable to see the ZNC working on the specified port of my server, even though I performed each step very carefully.

I again re-installed it, but then I got the CONFIG error, as the config file was already there on server, so I again deleted whole of it, including the .znc folder and again re-installed it and voila!! my webmodule was working fine. Meaning, I could see the web interface of ZNC. But then came another problem, I was not able to log onto the system properly, the error being my IP was changing dynamically!! (EVEN I DON'T KNOW HOW) this is where the code base walkthrough comes into effect. I checked into their codebase, and edited some of the files manually, also people who were there on their IRC channel #znc, helped me to rectify my error, so after typing a simple one line, which was

echo 'ProtectWebSessions = false' >> ~/.znc/configs/znc.conf

BINGO!!! All of my problems were solved and finally after 7 hours of hard work. I was able to pull this off.

Teachings: Well be patient, you never know what obstacle may come in your way, secondly, READ THE DOCUMENTATION CAREFULLY !!

No comments:

Post a Comment