Commit Graph

221 Commits

Author SHA1 Message Date
wiz f704e3fc5c -i does not take an argument. Remove unnecessary Bk/Ek. New sentence, new line. 2010-02-26 07:01:17 +00:00
christos c40eb1e731 PR/42883: Greywolf: Add -i flag which brings "true incremental" capability. 2010-02-26 02:11:40 +00:00
spz 1cb24f3feb range-check what we assign to int cachebufs from calculations with
uint64_t usermem. This only becomes relevant if you have several TB of RAM.
Promoting cachebufs to uint64_t is not necessary as it gets limited to
(currently) 512 anyway.

fixes the last issue of PR: 19852
2010-01-27 12:20:25 +00:00
lukem ef685eeea9 Enable WARNS=4 by default except for:
dump  dump_lfs  fsck_ffs  fsck_lfs  fsdb  mount_smbfs
	newfs_ext2fs  newfs_lfs  resize_lfs  setkey
2009-04-11 07:58:11 +00:00
lukem 6f957c8d46 fix sign-compare issue 2009-04-11 07:55:35 +00:00
enami ca82f7eac5 Use indent-synopsis instead of iS register. The latter is a register
used in BSD derived .Nm implementation.
2009-01-30 11:55:04 +00:00
gmcgarry 3c9a95916d Wrap compiler-specific flags with HAVE_GCC and HAVE_PCC as necessary. Add a few flags for PCC. 2008-08-29 00:02:21 +00:00
simonb 89943600ac We don't need to dump WAPBL log files - don't dump files with SF_LOG
flag set, and document this.
2008-08-12 13:28:35 +00:00
simonb cb6ddf15e6 Remove adding -g to CFLAGS and LDFLAGS. Ancient debug bogon? 2008-08-10 08:06:23 +00:00
lukem 6543a91fea Remove the \n and tabs from the __COPYRIGHT() strings.
(Tweak some to use a consistent format.)
2008-07-20 01:20:21 +00:00
martin ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
matt 6a2c9c06cc Fix some inconsisent/conflicting definitions and missing parameters 2008-02-16 17:58:01 +00:00
christos 746c5b06eb Convert a couple of "(void)&" constructs to volatile.
Flag various unused parameters in restore and dump so that these will
compile with -Wextra.  (Note: restore uses some stuff from dump.)
2006-12-18 20:07:32 +00:00
hannken fcd5ec4841 When using a snapshot take the snapshot raw device on further open.
Fixes PR #34923  dump(8) only dumps a corefile with -X (snapshots)

Approved by: Manuel Bouyer <bouyer@netbsd.org>
2006-10-26 20:02:30 +00:00
perseant 1c57171fe3 Change LFCNWRAP{STOP,GO} to make them more suitable for snapshotting; in
particular, the caller can now choose whether to wait for the condition
to be met, and if the caller of LFCNWRAPSTOP dies or otherwise closes
the descriptor, the filesystem is started again.  Updated the ckckp
regression test to use the new semantics.

dump_lfs(8) now uses the fcntls to implement LFS-style snapshotting through
the -X flag, addressing PR#33457 albeit not using fss(4).  Fixed a couple
other problems with dump_lfs that manifested themselves during testing.
2006-06-24 05:28:54 +00:00
christos 326dc9f020 Coverity CID 3275: Plug memory leak. 2006-05-19 14:52:39 +00:00
mrg aadd7d4847 sprinkle some -fno-strict-aliasing and -Wno-pointer-sign with GCC4. 2006-05-11 23:16:28 +00:00
skrll 7ba7efe154 Don't use cast expressions as lvalues as newer versions of gcc warn. 2006-04-21 15:00:49 +00:00
hannken f4729837b8 Emit "a snapshot of" message for snap_internal case too. 2006-04-19 15:42:12 +00:00
christos 6edcc275a1 Coverity CID 2297: Fix memory leak. 2006-03-18 09:51:08 +00:00
perry 0f0296d88a Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete. 2005-12-24 20:45:08 +00:00
wiz e35607e772 Argument is read-blocksize, not "read blocksize". From YOMURA Masanori in private mail. 2005-09-11 23:36:55 +00:00
christos c4ee9f6d2e 64 bit inode changes 2005-08-19 02:07:18 +00:00
christos 64747563b4 sprinkle const 2005-06-27 01:37:32 +00:00
lukem a0618cd165 appease gcc -Wuninitialized 2005-06-02 00:48:48 +00:00
wiz 29d2ffbe11 Sort SEE ALSO. 2005-04-19 11:04:34 +00:00
hannken 07417a9241 Fix copyright date for previous. 2005-04-19 08:10:43 +00:00
hannken 1f51c28099 Snapshot support for dump(8):
- New option `-x backup' takes the dump from a snapshot backed up by `backup'.
  The snapshot will be deleted on exit.

- New option `-X' as a synonym for `-x mountpoint' where `mountpoint' is the
  file system to be dumped.

Reviewed and Approved by: Manuel Bouyer <bouyer@netbsd.org>
2005-04-19 07:26:38 +00:00
lukem c9e78fddc5 Signal handlers should manipulate 'volatile sig_atomic_t' instead of 'int'. 2004-08-08 09:46:16 +00:00
hannken 8c21bc6224 Add ffs internal snapshots. Written by Marshall Kirk McKusick for FreeBSD.
- Not enabled by default. Needs kernel option FFS_SNAPSHOT.
- Change parameters of ffs_blkfree.
- Let the copy-on-write functions return an error so spec_strategy
    may fail if the copy-on-write fails.
- Change genfs_*lock*() to use vp->v_vnlock instead of &vp->v_lock.
- Add flag B_METAONLY to VOP_BALLOC to return indirect block buffer.
- Add a function ffs_checkfreefile needed for snapshot creation.
- Add special handling of snapshot files:
    Snapshots may not be opened for writing and the attributes are read-only.
    Use the mtime as the time this snapshot was taken.
    Deny mtime updates for snapshot files.
- Add function transferlockers to transfer any waiting processes from
  one lock to another.
- Add vfsop VFS_SNAPSHOT to take a snapshot and make it accessible through
  a vnode.
- Add snapshot support to ls, fsck_ffs and dump.

Welcome to 2.0F.

Approved by: Jason R. Thorpe <thorpej@netbsd.org>
2004-05-25 14:54:55 +00:00
christos 6bd1d6d4db Replace the statfs() family of system calls with statvfs().
Retain binary compatibility.
2004-04-21 01:05:31 +00:00
dsl 83a830e1f1 Don't require ffsv2 fs have FS_FLAGS_UPDATED set 2004-03-27 12:59:18 +00:00
ws 7f76a970b7 After determining whether the filesystem is byte swapped,
we better return that fact to the caller.
2004-03-24 17:07:12 +00:00
hannken 7deceea338 Make the computation of estimated blocks work for frag size != 1024. 2004-03-24 12:28:51 +00:00
dsl 13e2deaa83 When searching for the superblock, don't pick an ffsv1 superblock from the
location where we expect to find an ffsv2 superblock.
It could be the first alternate for a ffsv1 filesystem with 64k blocks.
Fixes part of PR kern/24809
2004-03-21 20:30:38 +00:00
lukem b166f025eb Adjust tstart_volume (volume start time) by the time spent in query(),
similar to the adjustment for tstart_writing made in optr.c rev 1.4.
Should fix PR bin/19711 from matthew green.
2004-03-15 01:06:06 +00:00
hannken 912c7e4549 Avoid signal race condition. If a slave gets the SIGUSR2 signal between
the "setjmp" and the "ready = 1" statements the slave will pause forever
and the complet dump hangs.

Fixes PR #24453
2004-02-18 10:45:21 +00:00
simonb bb850c0c5e Use HW_USERMEM64 to fetch the amount of memory available. 2003-09-13 10:59:50 +00:00
agc bf07c8719a Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22308, verified by myself.
2003-08-07 10:04:11 +00:00
lukem 9014bdbce6 * Document $RCMD_CMD in environ(7).
* Cross-reference rcmd(1), rcmd(3), and environ(7) as appropriate.

Should fix [bin/21670] from Geoff Wing.
2003-05-26 10:18:39 +00:00
fvdl 617c9472c7 Fix byteswapping issues in dirindir(); mostly from Enami Tsugutomo. 2003-05-01 11:29:55 +00:00
fvdl 161b371dad Swap the right disk block in mapdirs() for the UFS1 case. From Enami. 2003-05-01 10:59:20 +00:00
tls 539a3fbb0a The sysctl returning the amount of memory in the system returns "int",
which is silly.  Luckily, it really does return the correct result if
interpreted as an unsigned int.  This change lets dump work on 32-bit
systems that have more than 2GB of RAM.
2003-04-19 23:29:12 +00:00
fvdl 2812e7d837 Since the size passed in may be different from the fs blocksize, just
allocate a buffer each time instead of using a static one.
2003-04-08 10:02:23 +00:00
fvdl 0835d456dd dblk should be static. Fixes PR 21020, by Geoff Wing. Patch supplied
by him.
2003-04-08 09:16:19 +00:00
fvdl 42614ed3f3 Add support for UFS2. UFS2 is an enhanced FFS, adding support for
64 bit block pointers, extended attribute storage, and a few
other things.

This commit does not yet include the code to manipulate the extended
storage (for e.g. ACLs), this will be done later.

Originally written by Kirk McKusick and Network Associates Laboratories for
FreeBSD.
2003-04-02 10:39:19 +00:00
lukem ec029d0aa9 Use "wall -g operator" (instead of private code) to broadcast() messages to
members of the operator group.
Don't install "setgid tty", and remove now unnecessary gid/egid swapping.
Remove utmp trawling code pulled in from usr.bin/who.
The Code is now simpler, and more portable (without the utmp cruft) too.

This is derived from similar work in OpenBSD.
2003-03-27 13:56:46 +00:00
wiz 990562bfef .Nm does not need a dummy argument ("") before punctuation or
for correct formatting of the SYNOPSIS any longer.
2003-02-25 10:34:36 +00:00
enami 166444b3a9 No need to print same error message twice in the same line. 2003-02-06 23:25:02 +00:00
enami 8d849f483a Check lseek error correctly (i.e., use == -1 rather than < 0). 2003-02-06 23:00:08 +00:00