Robert Baldyga
50bff0285d
Merge pull request #708 from KamilLepek/fix_perm
...
Fix permissions for verify_header.sh
2022-05-05 16:06:50 +02:00
Kamil Lepek
3464bb5da7
Fix permissions for verify_header.sh
...
Signed-off-by: Kamil Lepek <kamil.lepek@intel.com>
2022-05-05 13:49:05 +02:00
Robert Baldyga
32dbb2d355
Merge pull request #707 from Open-CAS/KamilLepek-patch-1
...
Added header verification script
2022-05-05 11:40:31 +02:00
Kamil Łepek
0ce8ced578
Added header verification script
...
Signed-off-by: Kamil Lepek <kamil.lepek@intel.com>
2022-05-04 16:52:11 +02:00
Robert Baldyga
fa6c0f3573
Merge pull request #699 from mmichal10/alleviation-for-static-analysers
...
Alleviation for static analyzers
2022-04-11 17:31:32 +02:00
Michal Mielewczyk
e8e4e00bb7
alru: explicit upcasting
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-11 15:21:37 +02:00
Michal Mielewczyk
cd4d894348
acp: skip the first bucket on recovering acp
...
Since the threshold for the first bucket is always zero and the condition to
exit from the loop is never met in the first iteration it is save to start
iterating from `1`
This change is meant to avoid confusing static code analyzers
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-11 13:14:25 +02:00
Robert Baldyga
99608c9a30
Merge pull request #698 from mmichal10/secure-fixes
...
fixes for Coverity static analysis findings
2022-04-08 16:39:31 +02:00
Michal Mielewczyk
edd42fed98
Avoid zero-size memcpy
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 16:10:28 +02:00
Michal Mielewczyk
92fa8f7e59
Remove redundant standby check
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 15:34:14 +02:00
Michal Mielewczyk
bc30d2665b
Prevent sending io to volume if it not opened
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 15:34:14 +02:00
Michal Mielewczyk
9734980be2
Free memory when failed to open core volume
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-04-08 15:34:14 +02:00
Robert Baldyga
a0bf8587a0
Merge pull request #697 from arutk/deinit_pio_in_stop
...
Add missing pio deinitialization in standby stop pipeline
2022-04-07 13:02:06 +02:00
Adam Rutkowski
8f24556cec
Add missing pio deinitialization in standby stop pipeline
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-04-07 12:23:03 +02:00
Adam Rutkowski
550a479cde
fix typo in cache mngmt
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-04-07 12:23:03 +02:00
Robert Baldyga
bbaffd96a3
Merge pull request #696 from robertbaldyga/remove-spaces-from-vol-names
...
Remove space from names of internal volumes
2022-04-06 14:00:21 +02:00
Robert Baldyga
dc9c076ef3
Remove space from names of internal volumes
...
Those names are used for creating allocators. In Linux kernel environment
starting from version 5.12 there is a kernel warning if allocator name
contains spaces. This patch resolves this problem by replacing spaces with
underscores.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-04-06 13:23:02 +02:00
Robert Baldyga
744c5d4164
Merge pull request #694 from robertbaldyga/fix-double-clp-init
...
Avoid double initialization of cleaning policy in standby mode
2022-04-04 12:55:50 +02:00
Robert Baldyga
c677f65212
Avoid double initialization of cleaning policy in standby mode
...
Cleaning policy is initialized on standby activate, after all the metadata
from primary cache is flushed and the actual recovery is being performed.
Thus initializing it earlier on standby attach is incorrect.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-04-04 12:08:27 +02:00
Robert Baldyga
65918344c0
Merge pull request #691 from arutk/fix_core_load_err
...
Fix core load cleanup loop
2022-04-01 14:57:58 +02:00
Adam Rutkowski
77380d6579
Fix core load cleanup loop
...
conf_meta->core_count is not modified during load/recovery in the latest
version. Thus in case of error in cores initialization, in order to
iterate over the initialized cores we must depend on core->added only,
regardles of conf_meta->core_count value. for_each_core() macro does
exactly this.
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-04-01 13:53:25 +02:00
Robert Baldyga
fdb32541cb
Merge pull request #690 from kmajzero/fix_error_1155
...
Fix error code for superblock checksum mismatch
2022-04-01 13:15:15 +02:00
Krzysztof Majzerowicz-Jaszcz
1b3f0d44a8
Fix error code for superblock checksum mismatch
...
Fix error code for superblock checksum mismatch.
Superblock validation now returns a proper error on checksum check fail.
Signed-off-by: Krzysztof Majzerowicz-Jaszcz <krzysztof.majzerowicz-jaszcz@intel.com>
2022-04-01 07:23:49 +00:00
Robert Baldyga
48fb745686
Merge pull request #688 from robertbaldyga/manage-valid-core-bitmap
...
Manage valid_core_bitmap properly
2022-03-31 14:32:34 +02:00
Adam Rutkowski
09b73461b4
Always modify valid_core_map together with core_count
...
.. to assure that superblock config state on drive is consistent
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-31 13:37:42 +02:00
Adam Rutkowski
77a709c086
Merge pull request #689 from mmichal10/security-fix
...
pyocf: minor security test fixes
2022-03-31 11:32:21 +02:00
Michal Mielewczyk
09d2843468
pyocf: minor security test fixes
...
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
2022-03-31 10:01:05 +02:00
Robert Baldyga
9ebb0de878
Do not modify core_count on cache load / activate
...
Increment core_count only on core addition, and decrement it only on core
removal.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-31 10:00:24 +02:00
Robert Baldyga
25434cb8d1
Explicitly validate valid_core_bitmap consistency
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-30 23:46:06 +02:00
Robert Baldyga
9c751dd2b8
Manage valid_core_bitmap properly
...
Set bit only on core addition and clean it on core removal.
This allows to avoid conf metadata modification in load / standby load
paths, which effectively prevents issues with metadata mismatch during
consequent standby activate attempts after initial activate failure.
Previously the first attempt changed the metadata, so on comparison with
metadata on drive failed on any following attempt, leading to inability
to activate the cache.
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-30 23:46:06 +02:00
Robert Baldyga
d550c8f4ef
Fix minor coding style issues
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-30 22:15:50 +02:00
Robert Baldyga
ca8531a421
Merge pull request #685 from arutk/stats2
...
Return error from stats API functions in standby
2022-03-30 11:57:10 +02:00
Robert Baldyga
bfd3f5bcba
Merge pull request #686 from jfckm/fix-potential-overflow
...
Fix potential unsigned overflow in calculations
2022-03-30 08:57:55 +02:00
Jan Musial
d1bd32add9
Fix potential unsigned overflow in calculations
...
Signed-off-by: Jan Musial <jan.musial@intel.com>
2022-03-30 08:24:39 +02:00
Adam Rutkowski
9a1f9d41b8
Return error from stats API functions in standby
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-29 22:20:04 +02:00
Robert Baldyga
a64fc61413
Merge pull request #666 from arutk/pyocf_vol_cleaniup
...
pyocf: volume changes required for failover tests
2022-03-29 10:02:01 +02:00
Robert Baldyga
cf2d4327a1
Merge pull request #667 from arutk/pyocf_failover_api
...
pyocf: failover API in Cache
2022-03-29 09:32:00 +02:00
Adam Rutkowski
03df6d3eee
Merge pull request #683 from robertbaldyga/better-error-on-crc-mismatch
...
Return more specific error on CRC mismatch
2022-03-29 09:24:52 +02:00
Robert Baldyga
af43a240d3
Return more specific error on CRC mismatch
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-28 22:42:59 +02:00
Robert Baldyga
84aa968877
Check for load error before accessing metadata content
...
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
2022-03-28 22:08:05 +02:00
Adam Rutkowski
5c39af81ca
pyocf: failover api
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 16:24:43 +02:00
Robert Baldyga
174f7b5c2b
Merge pull request #682 from jfckm/zero-cache-volume-priv
...
Zero cache_volume priv on close
2022-03-28 16:02:02 +02:00
Robert Baldyga
8e7fae110e
Merge pull request #681 from arutk/extra_seek_mio
...
Add extra data seek before data fill in mio
2022-03-28 16:00:11 +02:00
Jan Musial
43e643873a
Zero cache_volume priv on close
...
Signed-off-by: Jan Musial <jan.musial@intel.com>
2022-03-28 14:50:25 +02:00
Adam Rutkowski
6b6300c646
Add extra data seek before data fill in mio
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 14:26:51 +02:00
Robert Baldyga
223ba0b025
Merge pull request #678 from arutk/pes
...
Verify standby/active cache state in OCF entry points
2022-03-28 12:07:06 +02:00
Adam Rutkowski
0e8d02235a
pyocf: Move core/cache md5() logic to volume
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 10:37:11 +02:00
Adam Rutkowski
16c85c1560
Remove ocf_core_new_io
...
This function is equivalent to calling ocf_volume_new_io()
on core front volume
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 10:36:19 +02:00
Adam Rutkowski
05f5d49be9
switch to volume I/O interface in functional tests
...
... instead of core::new_io()
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 10:36:19 +02:00
Adam Rutkowski
9e88afad62
pyocf: cache and core exported object volumes
...
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
2022-03-28 10:35:18 +02:00