Softupdates vs gjournal

Hello!

I'm going to make some changes in my system, that's why i wanna know differences between softupdates and gjournal.
I know, that fsck run quicker on gjournal-ed filesystem, rather then on filesystem with softupdates.

But what about stability and performance?
When it's better to use softupdates and when gjournal.
 
One note about the gjournal - the journal size should be several times bigger than the machine RAM; otherwise it might panic under heavy filesystem load due to journal overflow.

As for fsck - with gjournal, it just doesn't get run after unclean shutdown.
 
trasz@ said:
As for fsck - with gjournal, it just doesn't get run after unclean shutdown.

which actually saves a lot of time on huge file systems :stud
 
I've system with gjournal-ed partitions, like
/dev/da0s2d.journal

It reboots from time to time (mostly due gjournal overflows under high write load, heh) but fsck still run on such partitions ;(
 
IIRC, you need to disable it in /etc/fstab...
 
Yes, gjournal can save _huge_ amounts of time. As for fsck - no, it doesn't have to be disabled. For example, the line in my fstab looks like this:

/dev/ad0s1a.journal / ufs rw,async,noatime 1 1

Zuborg, are you sure you have UFS configured to actually _use_ gjournal, and not just placed on top of it? If it's configured properly, you should see the following in the mount output:

/dev/ad0s1a.journal on / (ufs, asynchronous, local, noatime, gjournal)

Notice the 'gjournal' mount flag there.
 
nickolas said:
Hello!

I'm going to make some changes in my system, that's why i wanna know differences between softupdates and gjournal.
I know, that fsck run quicker on gjournal-ed filesystem, rather then on filesystem with softupdates.

But what about stability and performance?
When it's better to use softupdates and when gjournal.

I ahve a desktop computer and I try gjournal on frsh installed FreeBSD 7.1 (/usr and /var) and was slower than softupdates. I decided to go back to softupdate. I have 2GB RAM.
 
It is quite possible that gjournal will be slower than softupdates, for the simple reason it basically writes everything to the disk twice - the first time into the journal ("intent log"), second time into the filesystem ("commit"). However, it comes down to one question - is the disk throughtput really the bottleneck for you? For me, it's not. I'd rather have a guarantee of not having to run fsck at boot, even in background.
 
lumiwa said:
I ahve a desktop computer and I try gjournal on frsh installed FreeBSD 7.1 (/usr and /var) and was slower than softupdates. I decided to go back to softupdate. I have 2GB RAM.

How large are your /usr and /var filesystems?
And what about your hardware?
 
trasz@ said:
Yes, gjournal can save _huge_ amounts of time. As for fsck - no, it doesn't have to be disabled. For example, the line in my fstab looks like this:

/dev/ad0s1a.journal / ufs rw,async,noatime 1 1

Zuborg, are you sure you have UFS configured to actually _use_ gjournal, and not just placed on top of it? If it's configured properly, you should see the following in the mount output:

/dev/ad0s1a.journal on / (ufs, asynchronous, local, noatime, gjournal)

Notice the 'gjournal' mount flag there.

Sure I'm, here is example:
/dev/da0s2d.journal on /home/B/bak/0 (ufs, asynchronous, local, gjournal)

As far as I know, geom_journal clears 'dirty' bit on every ufs partitions found on gjournal-led device, so it looks like the problem is geom_journal is not able to find some ufs-partitions.
 
nickolas said:
How large are your /usr and /var filesystems?
And what about your hardware?

/usr was about 50GB and /var 7GB. I have 2G of RAM and I used 7G for each slice.

Hardware:
CPU: Intel(R) Pentium(R) 4 CPU 2.60GHz (2605.92-MHz 686-class CPU)
real memory = 2146631680 (2047 MB)
avail memory = 2090995712 (1994 MB)
ad0: 76319MB <WDC WD800JB-00FSA0 77.07W77> at ata0-master UDMA100

On the computer is just FreeBSD and I used it as a desktop computer.
 
If my memory is correct, Michael Lucas (Absolute FreeBSD 2th ed.) suggest to install gjournal on partitions over 20GB and keep soft-updates for smaller partitions.

However, on my own FS benchmarks on SATA disk, I see time increases about 20% for file creation, copy and removal, when using gjournal compared to soft-updates. I don't know if other FreeBSD users have replicated a performance penality of this magnitude.
 
Back
Top