Commit b37d105b authored by Vladimir Bashkirtsev's avatar Vladimir Bashkirtsev

Fixed tests on 32 bit systems - just reduce sizes of data for large tests

parent dcf4f32b
......@@ -40,6 +40,7 @@ all: ceph-config
patch -Np1 -d ceph-15.2.4 < ceph-15.2.4-fix_ceph_thread_timeout.patch
if [ `uname -m` = 'armv7l' ] ; then \
patch -Np1 -d ceph-15.2.4 < ceph-15.2.4-arm32_fix.patch ; \
patch -Np1 -d ceph-15.2.4 < ceph-15.2.4-arm32_fix_tests.patch ; \
fi
cd ceph-15.2.4 && ./do_cmake.sh -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_SYSCONFDIR=/etc -DCMAKE_INSTALL_LIBEXECDIR=/lib -DWITH_SPDK=OFF -DWITH_RDMA=OFF -DWITH_RADOSGW_AMQP_ENDPOINT=OFF -DWITH_PYTHON2=OFF -DWITH_PYTHON3=ON -DALLOCATOR=tcmalloc_minimal
$(MAKE) -C ceph-15.2.4/build npm_config_cache=/build/.npm NODE_OPTIONS="--max-old-space-size=3072"
......
diff -uNr ceph-15.2.4/src/test/objectstore/test_bdev.cc ceph-15.2.4-arm32_fix_tests/src/test/objectstore/test_bdev.cc
--- ceph-15.2.4/src/test/objectstore/test_bdev.cc 2020-07-01 01:10:51.000000000 +0930
+++ ceph-15.2.4-arm32_fix_tests/src/test/objectstore/test_bdev.cc 2020-11-17 15:40:57.203039097 +1030
@@ -54,8 +54,8 @@
BlockDevice::create(g_ceph_context, bdev.path, NULL, NULL,
[](void* handle, void* aio) {}, NULL));
bufferlist bl;
- // writing a bit less than 4GB
- for (auto i = 0; i < 4000; i++) {
+ // writing a bit less than 1GB
+ for (auto i = 0; i < 1000; i++) {
string s(1048576, 'a' + (i % 28));
bl.append(s);
}
diff -uNr ceph-15.2.4/src/test/objectstore/test_bluefs.cc ceph-15.2.4-arm32_fix_tests/src/test/objectstore/test_bluefs.cc
--- ceph-15.2.4/src/test/objectstore/test_bluefs.cc 2020-07-01 01:10:51.000000000 +0930
+++ ceph-15.2.4-arm32_fix_tests/src/test/objectstore/test_bluefs.cc 2020-11-17 15:41:32.066147015 +1030
@@ -206,7 +206,7 @@
}
TEST(BlueFS, very_large_write) {
- // we'll write a ~3G file, so allocate more than that for the whole fs
+ // we'll write a ~1G file, so allocate more than that for the whole fs
uint64_t size = 1048576 * 1024 * 8ull;
TempBdev bdev{size};
BlueFS fs(g_ceph_context);
@@ -228,7 +228,7 @@
BlueFS::FileWriter *h;
ASSERT_EQ(0, fs.mkdir("dir"));
ASSERT_EQ(0, fs.open_for_write("dir", "bigfile", &h, false));
- for (unsigned i = 0; i < 3*1024*1048576ull / sizeof(buf); ++i) {
+ for (unsigned i = 0; i < 1*1024*1048576ull / sizeof(buf); ++i) {
h->append(buf, sizeof(buf));
}
fs.fsync(h);
@@ -239,7 +239,7 @@
ASSERT_EQ(0, fs.open_for_read("dir", "bigfile", &h));
bufferlist bl;
BlueFS::FileReaderBuffer readbuf(10485760);
- for (unsigned i = 0; i < 3*1024*1048576ull / sizeof(buf); ++i) {
+ for (unsigned i = 0; i < 1*1024*1048576ull / sizeof(buf); ++i) {
bl.clear();
fs.read(h, &readbuf, i * sizeof(buf), sizeof(buf), &bl, NULL);
int r = memcmp(buf, bl.c_str(), sizeof(buf));
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment