Search and replace multiple files

At one point, you may be facing a situation where you would want to do an in place replacement of one string by another in multiple files. In this article, we will demonstrate a couple a way to do it, one solution using ‘perl’ and a second using ‘sed’.

2 min read

Identify physical network port name

The ‘ethtool’ is a command line utility used to query and control network device driver and hardware settings, particularly for wired Ethernet devices. In our example, we will use it to flash the light on the back of a card, this will be useful to identify the device name that belong to what port on the back of you Linux computer.

~1 min read

Resetting file permission with rpm


Did you know that you can reset file permission to what they were when you installed the package. This may become helpful if somebody made a mistake and change the permission on a number of files (This never happen right).

1 min read

Doing more with less

We usually use the “less” command to browse the content of a text file. We use the [Page-Up], [Page-Down], [Down-Arrow], [Up-Arrow] keys to move within the file, but did you know that you can do more with the less command ?

2 min read

Making Date Calculation

You’re doing a script and you need to know what was the date 35 days ago or what will the date be in 21 days. This is where  the “date” command can help you doing that kind of calculation. In this little article we will present some examples to help us making some data calculation. I would like to point out, that all of these date calculation take in consideration the leap year.

3 min read

Force user to change password

User is calling and say that he forgot is password. So you need to change his password and for security reason you want to force him to change it upon his first login. The command “chage -d 0” (change aging) will force user to change his password upon first login.

~1 min read

Linux Administration Books for Free

A short post to list some free books for Linux users and administrators, take a look you might find one that you would like to have.

~1 min read