Feb 222012
 

It’s funny how through small daily tasks sometimes it happen to find new features or commands that you do not knew not, and today this thing happened to me.
In particular, I had to do something trivial on the shell of a server, run : command1 | tail-n 2 i use tail to keep, from a significant long output, only the last 2 lines which then i use in another function, but beyond this, I needed to understand if command1 was terminated with an exit code of 0 or if the code was not 0 which number it was.

A simple:

....
comando1 | tail -n 2 
if [ $? -ne 0 ]
	then
		echo "comando1 fallito."
		EXIT_CODE=1
	fi
....

Does not work because the exit code comes from the command tail, which in my case is always 0.
So I Googled a bit and found more than a solution for this simple problem.
Continue reading »

Flattr this!

Feb 192012
 

This is the inside story on a Linux distribution known as SimplyMEPIS.

Like a lot of stories, there is more to it than meets the eye. And while on the surface, this is a story about a Linux distribution, there are some life lessons that can be found in it.

As with many other people, my life saw a lot of dramatic changes in the year 2001. For me, it started in January 2001. I should have been keeping in mind the words of wisdom from the world champion athlete Dan Millman. He wrote The Way of the Peaceful Warrior, and other books. One of his statements is all accidents can be attributed to one of three reasons:

  1. Someone is upset
  2. Someone is not paying attention.
  3. Someone is not physically ready.

On the evening of January 27, 2001, I was seriously holding on to positions number one and two. That led to option number three, in the dark and snow both me and my mountain bike became seriously FUBARED. The mountain bike did not live, and certainly I should not have. Continue reading »

Flattr this!

Feb 172012
 

Gnome 3 has failed to win users over. Unity was so unpopular it wiped out Ubuntu’s lead on Distrowatch and made Linux Mint number one. With the dominant desktop (Gnome) and the dominant distribution (Ubuntu) both failing to set users’ hearts racing we’re reminded once again why we love using Linux – there’s so much choice.

There might even be too much choice. From Fluxbox to XFCE and KDE to MATE there are a vast and confusing selection of desktop environments to work through. Whilst some have looked to move to a lightweight option like XFCE that captures much of the flavour of Linux past with some funky new features (the nice see-through dock at the bottom of the screen on Xubuntu looks really sharp for example) others are looking to the future. In Cinnamon we have a very exciting, beautiful future that you’ll soon be recommending to everyone who’ll listen. Continue reading »

Flattr this!

Feb 152012
 

Today I want to just give you a pill, but I’m sure that even if is short this article will save a lot of time to someone who, like me, has this requirement.
Having a machine with Linux and various IP (which can be IPv4 and / or ipv6) and a Squid Proxy Server configure your browser to use that proxy on one of these IP and go out from that server with the same IP and not with the default ip .

This can be useful if you have services that require 1 specific IP to be allowed, or if you want to give the proxy server to different people and still be able to trace what they do.
To achieve this we’ll use the ACL, Squid has very good ACL’s (Access Control Lists) built into the squid.conf file, allowing you to lock down or control the access by names, IP’s, networks, time of day, actual day. Remember however that like every firewall the more complicated an ACL is, the slower Squid will be to respond to requests. Continue reading »

Flattr this!

Feb 122012
 

There are many people that have old computers in their basement or attic, and they do not use it because they are considered too old and outclassed.
Today we will see a possibility to recover an old PC, we will see how to turn your PC into a fantastic digital Jukebox. You will have the opportunity to listen to music like a professional real station! What do you need? Nothing more than your old PC and, of course, some average speakers or audio system.

If you want the best, pick up your Android smartphone and you will see what we can do! Continue reading »

Flattr this!