You are not logged in.

#1 2005-11-14 02:57:34

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

ext3 with dir_index - holy cow!

And to think I once thought this was all hype...

You see, I was getting grief from pacman on XFS. Not sure exactly what was going on there, but anyway... Just for kicks, I reinstalled on ext3 with directory indexing. You know, mke2fs -j -O dir_index, for both root and /home partitions.

It's quite freaky actually. Everything is visibly faster than on ReiserFS. :shock:

Why the heck isn't dir_index enabled by default?!

Offline

#2 2005-11-14 03:46:10

deficite
Member
From: Augusta, GA
Registered: 2005-06-02
Posts: 693

Re: ext3 with dir_index - holy cow!

Yes, dir_index is very nice indeed. I have no clue why it isn't enabled by default, but if I remember right they're considering making the new installer use dir_index by default when formatting ext3 partitions.

Offline

#3 2005-11-14 04:02:48

Cam
Member
From: Brisbane, Aus
Registered: 2004-12-21
Posts: 658
Website

Re: ext3 with dir_index - holy cow!

Somebosy posted a short how-to a while ago on speeding up ext3 filesystems. I'm not 100% sure whether it was here or at LQ.org but I think it might have been here. Anyway, I did it and yeah, everything is running considerably faster. I can't compare it to Reiser though, never used anything but ext2 and more recently, ext3.

Offline

#4 2005-11-14 04:04:15

Cam
Member
From: Brisbane, Aus
Registered: 2004-12-21
Posts: 658
Website

Re: ext3 with dir_index - holy cow!

Offline

#5 2005-11-14 10:28:38

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

Re: ext3 with dir_index - holy cow!

I think that's where I first found out about this... Dang. Thanks, Codergeek!

Offline

#6 2005-11-14 16:00:32

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ext3 with dir_index - holy cow!

Hmmm I've never noticed this before - are there any issues with doing this on a stable system?  I don't want to screw things up by messing with the filesystem.

Offline

#7 2005-11-16 23:33:38

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

Gullible Jones wrote:

I think that's where I first found out about this... Dang. Thanks, Codergeek!

Happy to be of help. big_smile


~Peter~

Offline

#8 2005-11-17 00:24:47

mmccaskill
Member
From: NC
Registered: 2005-02-21
Posts: 163

Re: ext3 with dir_index - holy cow!

So overall, is ext3 dir_index better than reiserfs? jfs?

Offline

#9 2005-11-17 01:20:26

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

Re: ext3 with dir_index - holy cow!

I don't think it's quite as good as Reiser for small files - not quite sure there, there's not really much way for me to tell - but the read speeds seem better than Reiser, XFS, or JFS.

There is a disadvantage, that it is not as storage efficient as ReiserFS, since there's no tail packing. On current hardware, this is not really a problem.

Offline

#10 2005-11-17 05:33:23

mmccaskill
Member
From: NC
Registered: 2005-02-21
Posts: 163

Re: ext3 with dir_index - holy cow!

Well considering that I have a AMD64 3200 (still running 32bit until 64bit stable) with WD Raptor 74GB I'm not so sure I would notice much of a difference anyway.

Offline

#11 2005-11-22 20:47:23

nuopus
Member
From: Mesa, AZ
Registered: 2005-03-09
Posts: 60

Re: ext3 with dir_index - holy cow!

Is it possible to get this indexing feature on an existing root file system?

Offline

#12 2005-11-22 20:57:26

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: ext3 with dir_index - holy cow!

As the codergeek's howto points out, just boot into some live cd and execute

tune2fs -O dir_index /dev/hdXY
e2fsck -D /dev/hdXY

Offline

#13 2005-11-23 00:01:57

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

Gullible Jones wrote:

There is a disadvantage, that it is not as storage efficient as ReiserFS, since there's no tail packing. On current hardware, this is not really a problem.

One must balance  these things. The more storage efficient a filesystem becomes, the higher probability that files may get fragmented heavily. If you're really that worried about storage efficiency though, you could always create an ext2/ext3 FS with KJiB block sizes and 1 inode/block. That almost certainly will cut your performance though. *shrug*


~Peter~

Offline

#14 2005-11-23 00:36:24

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: ext3 with dir_index - holy cow!

lucke wrote:

As the codergeek's howto points out, just boot into some live cd and execute

tune2fs -O dir_index /dev/hdXY
e2fsck -D /dev/hdXY

Or just do it on your running system and reboot. 8)


·¬»· i am shadowhand, powered by webfaction

Offline

#15 2005-11-23 00:48:22

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

shadowhand wrote:
lucke wrote:

As the codergeek's howto points out, just boot into some live cd and execute

tune2fs -O dir_index /dev/hdXY
e2fsck -D /dev/hdXY

Or just do it on your running system and reboot. 8)

Erm. fsck'ing a live filesystem can cause  massive data corruption!  :!:


~Peter~

Offline

#16 2005-11-23 01:06:18

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: ext3 with dir_index - holy cow!

codergeek42 wrote:
shadowhand wrote:
lucke wrote:

As the codergeek's howto points out, just boot into some live cd and execute

tune2fs -O dir_index /dev/hdXY
e2fsck -D /dev/hdXY

Or just do it on your running system and reboot. 8)

Erm. fsck'ing a live filesystem can cause  massive data corruption!  :!:

Oh hey... I didn't notice the e2fsck line. Shutdown after using tune2fs with

shutdown -F -r

to force a fsck on reboot. smile


·¬»· i am shadowhand, powered by webfaction

Offline

#17 2005-11-23 01:24:03

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

That's the right way to do it. smile


~Peter~

Offline

#18 2005-11-23 01:42:52

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

Re: ext3 with dir_index - holy cow!

You could also use magic sysrq to remount all filesystems read-only.

BTW, Codergeek, is it necessary to use '-O has_journal' when using tune2fs to enable full journalling?

Offline

#19 2005-11-23 03:41:48

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

Gullible Jones wrote:

You could also use magic sysrq to remount all filesystems read-only.

I just boot to a LiveCD. It's simpler (imho). smile

BTW, Codergeek, is it necessary to use '-O has_journal' when using tune2fs to enable full journalling?

Not necessarily. I have that in there to add a journal to ext2 filesystems.


~Peter~

Offline

#20 2005-11-23 05:56:39

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: ext3 with dir_index - holy cow!

Entered the dir_index code in two kernels, 2.6.13 and 2.6.14.

In each case, used the shutdown -F -r now ... procedure.

In each case, I had to reboot twice in order to complete the fsck of the partition.

Just a note on how it went for my system.

The system is up and running on either kernel.


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#21 2005-11-23 11:03:47

nightfrost
Member
From: Sweden
Registered: 2005-04-16
Posts: 647

Re: ext3 with dir_index - holy cow!

I was actually looking for this one over at the wiki a while back, with no luck. How about moving it there? I could do some copy & pasting myself, if you guys feel like you got better things to do. What do you say?

Offline

#22 2005-11-23 11:16:36

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: ext3 with dir_index - holy cow!

Sure, it belongs to the WIKI.

Sounds disturbing...

Offline

#23 2005-11-23 11:43:08

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

Re: ext3 with dir_index - holy cow!

Not really.

BTW, I tried full journalled mode... I don't know what's going on with your HDDs, Codergeek, but on this end full journalling causes write times to double as one might expect.

Offline

#24 2005-11-23 16:16:16

codergeek42
Member
From: Anaheim, CA (USA)
Registered: 2005-06-03
Posts: 90
Website

Re: ext3 with dir_index - holy cow!

@Gullible Jones: It does not seem to cause any significant reduction in terms of throughput or interactivity though. smile


~Peter~

Offline

#25 2005-11-23 17:32:29

Gullible Jones
Member
Registered: 2004-12-29
Posts: 4,863

Re: ext3 with dir_index - holy cow!

No, but it's annoying as hell when you're copying stuff around. I'll stick with metadata journalling, thank you. May be slightly riskier if something bad happens, but my data is not incredibly important.

Offline

Board footer

Powered by FluxBB