Month: July 2011

How to find block size in Linux and Unix

This a small how-to on getting block size of a file system in your Linux machine. To go in to that info we have to learn bit information about file-system. What is a file-system? In simple, it’s a way we write data on to Disks is called as file-system. There are many File-systems supported by Linux. What is  block size in Linux? A block is a sequence of bit or Bytes with a fixed length ie 512 bytes, 4kB, 8kB, 16kB, 32kB etc. blockdev --getbsz partition Example # blockdev --getbsz /dev/sda1 4096 So the block size of this file...

Read More

18+ grep command examples in Linux/Unix

GREP is a command line search utility or tool to filter the input given to it. Grep got its name from ed editor as g/re/p (global / regular expression / print). Grep command can improve a command output by filtering out the required information. Grep will become a killer command when we combined it with regular expressions. In this post, we will see how to use grep command in a basic way and then move on some advanced and rarely used options. In our next couple of posts, we will see what grep can do with the help of regular...

Read More

Regular expressions in Linux -II

Regular Expression in Linux/Unix Part 2 This is our second part on Regular Expressions in Linux. Please have a look at our first part here. Interval Regular expressions These are used to mention no of character/character set reputation info. Note that interval regular expression and extended reg require -E option with grep Note: In order to use this set of regular expressions you have to us -E with grep command and -r option with sed commands   {n} –n occurrence of the previous character {n,m} – n to m times occurrence of the previous character {m, } –m or...

Read More

Over 16,000 readers, Get fresh content from “The Linux juggernaut”

Email Subscribe

ABOUT ME..!

My photo
My name is Surendra Kumar Anne. I hail from Vijayawada which is cultural capital of south Indian state of Andhra Pradesh. I am a Linux evangelist who believes in Hard work, A down to earth person, Likes to share knowledge with others, Loves dogs, Likes photography. At present I work at Bank of America as Sr. Analyst Systems and Administration. You can contact me at surendra (@) linuxnix dot com.