IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
CID: 1124492
If 'this' pointer fails to exist then the component is hard-coded
in the gf_log if not it is dereferenced.
Change-Id: I988137d4f5ac4c9aedef7cef0c75b167a8a5c59f
BUG: 789278
Signed-off-by: arao <arao@redhat.com>
Reviewed-on: http://review.gluster.org/9639
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Quota hard-limit is supported only upto: 9223372036854775807 (int 64)
In CLI, it is allowed to set the value upto 16384PB (unsigned int 64),
this is not a valid value as the xattrop for quota accounting and
the quota enforcer operates on a signed int64 limit value.
This patches fixes the problem in CLI and allows user to set
the hard-limit value only from range 0 - 9223372036854775807
Change-Id: Ifce6e509e1832ef21d3278bacfa5bd71040c8cba
BUG: 1206432
Signed-off-by: vmallika <vmallika@redhat.com>
Reviewed-on: http://review.gluster.org/10022
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
iobuf_get and iobref_add implicitly
ref the iobuf.
Hence, it is necessary to unref iobuf
before setting it to NULL.
Change-Id: Icadd8925574cf04fe708d8090868e49356653a8e
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/9818
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Xavier Hernandez <xhernandez@datalab.es>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
If user enable bitrot from node1 which have brick then glusterd starting
bitd daemon on node1 as well as glusterd starting bitd deamon on another node2
which does not have any brick (node1 and node2 are part of cluster).
With this fix glusterd will not start bitd daemon on the node which
don't have brick.
Change-Id: Ic1c68d204221d369d89d628487cdd5957964792e
BUG: 1207029
Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com>
Reviewed-on: http://review.gluster.org/10071
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
Tested-by: Venky Shankar <vshankar@redhat.com>
When adding a new friend to the cluster, the snap volfile
are populating with wrong information for reconfigured option.
For snap volumes, reconfigured data's are filling from the
regular volumes data. This is because wrong dictionary key is
used here.
Change-Id: I659ebdc48c33419a2b825f26ce1f174abc8ea7dd
BUG: 1204636
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Reviewed-on: http://review.gluster.org/9969
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Making snapshot scheduler use the common storage
shared by nfs, snapshot and geo-rep. The meta volume
should be named as gluster_shared_storage, and it
should be mounted at "/var/run/gluster/shared_storage/".
Each component(nfs, snapshot, and geo-rep) should have
their own repos inside the shared storage, and perform
their operations in the shared storage
Change-Id: I4f670bf089c80037bd2b0716ddf743f48d7411ca
BUG: 1210344
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-on: http://review.gluster.org/10183
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Problem : During snapshot restore we anyways copy the quota conf file
after that we need to compute the checksum for that. If not, there
might be a checksum mismatch during glusterd handshake.
Solution : Compute a checksum file for quota conf file if its
present.
Change-Id: Ic4a6567c6ede9923443abf4ca59380679be88094
BUG: 1202436
Signed-off-by: Sachin Pandit <spandit@redhat.com>
Reviewed-on: http://review.gluster.org/9901
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Change of message from "will lead to deletion of snaps"
to "Will limit creation of new snaps" when setting the
snapshot limits.
Change-Id: I4732555bb35d3ad30c2cef6ea6c7da42a8edf35d
BUG: 1116263
Signed-off-by: Joseph Fernandes <josferna@redhat.com>
Reviewed-on: http://review.gluster.org/8236
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Coverity IDs:
1124453
1124454
In the first case, In the beginning of the function check is made
to see of the word_count is less than 4. If yes it returns. So it
wouldn't reach this part if that check takes the true path. So
this code is logically dead.
In second and third case, this is in false branch for word_cound <6.
So word_count can't possibly be less than 5 at this point.
Change-Id: Id5e1c81045ce7bc0ee6b7612ea54ef2b7f54b699
BUG: 789278
Signed-off-by: Nandaja Varma <nvarma@redhat.com>
Reviewed-on: http://review.gluster.org/9582
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Humble Devassy Chirammal <humble.devassy@gmail.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
CID: 1134007
The code never reaches the condition check on retlen in
ret label, hence removing the dead code.
Change-Id: Ia0108b69489bb78a2561ff8da6e00685f472ae82
BUG: 789278
Signed-off-by: arao <arao@redhat.com>
Reviewed-on: http://review.gluster.org/9644
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
A valid schedule entry in snapshot schedule must have
six elements and adhere to the following format
* * * * *
| | | | |
| | | | +---- Day of the Week (range: 1-7, 1 standing for Monday)
| | | +------ Month of the Year (range: 1-12)
| | +-------- Day of the Month (range: 1-31)
| +---------- Hour (range: 0-23)
+------------ Minute (range: 0-59)
Change-Id: Idf03a3c43a461295dd3e2026bbcd0420319dd0e0
BUG: 1209408
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-on: http://review.gluster.org/10169
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Before running any snapshot scheduler op command,
verify if /var/run/gluster/snaps/shared_storage/ exists
and if the shared storage is mounted at it.
Change-Id: Ibb6ba6c01c227cacf9a19d1bf9264500373a4ed6
BUG: 1209112
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-on: http://review.gluster.org/10135
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
In ping-timer implementation, the timer event takes a ref on the rpc
object. This ref needs to be removed after every timeout event.
ping-timer mechanism could be holding the last ref. For e.g, when a peer
is detached and its rpc object was unref'd. In this case, ping-timer
mechanism would try to acquire conn->mutex to perform the 'last' unref
while being inside the critical section already. This will result in a
deadlock.
Change-Id: I74f80dd08c9348bd320a1c6d12fc8cd544fa4aea
BUG: 1206134
Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com>
Reviewed-on: http://review.gluster.org/9613
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Previously when user start remove-brick operation on a volume then by
giving non-existing brick for remove-brick status/stop command it was
showing remove-brick status/stoping remove-brick operation on a volume.
With this fix it will validate bricks which user have given for
remove-brick status/stop command and if bricks are part of volume then
it will show statistics of remove-brick operation otherwise it will show
error "Incorrect brick <brick_name> for <volume_name>".
Change-Id: I151284ef78c25f52d1b39cdbd71ebfb9eb4b8471
BUG: 1121584
Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com>
Reviewed-on: http://review.gluster.org/9681
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Since we are not providing complete details of stopped
bricks on snapshot create error, it is better to remove
the incomplete brick details.
BUG: 1205596
Change-Id: I73386059c0d29a6cbe7f2bb6834d8b8fb393db0a
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Reviewed-on: http://review.gluster.org/9999
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
To allow handshake requests to be validated correctly in a multi network
environment, the request validation process has been improved.
The handshake request initiator will add it's peer ID the request.
The handshake request reciever will allow a request (as before) if,
- it has no peers, or
- the request came from a known peer
Identifying the known peer is done as follows.
- If the request contains a peer ID, it is matched against the IDs in
the peer list. If a match is found, the request is allowed.
- The address of the incoming request is matched against the peer
addresses in the peer list. If a match is found, the request is
allowed.
- Otherwise, the request if disallowed
Change-Id: I9eabe2935d16276bb147dfeebf8c8beb08e01411
BUG: 1207611
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.org/10122
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Geo-replications allows users to send rsync_options from
cli but while parsing, options prefixed with '--' are
treated as unrecognized apart from a few options. Because
of this rsync_options can't be set through cli. This
patch allows such options if it's a geo-rep config command.
e.g.
gluster vol geo-rep master fedora1::slave config rsync-options \
"--bwlimit=1.5m"
Change-Id: I4b4f10c0efd3f3a362ece65e697d5ce1498f84ac
BUG: 1168108
Signed-off-by: Kotresh HR <khiremat@redhat.com>
Reviewed-on: http://review.gluster.org/9198
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Currently every geo-rep operation other than start and stop
force, checks if the state-file is present or not before
performing the operation. This check is done to confirm that
the session on which the op is being performed is created.
This patch makes the start command also perform the same check
and accordingly display the correct error.
Change-Id: Ifd8bdfa3f362e91f58ead3202e2ebdbd411080e5
BUG: 1114469
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-on: http://review.gluster.org/8202
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kotresh HR <khiremat@redhat.com>
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
OpenSSL isn't thread-safe unless you register these locking and thread
ID functions. Most often the crashes would occur around
X509_verify_cert, even though it's insane that the certificate parsing
functions wouldn't be thread-safe. The bug for this was filed over
two years ago, but it didn't seem like a high priority because the bug
didn't bite anyone until it caused a spurious regression-test failure.
Ironically, that was on a test for a *different* spurious
regression-test failure, which I guess is just deserts[1] for leaving
this on the to-do list so long.
[1] Yes, it really is "deserts" in that phrase - not as in very dry
places, but from late Latin "deservire" meaning to serve well or
zealously. Aren't commit messages educational?
Change-Id: I2a6c0e9b361abf54efa10ffbbbe071404f82b0d9
BUG: 906763
Signed-off-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-on: http://review.gluster.org/10075
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
In the previous test script, for every change in export/netgroup file
the volume is restarted to accodomate those changes. New changes will
avoid those restarts.
Change-Id: I2a6052075637f8e833096c6b3fcc01139dea85e4
BUG: 1143880
Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
Reviewed-on: http://review.gluster.org/10047
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Use glusterfind list command to check a session is valid or not
glusterfind list --session <SESSION> --volume <VOLUME>
Session exists if return code($?) is zero else invalid session
Change-Id: I37faa09e4e1bf2f10725dd8e5b0cc36a36a3cad4
Signed-off-by: Aravinda VK <avishwan@redhat.com>
BUG: 1205057
Reviewed-on: http://review.gluster.org/10154
Reviewed-by: Kotresh HR <khiremat@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
These are suspected of causing core dumps during regression tests,
leading to spurious failures. Per email conversation, since this
isn't a supported feature anyway, the tests are being removed to
facilitate testing of features we do support.
Change-Id: I7fd5c76d26dd6c3ffa91f89fc10469ae3a63afdf
BUG: 1195415
Signed-off-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-on: http://review.gluster.org/10167
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
and dead code removal
CID: 1124609
CID: 1124596
CID: 1124471
CID: 1124475
CID: 1124476
The pointer variables are checked before
dereferencing and the dead code is removed
BUG: 789278
Change-Id: Ia532733a64401d71ccf1f2b6e434d7bc910e0ed1
Signed-off-by: arao <arao@redhat.com>
Reviewed-on: http://review.gluster.org/10083
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Using __attribute__ ((__packed__)) for object signature xattr
saves some bytes (7 bytes to be particular) occupied by the
extended attribute on-disk as compared to the unpacked format.
Change-Id: I91a6a0a54aa60e6fd8c357d72f7601b6ed213f2d
BUG: 1170075
Signed-off-by: Venky Shankar <vshankar@redhat.com>
Reviewed-on: http://review.gluster.org/10161
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Previously command "gluster volume help | grep bitrot" was not giving
sufficient information for bitrot.
With this fix command "gluster volume help" will give appropriate information
for bitrot.
Change-Id: Ic385c760d4ecbfb16ff5d90dba8940b3616035e5
BUG: 1207532
Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com>
Reviewed-on: http://review.gluster.org/10133
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
If multiple files with the same name but different gfids
exist on different subvolumes, dht_lookup_everywhere_cbk()
copies the gfid from the last received response into
local->gfid but does not update the local->stbuf structure.
dht_linkfile_create() uses the value in local->gfid, but
dht_linkfile_attr_heal() uses the one in local->stbuf, causing
a mismatch and failure while trying to heal the linkfile attrs.
Change-Id: I80d152be95b42d736c5d9182b955f42e374b82a5
BUG: 1205785
Signed-off-by: Nithya Balachandran <nbalacha@redhat.com>
Reviewed-on: http://review.gluster.org/9998
Reviewed-by: Susant Palai <spalai@redhat.com>
Reviewed-by: Shyamsundar Ranganathan <srangana@redhat.com>
Tested-by: Shyamsundar Ranganathan <srangana@redhat.com>
ctx is passed to gf_log_inject_timer_event() and pass through to
__gf_log_inject_timer_event() where the struct members are getting
dereferenced, and can cause crash if the passed ctx is null. This patch
avoids the issue.
Change-Id: I153dbb5d3744898429139e3d40bb4f0e9093632a
BUG: 1208118
Signed-off-by: Humble Devassy Chirammal <hchiramm@redhat.com>
Reviewed-on: http://review.gluster.org/10102
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
fix bug with reading pid file to determine if ganesha.nfsd is running
Change-Id: I4050a119e2be93578045a221b67f616e152546d9
BUG: 1188184
Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.org/10163
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
With each inode write FOP, the size and block count of the file will be
updated within the xattr. There are two 64 byte fields that are
intentionally left blank for now for future use when consistency
guarantee is introduced later in sharding.
Change-Id: I40a2e700150c1f199a6bf87909f063c84ab7bb43
BUG: 1207603
Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
Reviewed-on: http://review.gluster.org/10097
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
This patch adds support for xdata in both the
request and response path of syncops.
Few calls like lookup already had the support;
have renamed variables in few places to maintain
uniformity.
xdata passed downwards is known as xdata_in
and xdata passed upwards is known as xdata_out.
There is an old patch by Jeff Darcy at
http://review.gluster.org/#/c/8769/3 which does the
same for some selected calls. It also brings in
xdata support at gfapi level.
xdata support at gfapi level would be introduced
in subsequent patches.
Change-Id: I340e94ebaf2a38e160e65bc30732e8fe1c532dcc
BUG: 1158621
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/9859
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Eventhough we have release branches, its better to keep track of
upgrade procedures of previous versions. This way we always have
pointers to upgrade process.
Change-Id: If7a5af0e9efc36bf0343487819a4d311775e65a8
BUG: 1206539
Signed-off-by: Humble Devassy Chirammal <hchiramm@redhat.com>
Reviewed-on: http://review.gluster.org/10107
Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com>
Reviewed-by: Lalatendu Mohanty <lmohanty@redhat.com>
Tested-by: Lalatendu Mohanty <lmohanty@redhat.com>
This fix will solve the heating of the files during the promotion
or demotion.
Promotion:
~~~~~~~~~
When a file gets promoted it get the current time stamp
during creation only, but following writes or reads during the
migration wont heat the file.
Demotion:
~~~~~~~~
When a file gets demoted it get the wind/unwind time stamp is set to
zero. The following writes or reads during the migration wont heat
the file.
What is remaining ?
~~~~~~~~~~~~~~~~~
Bug 1209129 ( https://bugzilla.redhat.com/show_bug.cgi?id=1209129 )
Inspite of this fix there is still a issue remaining, i.e the heat of
the file is not keep intact during a internal rebalance activity i.e
a rebalance within a tier.
Change-Id: I01e82dc226355599732d40e699062cee7960b0a5
BUG: 1207867
Signed-off-by: Joseph Fernandes <josferna@redhat.com>
Signed-off-by: Dan Lambright <dlambrig@redhat.com>
Signed-off-by: Joseph Fernandes <josferna@redhat.com>
Reviewed-on: http://review.gluster.org/10080
Reviewed-by: Shyamsundar Ranganathan <srangana@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Coverity CID 1288819
strncpy executed with a limit equal to the target array
size potentially leaves the target string not null terminated.
Make sure the copied string is a valid 0 terminated string.
Change-Id: Ie2d2970f37840146aa18724be3b89e93194c8160
BUG: 789278
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-on: http://review.gluster.org/10062
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
Tested-by: Venky Shankar <vshankar@redhat.com>
ec_manager_xxx() function for [f]set/[f]remove xattr is exactly same except the
reporting part. So moved that to common function and use same
ec_manager_xattr() function for all these fops.
Change-Id: Iaa57023b800f8d1f3f6a827f4ceba9b0a0337336
BUG: 1199767
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/10036
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Xavier Hernandez <xhernandez@datalab.es>
We did not set up the graph properly for hot tiers with replicated
subvolumes. Also add check that the file has not already been moved
by another replicated brick on the same node.
Change-Id: I9adef565ab60f6774810962d912168b77a6032fa
BUG: 1206517
Signed-off-by: Dan Lambright <dlambrig@redhat.com>
Reviewed-on: http://review.gluster.org/10054
Reviewed-by: Joseph Fernandes <josferna@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
This patch fixes a handful of problem with scrubber which
are detailed below.
Scrubber used to skip objects for verification due to missing
fd iterface to fetch versioning extended attributes. Similar
to the inode interface, an fd based interface in POSIX is now
introduced.
Moreover, this patch also fixes potential false reporting by
scrubber due to:
An object gets dirtied and signed when scrubber is busy
calculatingobject checksum. This is fixed by caching the
signed version when an object is first inspected for
stalenes, i.e., during pre-compute stage. This version is
used to verify checksum in the post-compute stage when the
signatures are compared for possible corruption.
Side effect of _not_ sending signature length during signing
resulted in "truncated" signature to be set for an object.
Now, at the time of signing, the signature length is sent
and is used in place of invoking strlen() to get signature
length (which could have possible 00s). The signature length
itself is not persisted in the signature xattr, but is
calculated on-the-fly by substracting the xattr length by
the "structure" header size.
Some of the log entries are made more meaningful (as and aid
for debugging).
Change-Id: I938bee5aea6688d5d99eb2640053613af86d6269
BUG: 1207624
Signed-off-by: Venky Shankar <vshankar@redhat.com>
Reviewed-on: http://review.gluster.org/10118
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
This patch introduces basic object versioning test(s) which
is required for bitrot detection to work correctly. Basic
test(s) such as opening a file in read-only mode, single
open, multiple open()s are covered on FUSE mount _only_ as
stub does not support anonymous fds yet. For this reason,
the test case disables open-behind.
Actual verification is implemented as a C source which
makes use of the same on-disk data structures as used by
the stub code. The data structures are moved to separate
header file which is included by the test script. Such
modularization helps in future enhancements to keep the
version "data type" opaque and provide handful of APIs
version checking (equal/greater/etc..).
[
This is just a start and should grow over time as stub
is enhanced and codebase matures.
]
Change-Id: Ibee20e65a15b56bbdd59fd2703f9305b115aec7a
BUG: 1201724
Signed-off-by: Venky Shankar <vshankar@redhat.com>
Reviewed-on: http://review.gluster.org/10140
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>