This commit is contained in:
commit
7b26ebb1c1
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
.osc
|
38
README
Normal file
38
README
Normal file
@ -0,0 +1,38 @@
|
||||
Introduction:
|
||||
To shorten the size of the dumpfile and the time of creating the
|
||||
dumpfile, makedumpfile copies only the necessary pages for analysis
|
||||
to the dumpfile from /proc/vmcore. You can specify the kind of
|
||||
unnecessary pages with dump_level. If you want to shorten the size
|
||||
further, enable the compression of the page data.
|
||||
|
||||
Download:
|
||||
https://sourceforge.net/projects/makedumpfile/
|
||||
|
||||
Usage:
|
||||
makedumpfile [-c] [-E] [-d dump_level] [-x vmlinux] dump_mem dump_file
|
||||
|
||||
Example:
|
||||
If you want to exclude pages filled by zero, cache pages, user pages
|
||||
and free pages and to enable compression, please execute the following
|
||||
command.
|
||||
|
||||
# makedumpfile -c -d 31 -x vmlinux /proc/vmcore dumpfile
|
||||
|
||||
SSH transporting support:
|
||||
For ssh transporting support, -F and -R options are added.
|
||||
A panic system sends dump data to a remote host with -F option, and
|
||||
a remote host re-arranges dump data received to a normal dumpfile
|
||||
(readable by analysis tools) with -R option.
|
||||
Example-1:
|
||||
# makedumpfile -F -cd31 -x vmlinux /proc/vmcore | ssh user@host "makedumpfile -R dumpfile"
|
||||
|
||||
A perl script makedumpfile-R.pl implements the same function as '-R'
|
||||
option. Perl script does not depend on architecture, and a lot of
|
||||
systems have perl command. Even if a remote host does not have the
|
||||
makedumpfile command, it is possible to transport a dumpfile to a
|
||||
remote host with running this script.
|
||||
Example-2:
|
||||
1. Transport the script.
|
||||
# scp makedumpfile-R.pl user@remote:makedumpfile-R.pl
|
||||
2. Transport a dumpfile.
|
||||
# makedumpfile -F -cd31 -i config /proc/vmcore | ssh user@remote "./makedumpfile-R.pl dumpfile"
|
12
elfutils-0.124-compile-fix.diff
Normal file
12
elfutils-0.124-compile-fix.diff
Normal file
@ -0,0 +1,12 @@
|
||||
--- tests/line2addr.c-dist 2007-01-09 13:01:13.000000000 +0100
|
||||
+++ tests/line2addr.c 2007-01-09 13:18:36.000000000 +0100
|
||||
@@ -132,7 +132,8 @@ main (int argc, char *argv[])
|
||||
{
|
||||
struct args a = { .arg = argv[cnt] };
|
||||
|
||||
- switch (sscanf (a.arg, "%a[^:]:%d", &a.file, &a.line))
|
||||
+ a.file = malloc(4096); /* XXX temporary fix */
|
||||
+ switch (sscanf (a.arg, "%s[^:]:%d", a.file, &a.line))
|
||||
{
|
||||
default:
|
||||
case 0:
|
3
elfutils-0.124-no-osl.tar.bz2
Normal file
3
elfutils-0.124-no-osl.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:d25586459c0f6366ee4c1e9cd7cd09abd3558ad355296b28b37c182c36087f47
|
||||
size 943456
|
1024
elfutils-portability.patch
Normal file
1024
elfutils-portability.patch
Normal file
File diff suppressed because it is too large
Load Diff
3
makedumpfile-1.1.0.tar.bz2
Normal file
3
makedumpfile-1.1.0.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:c50f0e840d54c5e4c94937caed917c58cfaa664201da251589729158a00a1072
|
||||
size 24871
|
15
makedumpfile-coptflags.diff
Normal file
15
makedumpfile-coptflags.diff
Normal file
@ -0,0 +1,15 @@
|
||||
--- Makefile-dist 2007-01-09 12:57:28.000000000 +0100
|
||||
+++ Makefile 2007-01-09 12:57:30.000000000 +0100
|
||||
@@ -4,9 +4,10 @@
|
||||
DATE=22 December 2006
|
||||
|
||||
CC = gcc
|
||||
-CFLAGS = -g -O2 -Wall -D_FILE_OFFSET_BITS=64 \
|
||||
+COPTFLAGS = -g -O2 -Wall
|
||||
+CFLAGS = $(COPTFLAGS) -D_FILE_OFFSET_BITS=64 \
|
||||
-DVERSION='"$(VERSION)"' -DRELEASE_DATE='"$(DATE)"'
|
||||
-CFLAGS_ARCH = -g -O2 -Wall
|
||||
+CFLAGS_ARCH = $(COPTFLAGS)
|
||||
|
||||
ARCH := $(shell uname -m | sed -e s/i.86/x86/ -e s/sun4u/sparc64/ \
|
||||
-e s/arm.*/arm/ -e s/sa110/arm/ \
|
21
makedumpfile-static-elfutils.diff
Normal file
21
makedumpfile-static-elfutils.diff
Normal file
@ -0,0 +1,21 @@
|
||||
--- Makefile-dist 2006-12-21 13:20:43.000000000 +0100
|
||||
+++ Makefile 2006-12-21 13:22:33.000000000 +0100
|
||||
@@ -20,6 +20,9 @@
|
||||
CFLAGS_ARCH += -m64
|
||||
endif
|
||||
|
||||
+CFLAGS += -Iinstalled/usr/include
|
||||
+CFLAGS_ARCH += -Iinstalled/usr/include
|
||||
+
|
||||
SRC = makedumpfile.c makedumpfile.h diskdump_mod.h
|
||||
SRC_ARCH = x86.c x86_64.c ia64.c ppc64.c
|
||||
OBJ_ARCH = x86.o x86_64.o ia64.o ppc64.o
|
||||
@@ -30,7 +33,7 @@
|
||||
$(CC) $(CFLAGS_ARCH) -c -o ./$@ ./$(@:.o=.c)
|
||||
|
||||
makedumpfile: $(SRC) $(OBJ_ARCH)
|
||||
- $(CC) $(CFLAGS) $(OBJ_ARCH) -o $@ $< -static -ldw -lelf -lz
|
||||
+ $(CC) $(CFLAGS) $(OBJ_ARCH) -o $@ $< -static -Linstalled/usr/lib -ldw -lelf -lz
|
||||
|
||||
clean:
|
||||
rm $(OBJ) $(OBJ_ARCH) makedumpfile
|
32
makedumpfile.changes
Normal file
32
makedumpfile.changes
Normal file
@ -0,0 +1,32 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 5 13:37:36 CET 2007 - tiwai@suse.de
|
||||
|
||||
- updated to version 1.1.0:
|
||||
* support SSH transfer
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 18 15:35:17 CET 2007 - tiwai@suse.de
|
||||
|
||||
- updated to version 1.0.9:
|
||||
* fix the calculation of page size.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 9 19:17:53 CET 2007 - tiwai@suse.de
|
||||
|
||||
- remove codes with problematic license from elfutils-0.124
|
||||
(#232894)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 9 13:00:11 CET 2007 - tiwai@suse.de
|
||||
|
||||
- added COPYING file (from elfutils)
|
||||
- fixed optimization flags to use $RPM_OPT_FLAGS
|
||||
- fix a minor compile error with C99 standard.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jan 8 16:45:29 CET 2007 - tiwai@suse.de
|
||||
|
||||
- initial version: 1.0.8
|
||||
- build statically with elfutils-1.2.4 since elfutils conflicts
|
||||
with the existing libelf.
|
||||
|
103
makedumpfile.spec
Normal file
103
makedumpfile.spec
Normal file
@ -0,0 +1,103 @@
|
||||
#
|
||||
# spec file for package makedumpfile (Version 1.1.0)
|
||||
#
|
||||
# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
# This file and all modifications and additions to the pristine
|
||||
# package are under the same license as the package itself.
|
||||
#
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# norootforbuild
|
||||
|
||||
Name: makedumpfile
|
||||
BuildRequires: gcc-c++
|
||||
%define elfutils_version 0.124
|
||||
License: GNU General Public License (GPL)
|
||||
Version: 1.1.0
|
||||
Release: 1
|
||||
Summary: Partial kernel dump
|
||||
Group: System/Kernel
|
||||
URL: https://sourceforge.net/projects/makedumpfile/
|
||||
Source: makedumpfile-%{version}.tar.bz2
|
||||
Source1: elfutils-%{elfutils_version}-no-osl.tar.bz2
|
||||
Source2: README
|
||||
Patch: makedumpfile-static-elfutils.diff
|
||||
Patch1: makedumpfile-coptflags.diff
|
||||
Patch2: elfutils-portability.patch
|
||||
Patch3: elfutils-0.124-compile-fix.diff
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
|
||||
%description
|
||||
makedumpfile is a dump program to shorten the size of dump file. It
|
||||
copies only the necessary pages for analysis with various dump levels,
|
||||
and can compress the page data. The obtained dump file can by analyzed
|
||||
via gdb or crash utility.
|
||||
|
||||
|
||||
|
||||
Authors:
|
||||
--------
|
||||
NEC Corporation
|
||||
|
||||
%prep
|
||||
%setup -n makedumpfile -q -a1
|
||||
%patch
|
||||
%patch1
|
||||
cp %{SOURCE2} .
|
||||
cd elfutils-%{elfutils_version}
|
||||
ls -l backends
|
||||
if [ `wc -l < "backends/sparc_retval.c"` -gt 2 ]; then
|
||||
echo "backends/sparc_retval.c is not distributable for legal reasons."
|
||||
echo "Please replace it with a dummy implementation in your elfutils package:"
|
||||
echo "echo -e '#include <stdlib.h>\nint sparc_return_value_location () { abort(); return 0; }' > backends/sparc_retval.c"
|
||||
exit 1
|
||||
fi
|
||||
%patch2 -p1
|
||||
%patch3
|
||||
autoreconf -fi
|
||||
cd ..
|
||||
|
||||
%build
|
||||
MKDUMP_ROOT=`pwd`/installed
|
||||
cd elfutils-%{elfutils_version}
|
||||
CFLAGS="$RPM_OPT_FLAGS" \
|
||||
./configure --prefix=/usr
|
||||
make
|
||||
make install DESTDIR=$MKDUMP_ROOT
|
||||
rm -f $MKDUMP_ROOT/usr/lib/*.so*
|
||||
cd ..
|
||||
make COPTFLAGS="$RPM_OPT_FLAGS"
|
||||
|
||||
%install
|
||||
mkdir -p $RPM_BUILD_ROOT/bin
|
||||
install -c -m 0755 makedumpfile $RPM_BUILD_ROOT/bin
|
||||
install -c -m 0755 makedumpfile-R.pl $RPM_BUILD_ROOT/bin
|
||||
|
||||
%clean
|
||||
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc README
|
||||
%doc elfutils-*/COPYING
|
||||
/bin/*
|
||||
|
||||
%changelog -n makedumpfile
|
||||
* Mon Feb 05 2007 - tiwai@suse.de
|
||||
- updated to version 1.1.0:
|
||||
* support SSH transfer
|
||||
* Thu Jan 18 2007 - tiwai@suse.de
|
||||
- updated to version 1.0.9:
|
||||
* fix the calculation of page size.
|
||||
* Tue Jan 09 2007 - tiwai@suse.de
|
||||
- remove codes with problematic license from elfutils-0.124
|
||||
(#232894)
|
||||
* Tue Jan 09 2007 - tiwai@suse.de
|
||||
- added COPYING file (from elfutils)
|
||||
- fixed optimization flags to use $RPM_OPT_FLAGS
|
||||
- fix a minor compile error with C99 standard.
|
||||
* Mon Jan 08 2007 - tiwai@suse.de
|
||||
- initial version: 1.0.8
|
||||
- build statically with elfutils-1.2.4 since elfutils conflicts
|
||||
with the existing libelf.
|
Loading…
Reference in New Issue
Block a user