# [FreeNAS] ZFS and disabling ZIL



## Karlostavitch (Jun 4, 2013)

Ok, now I know the general recommendation is do not disable ZIL but is it ok to disable in certain situations?

In my situation, I am dumping ghetto VCB VMware images onto a FreeNAS NFS share, that's all. In the situation that there is a power failure during backup, then the backup will fail anyway and the image will be useless to me anyway. The performance benefit without ZIL enabled is huge, but the reason I am asking is because I am not sure exactly what the risks are, does anyone out there know?

Thanks


----------



## SirDice (Jun 4, 2013)

> The combination of ZFS and NFS stresses the ZIL to the point that performance falls significantly below expected levels. The best solution is to put the ZIL on a fast SSD (or a pair of SSDs in a mirror, for added redundancy). The next best solution is to disable ZIL with the following setting in loader.conf (up to ZFS version 15):
> 
> ```
> vfs.zfs.zil_disable="1"
> ...


https://wiki.freebsd.org/ZFSTuningGuide


----------



## Karlostavitch (Jun 5, 2013)

Thanks for the reply, @SirDice, those are the actual articles which lead me to here for more information.



> Disabling ZIL is not recommended where data consistency is required (such as database servers) but will not result in file system corruption



Yes, I would like data consistency within my backed up images, but those files are written once and never updated, only completely overwritten in rotation unlike a database server whose files are constantly updated; that is where I believe the greatest risk of inconsistency is.


----------



## SirDice (Jun 5, 2013)

Karlostavitch said:
			
		

> Yes, I would like data consistency within my backed up images, but those files are written once and never updated, only completely overwritten in rotation unlike a database server whose files are constantly updated; that is where I believe the greatest risk of inconsistency is.


Yep, that's what I understood of it too. Database servers tend to write regularly and because of ZFS's copy-on-write and a few other things this can get hairy when the power fails right in the middle of an update. The ZIL makes sure this doesn't cause any inconsistencies. This shouldn't be of a concern for you. If the power goes out during a backup cycle the backup fails and would need to be done again anyway. So it shouldn't be an issue if that partial backup file ends up corrupt.


----------



## Karlostavitch (Jun 6, 2013)

Hi @SirDice,

Thanks for that, exactly what I was looking for. 

Cheers,


----------

