How can I setup & run PhantomJS on Ubuntu?

Guidouil’s answer put me on the right track. I had to add one additional symlink to /usr/bin/, and I did direct symlinks for all 3 – see below. I’m installing on Ubuntu server Natty Narwhal. This is exactly what I did. cd /usr/local/share sudo wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.7-linux-x86_64.tar.bz2 sudo tar xjf phantomjs-1.9.7-linux-x86_64.tar.bz2 sudo ln -s /usr/local/share/phantomjs-1.9.7-linux-x86_64/bin/phantomjs /usr/local/share/phantomjs … Read more

When should we use mutex and when should we use semaphore

Here is how I remember when to use what – Semaphore: Use a semaphore when you (thread) want to sleep till some other thread tells you to wake up. Semaphore ‘down’ happens in one thread (producer) and semaphore ‘up’ (for same semaphore) happens in another thread (consumer) e.g.: In producer-consumer problem, producer wants to sleep … Read more

Keep SSH session alive [closed]

The ssh daemon (sshd), which runs server-side, closes the connection from the server-side if the client goes silent (i.e., does not send information). To prevent connection loss, instruct the ssh client to send a sign-of-life signal to the server once in a while. The configuration for this is in the file $HOME/.ssh/config, create the file … Read more