%{!?python_site: %define python_site %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(0)")} Summary: Application for remote coredump analysis Name: retrace-server Version: 1.13 Release: 1%{?dist} License: GPLv2+ Group: Applications/System URL: https://fedorahosted.org/abrt/wiki/AbrtRetraceServer Source: https://fedorahosted.org/released/%{name}/%{name}-%{version}.tar.gz # git format-patch -N -M --topo-order %%{version} Patch0001: 0001-Set-crash-inside-get_crash_cmd-file-if-the-file-does.patch #Patch0002: 0002-spec-add-sqlite-and-cron-to-requirements.patch Patch0003: 0003-update-fedora-plugin.patch BuildArch: noarch BuildRequires: intltool BuildRequires: libtool BuildRequires: texinfo BuildRequires: asciidoc BuildRequires: xmlto %{?el6:Requires: python-argparse} Requires: rsync Requires: mock >= 1.1.11 Requires: xz Requires: gzip Requires: bzip2 Requires: tar Requires: p7zip Requires: unzip Requires: elfutils Requires: createrepo Requires: mod_wsgi Requires: mod_ssl Requires: python-webob Requires: sqlite Requires: yum-utils Requires: crash >= 5.1.7 Requires: wget Requires: kexec-tools Requires: python-magic Requires(preun): /sbin/install-info Requires(post): /sbin/install-info Requires(post): /usr/bin/crontab Obsoletes: abrt-retrace-server < 2.0.3 Provides: abrt-retrace-server = 2.0.3 %description The retrace server provides a coredump analysis and backtrace generation service over a network using HTTP protocol. %prep %setup -q %patch0001 -p1 #%%patch0002 -p1 %patch0003 -p1 %build autoconf %configure make %{?_smp_mflags} %install make install DESTDIR=${RPM_BUILD_ROOT} mandir=%{_mandir} mkdir -p ${RPM_BUILD_ROOT}/%{_localstatedir}/cache/%{name} mkdir -p ${RPM_BUILD_ROOT}/%{_localstatedir}/cache/%{name}/kernel mkdir -p ${RPM_BUILD_ROOT}/%{_localstatedir}/cache/%{name}/download mkdir -p ${RPM_BUILD_ROOT}/%{_localstatedir}/log/%{name} mkdir -p ${RPM_BUILD_ROOT}/%{_localstatedir}/spool/%{name} mkdir -p ${RPM_BUILD_ROOT}/%{_datadir}/%{name} rm -f ${RPM_BUILD_ROOT}%{_infodir}/dir %{find_lang} %{name} %pre #retrace uid/gid reserved in setup, rhbz #706012 %define retrace_gid_uid 174 getent group retrace > /dev/null || groupadd -f -g %{retrace_gid_uid} --system retrace getent passwd retrace > /dev/null || useradd --system -g retrace -u %{retrace_gid_uid} -d %{_datadir}/%{name} -s /sbin/nologin retrace exit 0 %post /sbin/install-info %{_infodir}/%{name} %{_infodir}/dir 2> /dev/null || : /usr/sbin/usermod -a -G mock retrace 2> /dev/null || : if [ "$1" = 1 ] then #add disabled crontab entries to retrace's crontab %define retrace_crontab_entry0 "# 0 * * * * /usr/bin/retrace-server-cleanup >> /var/log/retrace-server/cleanup_error.log 2>&1" %define retrace_crontab_entry1 "#0 0,12 * * * /usr/bin/retrace-server-reposync fedora 15 i386 >> /var/log/retrace-server/reposync_error.log 2>&1" %define retrace_crontab_entry2 "#0 2,14 * * * /usr/bin/retrace-server-reposync fedora 15 x86_64 >> /var/log/retrace-server/reposync_error.log 2>&1" %define retrace_crontab_entry3 "#0 4,16 * * * /usr/bin/retrace-server-reposync fedora 16 i386 >> /var/log/retrace-server/reposync_error.log 2>&1" %define retrace_crontab_entry4 "#0 6,18 * * * /usr/bin/retrace-server-reposync fedora 16 x86_64 >> /var/log/retrace-server/reposync_error.log 2>&1" %define retrace_crontab_entry5 "#0 8,20 * * * /usr/bin/retrace-server-reposync fedora rawhide i386 >> /var/log/retrace-server/reposync_error.log 2>&1" %define retrace_crontab_entry6 "#0 10,22 * * * /usr/bin/retrace-server-reposync fedora rawhide x86_64 >> /var/log/retrace-server/reposync_error.log 2>&1" (crontab -u retrace -l 2> /dev/null; echo %{retrace_crontab_entry0}; \ echo %{retrace_crontab_entry1}; echo %{retrace_crontab_entry2}; \ echo %{retrace_crontab_entry3}; echo %{retrace_crontab_entry4}; \ echo %{retrace_crontab_entry5}; echo %{retrace_crontab_entry6};) | crontab -u retrace - 2> /dev/null fi %preun if [ "$1" = 0 ] then /sbin/install-info --delete %{_infodir}/retrace-server %{_infodir}/dir 2> /dev/null || : #comment entries in retrace's crontab (crontab -u retrace -l 2> /dev/null | sed "s,^\([^#].*\)$,#\1,g") | crontab -u retrace - 2> /dev/null fi %files -f %{name}.lang %defattr(-,root,root,-) %config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}-httpd.conf %config(noreplace) %{_sysconfdir}/%{name}.conf %config(noreplace) %{_sysconfdir}/logrotate.d/%{name} %dir %attr(0755,retrace,retrace) %{_localstatedir}/cache/%{name} %dir %attr(0755,retrace,retrace) %{_localstatedir}/cache/%{name}/kernel %dir %attr(0755,retrace,retrace) %{_localstatedir}/cache/%{name}/download %dir %attr(0750,retrace,retrace) %{_localstatedir}/log/%{name} %dir %attr(0770,retrace,retrace) %{_localstatedir}/spool/%{name} %dir %{_datadir}/%{name} %{_bindir}/%{name}-worker %{_bindir}/%{name}-interact %{_bindir}/%{name}-cleanup %{_bindir}/%{name}-reposync %{_bindir}/bt_filter %{_bindir}/coredump2packages %{python_site}/retrace/* %{_datadir}/%{name}/* %doc %{_mandir}/man1/%{name}-cleanup.1.gz %doc %{_mandir}/man1/%{name}-interact.1.gz %doc %{_mandir}/man1/%{name}-reposync.1.gz %doc %{_mandir}/man1/%{name}-worker.1.gz %doc %{_infodir}/%{name}* %doc COPYING INSTALL README TODO %changelog * Thu Jan 14 2016 Jakub Filak - 1.13-1 - New upstream release 1.13 - Add sqlite and /usr/bin/crontab to Requires * Thu Jun 18 2015 Fedora Release Engineering - 1.12-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild * Wed Mar 11 2015 Michal Toman 1.12-4 - fix the invocation of mock shell * Tue Mar 03 2015 Michal Toman 1.12-3 - manager.wsgi - fix kernelver handling (harshula@redhat.com) - add support for ppc64le and aarch64 * Thu Jul 31 2014 Michal Toman 1.12-1 - do not run kmem on vmcores by default - fix group readability of vmcores - add support for lzop compression - add DeleteFailedTaskAfter config option - add arch-based remote execution - add set-success and set-fail actions to retrace-server-interact - add config sanity checks to retrace-server-cleanup * Sun Jun 08 2014 Fedora Release Engineering - 1.11-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild * Thu Feb 27 2014 Michal Toman 1.11-1 - do not die trying to chmod a hardling - do not hardlink unpacked vmcores - print command line formatted correctly - allow submitting vmcores with spaces in file name - do not run makedumpfile when not necessary - allow to specify kernel VRA with custom cores - do not require the trailing slash in task manager URL - do not kill retrace-server-cleanup when retrace_log does not exist - cache kernel version into task directory - add support for ppc64, s390x - include floating point registers in userspace backtraces - execute ABRT's exploitability plugin if available * Wed Aug 21 2013 Michal Toman 1.10-1 - add possibility to make case number clickable - support local files in 'Custom core location' - create the stats database group-writable - do not die when saving stats fails - add possibility to restart task - do not show the output of 'mod -S' in crash - change directory to $MISCDIR after jumping to crash - load correct flavour for el4 kernels - do not kill tasks started from task manager - do not die if task manager is disabled - add basic support for ARM - find correct debuginfo for realtime kernels - fix httpd config for apache 2.4 - use mtime instead of atime in RetraceTask.get_age() - use correct suffixes when unpacking archives - do not die if module list can't be read from vmcore - add support for X-CoreFileDirectory header - add support for tweaking yum config in reposync - rework reposync logging - accept package list in the archive with crash data - try harder to find ix86 debuginfo in koji * Sun Aug 04 2013 Fedora Release Engineering - 1.9-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Wed Mar 20 2013 Michal Toman 1.9-1 - guess debuginfo name correctly for <= el4 - rename _log to retrace-log - fix cross-arch vmcores processing - debug mode checked by default in task manager - fix typos - touch task directory when using retrace-server-interact - forward kernel version from command line correctly - parse flavoured kernel version correctly - allow to send notification e-mails - symlink retrace_log to MISC_DIR - do not die on download error - rework front page - be able to specify custom core location - do not die if makedumpfile fails - make FTP buffer size configurable - fix detaching from httpd - add more logging - fix paths of DF_BIN and TAR_BIN - fix dependencies - unify access to task directory elements - display the progress of FTP download - add notes & case no. boxes - run bt_filter on vmcores automatically - add timestamps to logs - enable free space check in task manager - urlencode hyperlinks * Fri Nov 2 2012 Michal Toman 1.8-1 - use standard python mechanisms for logging - determine archive types with file magic - catch all task-specific exceptions - support various archive types - make AuthGroup configurable - allow overriding kernel version & architecture from command line - create a writable directory for interactive debuggers - add the retrace-server-interact printdir command - autoload modules when jumping into crash - make dead tasks deletable (really look to /proc) - show downloaded files in task manager - do not delete files that do not need unpacking - show task's start and finish time - added backref to downloaded file - make vmcore readable for retrace group - improve architecture guessing for vmcores - add possibility to wget kernel debuginfo - try harder to determine the actual vmcore - fix kernel version handling - fix httpd config * Fri Jul 27 2012 Michal Toman 1.7-1 - check whether package can be retraced before uploading - add possibility to disable interactive debugging - add support for chrooted crashes - also cache debuginfo for modules loaded in a vmcore - add task manager - add possibility to search kernel debuginfo in koji-like directory structure - fix permission denied on gdb.sh - add possibility to query an external FTP for task data - tasks may have multiple results - tasks may have remote resources - add possibility to run makedumpfile on vmcores - add possibility to archive old tasks instead of deleting them * Sat Jul 21 2012 Fedora Release Engineering - 1.6-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Fri May 04 2012 Michal Toman 1.6-1 - add support for interactive debugging - coredump2packages - handle malformed eu-unstrip output - expose repos via HTTP * Mon Feb 27 2012 Michal Toman 1.5-1 - add support for F17 - add hacks helping to depsolver - read huge files buffered - get rid of retrace-server.repo file - add //delete action * Sat Jan 14 2012 Fedora Release Engineering - 1.4-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild * Tue Nov 22 2011 Michal Toman 1.4-1 - add support for vmcores - add welcome page - add statistics page - add support for rawhide * Tue Aug 23 2011 Michal Toman 1.3-1 - cron jobs are not enabled by default - support X-Task-Type header - use atomic operations to lock/rename - add support for http(s) and ftp in reposync - abort if release is not supported - add option to use createrepo --update - add support for F16 * Wed Jun 29 2011 Michal Toman 1.2-1 - add option to verify GPG signatures - make HTTPS optional - use RetraceTask class - validate input - limit allowed files - do not allow worker to start twice - ship cron configuration - do not require suid launcher - minor bug and typo fixes * Wed Jun 01 2011 Scott Dodson 1.1-2 - Add asciidocs xmlto to BuildRequires * Wed Jun 01 2011 Michal Toman 1.1-1 - add logrotate script - add asciidoc support and manpages - replace rm by os.remove() and shutil.rmtree() - call du and df without block factor - use communicate() instead of .stdout.read() - replace popen by execlp - import manual from ABRT git, minor changes - create log directory - use 'retrace' user and group * Wed May 18 2011 Michal Toman 1.0-1 - initial packaging