summaryrefslogtreecommitdiffstats
path: root/sbin/savecore
Commit message (Collapse)AuthorAgeFilesLines
* Fix double fclose() in an error case.brueffer2014-04-141-1/+1
| | | | | | CID: 1006120 Found with: Coverity Prevent(tm) MFC after: 1 week
* Log the name of the device that we failed to open rather than anmarkj2014-03-051-1/+1
| | | | | | uninitialized buffer. MFC after: 3 days
* With rotating kernel dumps the higest dump number is not necessarily thepjd2012-12-161-1/+29
| | | | | | | | | | | last one. To make it easier to find the last one create symlinks with 'last' suffix that will point to the files of the last coredump, eg.: info.last -> info.5 textdump.tar.last.gz -> textdump.tar.5.gz Reviewed by: avg Obtained from: WHEEL Systems
* Implement -m option to savecore(8) that allows to limit number of kernelpjd2012-12-162-21/+96
| | | | | | | dumps stored. Once the limit is reached it restarts from 0. Reviewed by: avg Obtained from: WHEEL Systems
* Make use of the fact that we changed working directory to the dump directorypjd2012-12-161-4/+3
| | | | | | earlier. Obtained from: WHEEL Systems
* Sort flags properly.pjd2012-12-161-3/+3
| | | | Obtained from: WHEEL Systems
* Prefer snprintf() over sprintf().pjd2012-12-161-5/+5
| | | | Obtained from: WHEEL Systems
* - When checking if a dump exists on the given device there is no need topjd2012-12-142-5/+7
| | | | | | | | | | | | | | | | provide dump directory. Eliminate this redundant argument. This changes the usage, but the only risk here is that a warning will be printed about directory given as device. - Update usage of -C option. - When clearing dump header from the given device there is also no need to provide dump directory, although additional arguments for -c were not documented. - Document that -v can be used with -c and that list of devices can be given. Obtained from: WHEEL Systems
* The clear option (-c) is not compatible with keep (-k) and compress (-z)pjd2012-12-141-0/+2
| | | | | | options. Obtained from: WHEEL Systems
* If we are not going to clear the dump (we are either just checking if the dumppjd2012-12-141-2/+2
| | | | | | exists or we want to keep it), open device read-only. Obtained from: WHEEL Systems
* Whitespace cleanups.pjd2012-12-141-6/+6
|
* Include <signal.h> (for SIGINFO).rmh2012-04-091-0/+1
|
* Remove duplicated header fileskevlo2011-06-241-1/+0
|
* Remove the advertising clause from UCB copyrighted files in sbin. Thisjoel2010-12-121-4/+0
| | | | | is in accordance with the information at ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change
* Switch the default WARNS level for sbin/ to 6.ru2009-10-191-1/+0
| | | | Submitted by: Ulrich Spörlein
* Fixed markup.ru2009-09-171-3/+5
|
* - Add a SIGINFO handler for savecore.lulf2009-08-251-1/+17
|
* Correct the information about when the respective functionality firstbrueffer2009-04-231-1/+1
| | | | | | | | appeared in FreeBSD. PR: 133785 Submitted by: Ulrich Spoerlein <uqs@spoerlein.net> MFC after: 3 days
* Apply various fixes:trhodes2008-12-241-2/+2
| | | | | | | | | Silence mdoc(7) warnings; Xref correct manual pages; Point user to the ddb.8 manual page. PR: 129398 Submitted by: gavin
* Compare kernel dump header magic with textdump magic using strncmp()rwatson2007-12-271-11/+31
| | | | | | | | | | | | rather than the memcmp() which is used for regular dumps: the textdump string is one character shorter, so we need to stop comparing at the end of the string. Use independent version checking logic for architecture-specific version number vs. textdump version number, as the version sequences may (someday) differ. Run into by: rrs
* Teach savecore(8) how to extract textdump(4) dumps.rwatson2007-12-262-79/+171
| | | | | | Update savecore(8) man page to reflect textdump additions. MFC after: 3 months
* Check fdopen return value.kevlo2007-05-281-0/+6
| | | | Reviewed by: phk
* o Restore kerneldumpheader.architectureversion bytes swoppingmaxim2005-10-021-1/+2
| | | | | | | | mangled in rev. 1.72. PR: bin/86805 Submitted by: Gavin Atkinson MFC after: 3 days
* Don't consider being unable to open the bounds file worthy of printingrwatson2005-09-131-1/+2
| | | | | | | | | at LOG_WARNING by default; instead, consider it something to be printed to the tty when 'verbose' mode is set. This avoids printing out extra lines at every boot on a system with crash dumps enabled, but that has not yet had to generate a crashdump. MFC after: 1 week
* Don't bump bounds every time savecore(8) is run.dwhite2005-06-201-9/+12
| | | | | Submitted by: Ed Maste <emaste@sandvine.com> Approved by: re
* Markup fixes.ru2005-06-141-1/+1
| | | | Approved by: re (blanket)
* Fix a silly little typo I just spotted.philip2005-06-061-1/+1
|
* Constify savedir pointer, and remove an accompaning strdup() call.delphij2005-05-291-8/+3
|
* style(9).obrien2005-02-261-43/+45
|
* Allow a forced dump even if the dump header information is inconsistent.obrien2005-02-242-18/+61
| | | | | | Output more verbosity with additional -v's. Submitted by: seanc
* Sync program's usage() with manpage's SYNOPSIS.ru2005-02-101-2/+4
|
* Sort sections.ru2005-01-181-2/+2
|
* Initialize "he" in DoFile, so savecore(8) is WARNS=6 clean.delphij2005-01-102-2/+2
| | | | Bump WARNS accordingly.
* Use a local "compress" symbol corresponding to a variable in BSS,ru2004-08-161-2/+2
| | | | | | | rather than the one from libz, corresponding to a function, when linking statically. PR: bin/70392
* Remove advertising clause from University of California Regent's license,markm2004-04-091-4/+0
| | | | | | per letter dated July 22, 1999. Approved by: core, imp
* o Remove obsoleted '-N' and '-d' flags.maxim2004-02-281-3/+1
|
* o Sync usage() with reality: add 'z' flag.maxim2004-02-281-1/+2
| | | | MFC after: 1 week
* style.Makefile(5):johan2004-02-231-1/+1
| | | | Use WARNS?= instead of WARNS=.
* Merge from RELENG_4 1.28.2.13: Fix saving system crash dumps larger thantjr2004-02-201-1/+1
| | | | 2 GB by using fseeko() instead of fseek().
* Revision 1.61 changed the allocation of buffer 'buf' in DoFile() frommarcel2003-10-081-6/+0
| | | | | | | | | | | | | the stack to the heap to work around a problem on ia64. Now, roughly 16 months and two compiler updates later, it isn't an issue anymore in the sense that putting a 1M buffer on the stack just works and we don't actually need to work around anything anymore. However, since there's no advantage or need to put the buffer on the stack (again), this change merely removes the XXX comment describing that there's an explicit reason for the heap allocation. Hence, this change is a functional no-op. PR: ia64/38677
* Add a flag that reports the existence of a dump, and does nothing else.dougb2003-09-042-4/+32
| | | | | | | | The immediate purpose for this option is to use it in rc.d so that we can make savecore behavior conditional. Tremendous assistance with ideas and sanity checking provided by tjr and b@etek.chalmers.se.
* Correct typos, mostly s/ a / an / where appropriate. Some whitespace cleanup,schweikh2003-01-011-1/+1
| | | | especially in troff files.
* s/filesystem/file system/g as discussed on -developerstrhodes2002-08-211-2/+2
|
* The .Nm utility.charnier2002-07-061-1/+1
|
* Fix breakage caused by allocating the I/O buffer. There was amarcel2002-06-021-2/+5
| | | | | | | sizeof(buf) lurking around that I missed. PR: 38811 Submitted by: Adrian Colley <aecolley@spamcop.net>
* mdoc(7) police: nits.ru2002-05-291-8/+21
|
* Work around a memory fault on ia64 caused by having the 1MB buffer onmarcel2002-05-271-1/+16
| | | | | the stack in DoFile(). This needs some investigation. In the mean time we do a one time malloc() for the buffer to have it on the heap instead.
* Style.ru2002-05-131-3/+4
|
* Make argument to printf match format.marcel2002-05-061-1/+1
|
* - revert back to vmcore.#fenner2002-05-053-109/+271
| | | | | | | | | | | | | | - reimplement -z - use syslog() - improve consistancy of messages - allow -f to recover cleared dumps - return bufsize to 1024 * 1024 - return the ability to write sparse files - update man page - fix minfree to require 2k for info file instead of the kernel size - include Berkeley copyright too due to amount of old code copied Submitted by: Chad David <davidc@acns.ab.ca>
OpenPOWER on IntegriCloud