def SetInfo(self, text):
    # Replace invalid characters
    text = re.sub("^[^A-Za-z0-9_+.]", "_", text)
    text = re.sub("[^-A-Za-z0-9_+.]", "_", text)

    # Only up to 128 characters are allowed
    text = text[:128]

    # Call the External Storage's setinfo script,
    # to set metadata for an existing Volume inside the External Storage
    _ExtStorageAction(constants.ES_ACTION_SETINFO, self.unique_id,
                      self.ext_params, metadata=text,
                      name=self.name, uuid=self.uuid)
Update metadata with info text.
dataset/ETHPy150Open ganeti/ganeti/lib/storage/extstorage.py/ExtStorageDevice.SetInfo