Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37736055
en ru br
ALT Linux repos
5.0: 0.2-alt1

Group :: System/Base
RPM: kernelbootlog

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

pax_global_header00006660000000000000000000000064110117144760014514gustar00rootroot0000000000000052 comment=177f4c824bffd7835dcb0d59bfbd013ee16d8d81
kernelbootlog-0.2/000075500000000000000000000000001101171447600142215ustar00rootroot00000000000000kernelbootlog-0.2/.gear/000075500000000000000000000000001101171447600152155ustar00rootroot00000000000000kernelbootlog-0.2/.gear/rules000064400000000000000000000000101101171447600162610ustar00rootroot00000000000000tar: .
kernelbootlog-0.2/kernelbootlog000075500000000000000000000031241101171447600170150ustar00rootroot00000000000000#!/bin/sh
### BEGIN INIT INFO
# Provides: kernelbootlog
# Required-Start: $local_fs $network $remote_fs
# Required-Stop: $local_fs $network $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Simple logger for lsmod/interrupts/dmesg info
# Description: Simple logger for lsmod/interrupts/dmesg info
### END INIT INFO
WITHOUT_RC_COMPAT=1

DIR=/var/log/kernelbootlog

# Source function library.
. /etc/init.d/functions
RETVAL=0

start()
{
mkdir -p $DIR

if ! cd $DIR; then
exit -1
fi

if [ ! -d ".git" ]; then
git init > /dev/null
fi

dmesg > dmesg
cat /proc/interrupts > interrupts
cat /proc/cmdline > cmdline
cat /proc/cpuinfo > cpuinfo
cat /proc/iomem > iomem
cat /proc/ioports > ioports
cat /proc/mtrr > mtrr
cat /proc/version > version
lspci > lspci
gzip -d < /proc/config.gz > config
lsmod | sed 1d | sort > lsmod

git add * > /dev/null
git config user.name kernelbootlog
git config user.email root@`hostname`
git commit -a -m 'boot at '`date -I` > /dev/null

RETVAL=$?
return $RETVAL
}

stop()
{
return $RETVAL
}

restart()
{
stop
start
}

reload()
{
return $RETVAL
}

# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
reload)
reload
;;
restart)
restart
;;
condstop)
if [ -e "$LOCKFILE" ]; then
stop
fi
;;
condrestart)
if [ -e "$LOCKFILE" ]; then
restart
fi
;;
condreload)
if [ -e "$LOCKFILE" ]; then
reload
fi
;;
status)
status --expect-user root -- acpid
RETVAL=$?
;;
*)
msg_usage "${0##*/} {start|stop|reload|restart|condstop|condrestart|condreload|status}"
RETVAL=1
esac

kernelbootlog-0.2/kernelbootlog.spec000064400000000000000000000013001101171447600177350ustar00rootroot00000000000000Name: kernelbootlog
Version: 0.2
Release: alt1
BuildArch: noarch
Summary: Automaticaly backup some system info when booting
License: GPL
Group: System/Base

Packager: Denis Smirnov <mithraen@altlinux.ru>

Source: %name-%version.tar

%description
%summary

%prep
%setup -q

%build
%install
mkdir -p %buildroot%_initdir/
install -p %name %buildroot%_initdir//%name
mkdir -p %buildroot/var/log/%name

%post
%post_service %name

%preun
%preun_service %name
%files
%_initdir/%name
/var/log/%name

%changelog
* Mon May 12 2008 Denis Smirnov <mithraen@altlinux.ru> 0.2-alt1
- Bugfix: add user.name/user.email to git repo config

* Sat May 10 2008 Denis Smirnov <mithraen@altlinux.ru> 0.1-alt1
- initial build


 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin