Category Archives: Technical

The File-system dilemma

I recently bought Seagate GoFlex FreeAgent Desk 2TB 3.5inch [ 😦 ] hard-disk. And I wanted to know which is the best file-system suited for my use.

I usually use ext2 for my pen drives. I wanted to know that, is there any added advantage using btrfs over ext4. My use is to store books of size (usually <20 MB ). Seperate partition for movies and tvseries ( 300MB < avg-size < 4GB) and tutorials (size <100MB) and lecture videos (size <350MB).

After some discussion I decided to go for ext4. And this post explains why.

When formatted to Ext2
command $: mkfs.ext2 -L “” /dev/sdb1
Disk /dev/sdb: 2000.4 GB, 2000398933504 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006ec2e

Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1      243202  1953513472   83  Linux


When Formatted to Ext 4
It took painstaking 18 minutes


I personally prefer to use ext4 after reading this link.
Also ext reserves 5% disk space for root.

The reserved blocks are there for root’s use. This allows the system to continue running if non-root users fill up the file system and also assists in preventing file fragmentation because the filesystem does not fill up completely.

So, in short, if the drive doesn’t contain /var or /tmp, then there’s not much point in having space reserved for root.
You can get that space back. By using tune2fsIt is a good tool.

sudo tune2fs -r 0 /dev/sdX to disable it. /*Here we set the “-r=reserved-blocks-count” to zero */

Some forums prefer that minimum 1% is recommended. You can modify the percentage of reserved block percentage too using tune2fs.

sudo tune2fs -m 1 /dev/sdX to modift it. /* Here we modify (-m) “reserved-block-percentage” to 1% from the default 5% */

My earlier plan to format to Btrs was foolish at this point of time as it lacks tuning and debugging support. And gave a 100GB buffer space with the inferior FAT32 and 30 GB with NTFS so as to connect to my friend’s computers using windows.

With a larger maximum file size, fast fsck and journal checksumming ,  I chose ext4. Some benchmarking showed that ext4’s sequential read is better than sequential write as ext2 makes lesser writes than ext4 thereby increasing lifetime for your flashdrives.

Though ext4 makes more sequential writes to disks degrading performance for drives with data rarely modified. Unnecessary writes to your device can be avoided by using noatime flag in mount. You can over ride the default mount option again with tune2fs.

Further Read

1 Comment

Posted by on Thursday, October 20th, 2011 in disk management, File system, Linux, Technical


Tags: , , , , , , ,

Finger simulated with RPC

The link is –> /myfinger

Click on the download button and do it as tar.gz file.

There is a README file attached

Just extract it
tar xvzf .tar.gz

There is a tutorial file. just go to the project tree directory and execute

compilation overhead is solved by to naive scripts ./clientcompile and
./servercompile scripts. Could have used “make” but was lazy. So
kindly bare with that.
Sorry once again to overkill the problem

Leave a comment

Posted by on Saturday, June 4th, 2011 in Linux, RPC, Technical, Uncategorized


Tags: , , ,

Education in Kerala

This content is a mail that I sent to a mailing-list of which the identity will be kept secret for personal reasons.

Hi guys,

I  am   writing  this  mail   with  great  frustration  due   to  many
reasons. Well, I am from kerala. And  I am studying in one of the most
pioneering institutions of kerala. My  comments and reply to this mail
will be  solely based on  my experience in  the college. You  can take
this as a DISCLAIMER or whatever you feel like.

For who those wish to read this reply its a NOTICE that it may turn this
discussion to debate and it may turn political.

Q1) What problems have you faced in FOSS advocacy in your college? What are
the hurdles in FOSS/OpenSource adoption?

Let me be frank. I am a strong follower of Free Software, but some hackers
use the term OpenSource curtailing its Freedom. College has taken enough
steps to promote Free Software by installing GNU/Linux on almost all the
systems we(not only CS but also EC, EEE and ME branches) have in the lab.
I have been using linux for 4+ years. I feel it very soothing ‘coz every
day you learn *something*.

To promote FOSS we[4-5 of our group] formed a group called FOSSCET and was
giving lectures(courtesy:zyxware) on compiler technologies, GDB, BaSh
scripting etc. In the first day it brought a huge crowd but failed to
attract or seek attention of the people on the next sessions. Moreover we
were isolated thinking that we are aliens. Some of our seniors formed
“zyxware” and we seeked help from them. They supported us whole-heartedly
and even gave lectures on algorithms and so on. But later due to the indiff-
erent attitude of the students we had to discontinue the sessions.

AFAIK, people are not using Linux simply because they don’t want to learn
or try new things. Well, if they can’t WTF why being an engineer? Moreover
when I asked about the situation in other colleges came to know that their
condition was pitiable.

Thinking on “why they don’t want to try or learn new things?” I came to->
Our country or state is targetting at vocational education or job oriented
studies. Kerala alone produces 24,000+ engineers annually.
* From school age students are not encouraged to ask questions
* Teacher don’t support it because they are incapable of guiding kids
or they are simply helpless.
* So, after 10-12 years of school education it nearly converges students
questioning capability or in simple words __curiosity__ to ZERO.

School is the place where every kid starts there experiments with the world.
In school, for computer science we learned MS WORD, MS EXCEL, ORACLE
etc. Why can’t the curriculum make it as simple a word-processing package,
spreadsheet package, and DBMS with MySQL. Moreover for 11 and 12 grade CS
students, it was *turboc*. I mean WTF? Using a 16bit compiler in a 64-bit
world. Curriculum itself is flawed.

But now after learning LaTeX. I would recommend people to use LaTeX to make
documents and presentations(beamer). Anyway this may seem a big headache for
small kids to learn LaTeX(it would rather be a burden when there is a simple
WYSIWYG Free Software solution like LibreOffice).

Culture of the people in kerala(‘coz i dont know condition about other
states) is like they are very egoistic and want their kids to be engine-
ers and doctors. They don’t like kids to follow their passion. By this
the nation loses kids with inborn talent on the wide facet of knowlege.
Its a matter of prestige for parents to say that their kid is a ENGG or
a Dr.

Well, some of us maybe very lucky to fall into hands of good mentors to
not to follow the herd and start to make choices of our own.Kids when
they start thinking of career and higher studies, parents starts to say

– This is our tradition. Our family is full of doctors so you should
also be a doctor
– Their relative Appukuttan is an engineer. He earns 1lac a month.So you
also become an engineer.
– This is our prestige issue beta. please make a wise choice.

There are even people who think that Computer Science is all about browsing
chatting and emailing. [how sad]

College life is like ” Go get what you want ”
In College,we waste 1 complete year(first yr)learning the following papers

1) Basic Mechanical Engineering
2) Basic Electrical Engineering
3) Basic Electronics Engineering
4) Basic Civil Engineering
5) Physics
6) Chemistry
7) Mathematics
\8) Graphics
9) Mechanics
10)Mechanical Workshop

(Anyways not Basic Computer Science Engineering)
Except Physics and Mathematics, It seems to be a total waste to spend time
in studying useless papers which obviously the guy is not going to use in
his lifetime.

After 10-12 years of schooling the *Go get what you want* model won’t work
really well(‘coz of their deteriorated curiosity). Apart from these problems
there is the FUD factor who are willing to take a look at FOSS technologies.

However,to increase the Free Software usage in our college we setup a mirror
for ubuntu, debian and archlinux. As of now the systems within the college’s
network use our mirror. Got to see how will it be success.

Q2) What are your suggestions to improve FOSS/Linux adoption in your

I would like to emphasize that
* schooling is almost flawed
* outlook of people need to change
* political initiatives regarding education needs a radical change
which obviously isn’t going to happen in the near future.
* For CS branch,papers like Operating Systems, Computer Networks, Distribut-
ed Systems, Microprocessors(still use the 8085), Theory of Computation and
Compiler design is 5th-8th semesters. If it were in the first half of
B.Tech it would have given students enough time to explore the details and
try out something in it.

Solution :

* Make massive speech on the issues of software freedom.
* Make both govt and private schools to use FOSS technologies or make it as
a standarization criteria for private schools and colleges.
* Adoption of Free Software technologies need to be there in the accredtati-
on standards
* Change the syllabus.
* Make use of social media as a firm platform of development of FOSS, which
obviously every people use nowadays.
* Make advertisements in channels to inform them about the impending danger
on using proprietary technologies. [though sounds absurd, its the only way]

Q3) What are the methods do you consider will be good for FOSS adoption. I
will name one.. Seminar/Workshop.. What are the option option ??

FOSS is famous only among the techie community rather than common man, so
it is very important for naive users to know about FOSS. Though some of the
methods that I suggest may sound absurd, one or the other way it will surely
help us.

Community tasks

* seminar and workshops ( y )
* good, liberal and active helping and supporting community[which we have]
* Like Google does GSoC we should start a small hackathon for both school
and College students. It has to be regular and un-biased on any basis.
Else the event may sound as a competition b/w colleges and so on.
* Conferences like FOSS.IN should be made regularly.
* Well, illustrated and organized video tutorials on GNU Emacs, VIM, GDB,
GCC, familiarization of GNU Coreutils, PERL, PYTHON3, LaTeX, Qt, GTK+,
IDE’s, git, hg, drupal ; including its customizations etc [Lang:English].

Though the tutorial making thing is very difficult as developers won’t
be able to dedicate there valuable time doing this. It will be really
worth doing.

Advertising tasks

* moving speeches in public meetings regarding free software can people
atleast __think__ of switching to free software
* celebrity promotion is needed [though they may don’t give a F*** on FOSS]
it will surely seek attention of the people
* Goodies can attract students to the events and it will be a WIN-WIN
approach. eg: T-shirts etc.

Leave a comment

Posted by on Sunday, May 15th, 2011 in Personal Views, Social Views, Technical

%d bloggers like this: