-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathadaptivemm.spec
114 lines (88 loc) · 3.89 KB
/
adaptivemm.spec
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
Name: adaptivemm
Version: 2.1.0
Release: 1%{?dist}
License: GPLv2
Obsoletes: memoptimizer
Summary: Adaptive free memory management
URL: https://github.com/oracle/adaptivemm
Source0: %{name}-%{version}.tar.gz
BuildRequires: glib2-devel
BuildRequires: pkgconfig
BuildRequires: gcc
BuildRequires: make
Requires(post): systemd-units
Requires(preun): systemd-units
Requires(postun): systemd-units
%description
%{name} monitors the state of free pages by reading kernel provided
files under /proc and /sys. Based upon the current rate of free page
consumption and memory fragmentation, it predicts if the system is
likely to run out of memory, or if memory will become severely
fragmented in the near future. If so, it adjusts watermarks to force
memory reclamation. If memory is predicted to become severely
fragmented, it triggers compaction in the kernel. The goal is to avert
memory shortage and/or fragmentation by taking proactive measures.
%prep
%setup -q
%build
make %{?_smp_mflags}
%install
install -D -m 755 adaptivemmd %{buildroot}%{_sbindir}/adaptivemmd
install -D -m 644 adaptivemmd.service %{buildroot}%{_unitdir}/adaptivemmd.service
install -D -m 644 50-adaptivemm.preset %{buildroot}%{_presetdir}/50-adaptivemm.preset
install -D -m 644 adaptivemmd.cfg %{buildroot}%{_sysconfdir}/sysconfig/adaptivemmd
install -D -m 644 adaptivemmd.8 %{buildroot}%{_mandir}/man8/adaptivemmd.8
%post
%systemd_post adaptivemmd.service
%postun
%systemd_postun_with_restart adaptivemmd.service
%preun
%systemd_preun adaptivemmd.service
%files
%license LICENSE.txt
%doc README.md CONTRIBUTING.md SECURITY.md
%attr(0640,root,root) %config(noreplace) /etc/sysconfig/adaptivemmd
%{_sbindir}/adaptivemmd
%{_mandir}/man8/adaptivemmd.8*
%{_unitdir}/adaptivemmd.service
%{_presetdir}/50-adaptivemm.preset
%changelog
* Mon Dec 11 2023 Khalid Aziz <[email protected]> - 2.1.0-1
- Add module to look for possible memory leaks
* Tue Feb 9 2022 Khalid Aziz <[email protected]> - 2.0.1-1
- Fix total memory calculation for ARM since it is slightly
different from x86
* Tue Jan 25 2022 Khalid Aziz <[email protected]> - 2.0.0-1
- Changing name to adaptivemmd from memoptimizer
- Change a config option name to stop systemd from complaining
about the name format
* Thu Jul 29 2021 Khalid Aziz <[email protected]> - 1.5.0-1
- Add support for one time initializations at start up
- Add support for tunables value updates upon change
in number of hugepages on the system
* Mon May 17 2021 Khalid Aziz <[email protected]> - 1.4.2-1
- Fix crash on systems with less than 4G memory
* Thu Mar 25 2021 Khalid Aziz <[email protected]> - 1.4.0-1
- Various algorithm updates to reduce the possibility of OOM
killer being invoked because of memoptimizer's actions
* Thu Feb 11 2021 Khalid Aziz <[email protected]> - 1.3.0-1
- New upstream release. Various enhancements to reduce system
resource usage by the daemon. Fix to correct the sense of
aggressiveness level and documentation update
* Fri Jan 22 2021 Khalid Aziz <[email protected]> - 1.2.0-1
- New upstream release. Fixes bug with not reading configuration file
* Thu Jan 21 2021 Khalid Aziz <[email protected]> - 1.1.0-1
- New upstream release
* Tue Jan 12 2021 Khalid Aziz <[email protected]> - 1.0.5-1
- Updated spec file to conform to fedora packaging guidelines
* Wed Dec 23 2020 Khalid Aziz <[email protected]> - 1.0-4
- Fixed a formatting error in man page
* Mon Nov 2 2020 Khalid Aziz <[email protected]> - 1.0-3
- Added more documentation and updated spec file to enable memoptimizer
daemon using a preset file but not start the daemon
* Mon Oct 26 2020 Khalid Aziz <[email protected]> - 1.0-2
- Enable and start memoptimizer immediately after installation
* Wed Sep 02 2020 Khalid Aziz <[email protected]> - 1.0-1
- Add support for configuration file and systemd
* Tue Aug 04 2020 Khalid Aziz <[email protected]> - 0.8
- Initial release