Package vitastor: Specfile
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 | %global _unpackaged_files_terminate_build 1 %define _stripped_files_terminate_build 1 %set_verify_elf_method strict Name: vitastor Version: 1.6.0 Release: alt1.1 Summary: Vitastor, a fast software-defined clustered block storage Group: System/Base License: VNPL-1.1 Url: https://vitastor.io/ Source0: %name-%version.tar Source2: cpp-btree.tar Source3: json11.tar Patch: %name-%version.patch Patch2000: %name-e2k.patch BuildRequires(pre): rpm-macros-cmake BuildRequires: cmake gcc-c++ ninja-build BuildRequires: pkgconfig(liburing) BuildRequires: pkgconfig(libnl-3.0) pkgconfig(libnl-genl-3.0) BuildRequires: libgperftools-devel BuildRequires: node >= 10 BuildRequires: libjerasure-devel pkgconfig(libisal) BuildRequires: libgf-complete-devel BuildRequires: rdma-core-devel # For PVE %ifarch x86_64 aarch64 BuildRequires(pre): rpm-build-perl BuildRequires: pve-storage %add_perl_lib_path %buildroot%perl_vendor_privlib %endif %description Vitastor is a small, simple and fast clustered block storage (storage for VM drives), architecturally similar to Ceph which means strong consistency, primary-replication, symmetric clustering and automatic data distribution over any number of drives of any size with configurable redundancy (replication or erasure codes/XOR). %package common Summary: Vitastor SDS Common Group: System/Base BuildArch: noarch %description common Common utilities for Vitastor. %package mon Summary: Vitastor SDS monitor service Group: System/Base BuildArch: noarch Requires: node Requires: lp_solve Requires: %name-common = %EVR %description mon Vitastor SDS monitor service. Monitor is a separate daemon that watches cluster state and handles failures. %package osd Summary: Vitastor SDS Object Storage Daemon Group: System/Base Requires: %name-common = %EVR Requires: %name-client = %EVR Requires: sfdisk util-linux parted udev %description osd Vitastor SDS Object Storage Daemon is a process that stores data and serves read/write requests. %package client Summary: Vitastor SDS client Group: System/Base %description client Vitastor client library and command-line interface. %package nbd Summary: Vitastor SDS NBD proxy Group: System/Base %description nbd NBD stands for "Network Block Device", but in fact it also functions as "BUSE" (Block Device in UserSpace). NBD is currently required to mount Vitastor via kernel. NBD slighly lowers the performance due to additional overhead, but performance still remains decent. Vitastor Kubernetes CSI driver is based on NBD. %package nfs Summary: Vitastor SDS NFS proxy Group: System/Base %description nfs Vitastor has a simplified NFS 3.0 proxy for file-based image access emulation. It's not suitable as a full-featured file system, at least because all file/image metadata is stored in etcd and kept in memory all the time - thus you can't put a lot of files in it. However, NFS proxy is totally fine as a method to provide VM image access and allows to plug Vitastor into, for example, VMWare. It's important to note that for VMWare it's a much better access method than iSCSI, because with iSCSI we'd have to put all VM images into one Vitastor image exported as a LUN to VMWare and formatted with VMFS. VMWare doesn't use VMFS over NFS. NFS proxy is stateless if you use immediate_commit=all mode (for SSD with capacitors or HDDs with disabled cache), so you can run multiple NFS proxies and use a network load balancer or any failover method you want to in that case. %package -n lib%name-client Group: System/Libraries Summary: Vitastor SDS user-space client library License: VNPL-1.1 OR GPL-2.0+ %description -n lib%name-client Vitastor SDS user-space client library. %package -n lib%name-blk Group: System/Libraries Summary: Vitastor SDS blk library %description -n lib%name-blk Vitastor SDS blk library. %package -n lib%name-kv Group: System/Libraries Summary: Vitastor shared key/value database library %description -n lib%name-kv Vitastor shared key/value database library. %package -n lib%name-devel Group: Development/C++ Summary: Vitastor SDS headers of client and blk library License: VNPL-1.1 OR GPL-2.0+ Requires: lib%name-blk = %EVR lib%name-client = %EVR %description -n lib%name-devel This package contains libraries and headers needed to develop programs that use Vitastor SDS library. %package -n pve-storage-vitastor Group: System/Servers Summary: Vitastor Proxmox VE Plugin License: VNPL-1.1 OR GPL-2.0+ Requires: /usr/bin/vitastor-cli Requires: /usr/bin/vitastor-nbd Requires: pve-manager pve-storage %description -n pve-storage-vitastor Vitastor Proxmox VE Plugin. %prep %setup %patch -p1 %ifarch %e2k %patch2000 -p1 %endif tar -xf %SOURCE2 -C cpp-btree tar -xf %SOURCE3 -C json11 sed -i 's|fdiagnostics-color=always|fdiagnostics-color=auto|' src/CMakeLists.txt %build %add_optflags %(getconf LFS_CFLAGS) %cmake \ -DWITH_QEMU=OFF \ -DWITH_FIO=OFF \ -GNinja %cmake_build %install %cmake_install mkdir -p %buildroot{%_sysconfdir,%_libexecdir,%_localstatedir}/%name cp -r mon %buildroot%_libexecdir/%name mkdir -p %buildroot{%_unitdir,%_udevrulesdir} install -m 0644 mon/vitastor.target %buildroot%_unitdir install -m 0644 mon/vitastor-mon.service %buildroot%_unitdir install -m 0644 mon/vitastor-osd@.service %buildroot%_unitdir install -m 0644 mon/90-vitastor.rules %buildroot%_udevrulesdir # Install PVE plugin %ifarch x86_64 aarch64 install -D -m 0644 patches/VitastorPlugin.pm %buildroot%perl_vendor_privlib/PVE/Storage/Custom/VitastorPlugin.pm %endif # Cleanup rm -f %buildroot%_libexecdir/%name/mon/90-vitastor.rules rm -f %buildroot%_libexecdir/%name/mon/make-etcd rm -f %buildroot%_libexecdir/%name/mon/vitastor-mon.service rm -f %buildroot%_libexecdir/%name/mon/vitastor-osd@.service rm -f %buildroot%_libexecdir/%name/mon/vitastor.target %pre common groupadd -r -f %name 2>/dev/null ||: useradd -r -g %name -s /sbin/nologin -c "Vitastor daemons" -M -d %_localstatedir/%name %name 2>/dev/null ||: %post mon %post_service vitastor-mon %preun mon %preun_service vitastor-mon #%post osd #systemctl daemon-reload ||: #if [ "$1" -eq 1 ]; then # systemctl -q preset vitastor-osd@\*.service vitastor-osd.target ||: #else # systemctl try-restart vitastor-osd.target ||: #fi #%preun osd #if [ "$1" -eq 0 ]; then # systemctl --no-reload -q disable vitastor-osd@\*.service vitastor-osd.target ||: # systemctl stop vitastor-osd@\*.service vitastor-osd.target ||: #fi %post -n pve-storage-vitastor service pvedaemon condrestart ||: %postun -n pve-storage-vitastor if [ $1 = 0 ]; then service pvedaemon condrestart ||: fi %files common %doc README.md README-ru.md VNPL-1.1.txt GPL-2.0.txt %attr(770,root,%name) %dir %_localstatedir/%name %attr(770,root,%name) %dir %_sysconfdir/%name %files osd %_bindir/%name-osd %_bindir/%name-disk # ? may be to utils package? %_bindir/%name-dump-journal %_unitdir/%name-osd@.service %_unitdir/%name.target %_udevrulesdir/90-%name.rules %files mon %_libexecdir/%name %_unitdir/%name-mon.service %files client %_bindir/%name-cli %_bindir/%name-rm %_bindir/vita %files nbd %_bindir/%name-nbd %files nfs %_bindir/%name-nfs %_bindir/vitastor-kv %files -n lib%name-blk %_libdir/lib%{name}_blk.so.* %files -n lib%name-client %_libdir/lib%{name}_client.so.* %files -n lib%name-kv %_libdir/lib%{name}_kv.so.* %files -n lib%name-devel %_bindir/vitastor-kv-stress %_libdir/*.so %_includedir/* %_pkgconfigdir/*.pc %ifarch x86_64 aarch64 %files -n pve-storage-vitastor %perl_vendor_privlib/PVE/Storage/Custom/VitastorPlugin.pm %endif %changelog * Wed Apr 24 2024 Ilya Kurdyukov <ilyakurdyukov@altlinux.org> 1.6.0-alt1.1 - fixed build for Elbrus * Thu Apr 11 2024 Alexey Shabalin <shaba@altlinux.org> 1.6.0-alt1 - 1.6.0 * Sat Mar 16 2024 Ilya Kurdyukov <ilyakurdyukov@altlinux.org> 1.4.8-alt1.1 - fixed build for Elbrus * Sun Mar 03 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.8-alt1 - 1.4.8 * Thu Feb 22 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.7-alt1 - 1.4.7 * Tue Feb 20 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.5-alt1 - 1.4.5 * Wed Feb 14 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.4-alt1 - 1.4.4 * Fri Feb 09 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.3-alt1 - 1.4.3 * Tue Jan 23 2024 Alexey Shabalin <shaba@altlinux.org> 1.4.1-alt1 - 1.4.1 * Mon Dec 04 2023 Alexey Shabalin <shaba@altlinux.org> 1.3.1-alt1 - 1.3.1 * Thu Nov 09 2023 Alexey Shabalin <shaba@altlinux.org> 1.2.0-alt1 - 1.2.0 * Fri Nov 03 2023 Alexey Shabalin <shaba@altlinux.org> 1.1.0-alt1 - 1.1.0 (hotfix-1.1.0 branch) * Wed Oct 18 2023 Alexey Shabalin <shaba@altlinux.org> 1.0.0-alt1 - 1.0.0 (hotfix-1.0.0 branch) * Tue Aug 29 2023 Ilya Kurdyukov <ilyakurdyukov@altlinux.org> 0.9.6-alt3.1 - fixed build for Elbrus * Mon Aug 28 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.6-alt3 - update vitastor-osd@.service for send logs to journald * Thu Aug 03 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.6-alt2 - cleanup files in mon package - enable post and preun service for vitastor-mon * Mon Jul 31 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.6-alt1 - 0.9.6 * Fri Jul 28 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.5-alt1 - 0.9.5 * Mon Jul 03 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.3-alt1 - 0.9.3 * Fri Jun 30 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.2-alt1 - 0.9.2 * Mon May 22 2023 Alexey Shabalin <shaba@altlinux.org> 0.9.0-alt1 - 0.9.0 - add pve-storage-vitastor package * Sun May 14 2023 Alexey Shabalin <shaba@altlinux.org> 0.8.9-alt1 - 0.8.9 * Fri Apr 28 2023 Alexey Shabalin <shaba@altlinux.org> 0.8.8-alt1 - 0.8.8 * Thu Apr 13 2023 Alexey Shabalin <shaba@altlinux.org> 0.8.7-alt1 - 0.8.7 * Thu Jan 19 2023 Alexey Shabalin <shaba@altlinux.org> 0.8.4-alt1 - 0.8.4 * Wed Dec 28 2022 Alexey Shabalin <shaba@altlinux.org> 0.8.3-alt1 - 0.8.3 * Mon Dec 26 2022 Alexey Shabalin <shaba@altlinux.org> 0.8.2-alt1 - 0.8.2 * Thu Dec 01 2022 Alexey Shabalin <shaba@altlinux.org> 0.8.1-alt1 - 0.8.1 * Tue Sep 06 2022 Alexey Shabalin <shaba@altlinux.org> 0.8.0-alt1 - 0.8.0 * Fri Apr 15 2022 Alexey Shabalin <shaba@altlinux.org> 0.6.16-alt1 - 0.6.16 * Wed Jan 26 2022 Alexey Shabalin <shaba@altlinux.org> 0.6.12-alt1 - 0.6.12 * Sat Jan 15 2022 Alexey Shabalin <shaba@altlinux.org> 0.6.11-alt1 - 0.6.11 * Fri Dec 17 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.10-alt1 - 0.6.10 * Sun Jul 11 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.5-alt1 - 0.6.5 * Fri Jul 02 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.4-alt2 - build master snapshot 30bb6026818b66bbe05bde38d70673e4633313e9 - package client header to devel package - merge blk and client devel packages * Wed May 19 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.4-alt1 - 0.6.4 * Thu May 06 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.3-alt1 - 0.6.3 * Mon Apr 19 2021 Alexey Shabalin <shaba@altlinux.org> 0.6.2-alt1 - 0.6.2 * Fri Mar 19 2021 Alexey Shabalin <shaba@altlinux.org> 0.5.10-alt1 - Initial build. |