Zimbra Next Generation Modules/Zimbra NG HSM/Checking the message BLOBs health: Difference between revisions

m (1 revision imported: Zimbra NG)
 
Line 1: Line 1:
<div class="col-md-12"><br></div>
#REDIRECT [[Zimbra_NG_Modules/Zimbra_NG_HSM/Checking_the_message_BLOBs_health]]
<div class="col-md-12"><br></div>
<ol class="breadcrumb">
  <li>[[Main Page|Zimbra Wiki]]</li>
  <li>[[Zimbra_Next_Generation_Modules]]</li>
  <li>[[Zimbra_NG_HSM]]</li>
  <li class="active">Zimbra NG HSM - Checking the message BLOBs health</li>
</ol>
__NOTOC__
<div class="col-md-12"><br /></div>
<div class="col-md-9">
    <h2 class="title-header" style="padding-bottom: 9px; border-bottom: 4px solid #0087c3;">Zimbra NG HSM - Checking the message BLOBs health</h2>
    <div class="col-md-12">
        <div class="ibox-content">
            <div class="post animated fadeInLeft animation-delay-8" style="padding-top:5px">
                <div class="panel panel-default">
                    <div class="panel-body">
                        <h5 class="post-title">Zimbra NG HSM - Checking the message BLOBs health</h5>
                        <div class="row">
 
== Volumes and BLOBs ==
In Zimbra, all message data is stored into the so-called "Message [[Zimbra_Next_Generation_Modules/Zimbra_NG_HSM/Hierarchical_Storage_Management#Stores.2C_Volumes_and_Policies|Volumes]]" in the form of .msg files archived in a strict directory tree.
 
Every item in Zimbra is composed by 2 parts: the "Data", which is the actual content of the item, and the "Metadata" which is a set of additional informations regarding the item. A BLOB file is a file containing the "Data" part of an item, stored in a Message Volume. The exact path of the file depends on different factors.
 
==== BLOB path example====
The '''/opt/zimbra/store/0/128/msg/2/12124-23531.msg''' file's location and name are calculated as follows
 
'''/opt/zimbra/store/''' is the volume's path.
'''0/''' is a number calculated by applying a right bitshift on the mailbox_id of the owner of the item of a number of bits set in the "mailbox_bits" property of the volume.
'''128/''' is the mailbox_id of the owner of this item.
'''msg/''' is a default subfolder for message BLOBs.
'''2/''' is a number calculated by applying a right bitshift on the itemID of the item of a number of bits set in the "file_bits" property of the volume.
'''12124-23531.msg''' is the name of the file in the '''[itemID]'''-'''[revision]'''.msg form.
 
== What can go wrong==
Different issues can affect the health of a volume. The most common are:
* '''Missing BLOB''': Metadata for an item are stored in Zimbra's database but the corresponding BLOB file cannot be found.
* '''Unexpected BLOB''': A BLOB file exists but the corresponding metadata cannot be found in Zimbra's database.
* '''Size Mismatch''': Item size informations stored in the metadata are different than the corresponding BLOB file's size.
* '''Digest Mismatch''': Item digest informations stored in the metadata are different than the corresponding BLOB file's digest.
 
"Unexpected BLOB" errors are commonly caused by a problem in the deletion process of an item.
 
"Missing BLOB" errors are particularily pesky, as since the item's metadata exists in Zimbra's database this very item is usually visible in the Zimbra Web Client. An error will be shown to the user when trying to access an item which BLOB file is missing.
 
== Checking the BLOB status with Zimbra NG HSM ==
Zimbra NG HSM includes a CLI command that analyzes all BLOBs in a volume or mailbox to find out any possible issue: "doCheckBlobs"
 
<pre><nowiki>
Syntax:
  zxsuite powerstore doCheckBlobs {start} [attr1 value1 [attr2 value2]]
 
 
PARAMETER LIST
 
NAME                TYPE                  EXPECTED VALUES
action(M)          String                "start"
volumeID(O)        String
mailboxID(O)        String
 
(M) == mandatory parameter, (O) == optional parameter
 
Usage examples:
zxsuite powerstore doCheckBlobs start
Perform a BLOB coherency check on all message volumes
 
zxsuite powerstore doCheckBlobs start volumeID 1,3
Perform a BLOB coherency check on volumes 1 and 3
 
zxsuite powerstore doCheckBlobs start mailboxID 2,9,27
Perform a BLOB coherency check on mailboxes 2,9 and 27
</nowiki></pre>
 
==== Fixing BLOB errors ====
Zimbra offers a CLI command to fix some BLOB issues: `zmblobchk`.
 
Also, one of the most common causes of BLOB/volume issues is bound to filesystem permissions, which can be fixed using the `zmfixperms` Zimbra CLI command.
 
A great article about "Missing BLOB" errors and all related informations can be found on the Zimbra Wiki at http://wiki.zimbra.com/wiki/Ajcody-Notes-No-Such-Blob.
 
Extreme caution is advised when dealing with this kind of issues, as dealing with volumes and BLOB files level means dealing with Zimbra's "raw data". Before taking any action make sure that you find out the cause of the issue and that you have a backup of your system in order to easily revert any possible data loss.
                        </div>
                    </div>
                    <div class="col-md-9">
                        <div class="panel-footer">
                            <p><i class="fa fa-clock-o"></i> Aug 25, 2016 - [https://www.zimbra.com/email-server-software/ Know more »]</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<div class="col-md-3"><br /></div>
<div class="col-md-3">
    <div class="panel panel-zimbrared-light-border">
        <div class="panel-heading">
            <h3 class="panel-title"><i class="fa fa-gear pull-left"></i> Zimbra Next Generation Modules</h3>
        </div>
        <div class="panel-body">
            {{ZNG}}
        </div>
    </div>
</div>
<div class="col-md-3">
    <div class="panel panel-primary-light-border">
        <div class="panel-heading">
            <h3 class="panel-title"><i class="fa fa-info-circle pull-left"></i> Zimbra Next Generation Modules Resources</h3>
        </div>
        <div class="panel-body">
            {{ZNGL}}
        </div>
    </div>
</div>
<div class="clearfix"></div>
<div class="col-md-12"><br></div>
{{FH}}

Latest revision as of 13:18, 29 November 2017

Jump to: navigation, search