Commit Graph

316 Commits

Author SHA1 Message Date
Jeffrey Altman
08ca5fc1e1 dafs-windows-vnode-locking-20080204
LICENSE MIT

allow Windows to build with dafs-vnode-locking-20080204
2008-02-04 22:41:28 +00:00
Tom Keiser
ed25934c1f dafs-vnode-locking-20080204
LICENSE IPL10
FIXES 84778

* Vnode package concurrency model was overhauled. Unlike the old model,
where concurrency was controlled via reader/writer locks, the new model
uses a per-vnode finite state automata.
* add several new volume states to deal with volume vnode list operations
* a new FSSYNC command code was added to allow volume utilities to close
out a volume operation without causing the fileserver to mount the volume
* a new FSSYNC command code was added to allow volume utilities to
transition a volume into a hard error state
* the salvageserver has been modified to keep volume group partition
path data coherent with the fileserver (like many other parts of the
volume package, this code assumes all members of the group are stored on
the same vice partition)
* make salvageserver correctly handle volume state when a child worker
process terminates abnormally
* update volume pre-attachment code to deal with move volumes across
partitions on the same server
* add volume state sanity checks to more volume package interfaces
* original vos online patch introduced a race condition; rearchitect vos
online/offline to eliminate race condition, and reduce i/o load caused
by operation
* unify duplicate code in volserver related to servicing vos examine and
vos listvol requests
* add doxygen formatted comment blocks to numerous volume package elements
* various updates to fssync-debug to allow dumping vnode state, and
updates to deal with added volume and vnode states
* several 1.5-specific fixes related to fssync and salvsync
2008-02-04 18:50:54 +00:00
Jeffrey Altman
d094c65f14 windows-cellservdb-location-20080202
LICENSE MIT

Modify the search order for determining the location of CellServDB
and other client configuration files.

1. AFSCONF environment variable
2. registry setting
3. NEW - use All Users\AppData\OpenAFS\Client only if CellServDB exists
4. use Program Files\OpenAFS\Client
2008-02-02 13:38:50 +00:00
Simon Wilkinson
43aa2bd2ba poll-drop-fsync-lock-20080201
LICENSE IPL10

update to drop fsync lock if we're using poll
2008-02-01 15:25:52 +00:00
Derrick Brashear
2e135307b5 vgetvnode-debuglog-vio-20071228
LICENSE IPL10

provide a way to log otherwise unlogged VIO error cause
2007-12-28 22:13:42 +00:00
Derrick Brashear
58dd384ba4 inode-convertro-dont-include-volser-code-in-viced-20071204
LICENSE IPL10
FIXES 77574

viced isn't an fssync client; avoid the convert volser code there
2007-12-04 21:01:12 +00:00
Hartmut Reuter
8070286d6c namei-allow-ufs-20071129
LICENSE IPL10

allow ufs again for namei. oops.
2007-11-29 21:37:00 +00:00
Rainer Toebbicke
48bcb88ddc namei-avoid-spurious-emfile-20071126
FIXES 77531

before we did not handle the fd cache runnign dry. "oops"
2007-11-26 21:47:00 +00:00
Christof Hanke
da18bb147b assorted-warning-cleanup-20071126
add missignheader files, missing return values, correct a few calls to printf
2007-11-26 21:03:31 +00:00
Derrick Brashear
473b034521 dafs-inode-convert-20071113
the dafs version of this
2007-11-14 04:34:53 +00:00
Derrick Brashear
b98b51185d inode-convert-ro-to-rw-20071113
so this functionality works with inode fileserver, also. corrected abstraction from previous versions so vol and volser have correct bits.
2007-11-13 22:15:03 +00:00
Tom Keiser
eea1cb0814 dafs-salvage-deal-with-clones-20071101
FIXES 75591

cope with trying to salvage a clone correctly
2007-11-01 14:59:38 +00:00
Simon Wilkinson
855e644261 openafs-void-star-pointers-20071031
convert anonymous pointers from char* to void*
2007-10-31 04:05:27 +00:00
Simon Wilkinson
7d05bd439e openafs-string-header-cleanup-20071030
include only what we need
2007-10-30 15:10:37 +00:00
Simon Wilkinson
d0285a2193 fssync-poll-interface-20071022
FIXES 74708

support a poll interface

otherwise, the fd setsize can screw with us
2007-10-22 18:29:28 +00:00
Derrick Brashear
409a345703 vol-salvager-avoid-logging-to-nothing-20071004
check for logFile before using
2007-10-05 04:22:27 +00:00
Tom Keiser
29d5a11a1f dafs-avoid-volhdr-leak-20070927
when there's an error don't leak the loaded header; release it
2007-09-27 17:30:32 +00:00
Derrick Brashear
1aad009863 dafs-loadvolumeheader-before-we-need-it-20070920
make sure we have a header instead of potentially dereffing null
2007-09-20 05:01:44 +00:00
Jeffrey Hutzelman
f15a9a2788 dafs-shutdown-state-fix-20070912
clean up the dafs shutdown code to not read bogus info into the id
2007-09-12 19:25:53 +00:00
Chaskiel M Grundman
c22f945bb7 namei-protect-against-extra-files-20070911
if someone is monkeying in the filesystem, sometimes they shoot themselves. save them if they renamed foo to foo.bak (where foo is a full 64 bits)
2007-09-11 16:37:01 +00:00
Derrick Brashear
049c95d74c namei-fsync-less-20070910
remove sync() call from Windows build
2007-09-10 22:54:25 +00:00
Rainer Toebbicke
dbbd59495b namei-fsync-less-20070907
FIXES 30632

we call fsync() too much. call it less, and fsync in the background
2007-09-07 05:02:09 +00:00
Jeffrey Altman
8056e9347a dafs-commit-updatelist-change-20070831
actually save the changed value
2007-08-31 15:30:27 +00:00
Derrick Brashear
aa5d46b71b clone-dont-hold-vol-lock-20070516
same deal as purge. a transaction on the volume outstanding holds it. we don't need to preclude all access

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

same deal as purge. a transaction on the volume outstanding holds it. we don't n
eed to preclude all access

====================

same deal as purge. a transaction on the volume outstanding holds it. we don't n
eed to preclude all access
2007-05-18 06:52:37 +00:00
Rainer Toebbicke
c78b4c61f7 namei-dont-randomly-full-salvage-20070514
FIXES 61300

trivial fix to clear forcep
(inode already does this)
2007-05-14 22:42:09 +00:00
Frank Cusack
08cbee9b2d fix-partition-check-20070510
oops
2007-05-10 23:41:32 +00:00
Robert Banz
af0a976f11 namei-allow-zfs-20070320
don't force AlwaysAttach on ZFS in namei
2007-03-20 18:59:22 +00:00
Derrick Brashear
a4d52ee772 use-unix-sockets-20070208
option to use unix socket for fssync
2007-02-08 23:59:16 +00:00
Jeffrey Altman
0b669007c7 windows-vol-fssync-debug-20070130
add a resource file for fssync-debug for when we decide to build it
2007-01-30 12:23:28 +00:00
Jeffrey Altman
c4a89f3f79 windows-vol-fix-salvager-20070130
The salvager on Windows was not being built properly.  The fssync-debug.c
main() was being used instead of the salvager.c main().  Remove
fssync-debug.obj from the library and fixup the includes and global
variable declarations.
2007-01-30 12:14:49 +00:00
Derrick Brashear
ba017be750 unroll-namei-delay-fsync-20070104
has been shown to cause problems with releases per haba@pdc.kth.se testing, unroll until we figure out why
2007-01-05 03:39:16 +00:00
Tom Keiser
e6b719a4c0 parallel-attaching-20061021
FIXES 43332

Some sites expect single-threaded volume attaches to happen in a specific
order. The parallel attach patch also changed the attach order for sites
not specifying -vattachpar.
2006-10-22 02:58:37 +00:00
Jeffrey Altman
0fe7b3a058 avoid-assert-for-missing-vnodes-20060928
specify the correct number of parameters for VForceOffline_r()
2006-09-28 13:58:04 +00:00
Derrick Brashear
b613480bd5 avoid-assert-for-missing-vnodes-20060921
right now if a vnode is missing when we try to clone, we could assert. ick.
2006-09-21 12:47:20 +00:00
Derrick Brashear
1221e482d7 salvage-zlc-update-20060920
avoid dealing so well with damaged namei volumes that we assume a temporary clone is damaged
2006-09-20 06:51:15 +00:00
Derrick Brashear
1c8080fe9d namei-emulate-flock-20060913
FIXES 39797

lockf when not locking and unlocking the whole file is fraught with peril
2006-09-16 00:23:18 +00:00
Peter Somogyi
e7ec36ddeb vol-voffline-avoid-early-freevolumeheader-20050906
FIXES 39422

don't free vp before we finish using it
2006-09-07 02:08:39 +00:00
Jeffrey Altman
51b862ef88 windows-vol-ntops-20060905
if the function is namei_XXX on unix then it is nt_XXXX on Windows
2006-09-06 00:47:34 +00:00
Chaskiel M Grundman
2c103b8fb3 salvage-zlc-update-20060905
deal with damaged namei volumes better
2006-09-05 15:59:46 +00:00
Jeffrey Altman
474df74c88 windows-vol-ntops-20060904
add nt_SetNonZLC()
2006-09-04 18:36:23 +00:00
Chaskiel M Grundman
96c22fdc0d salvage-zlc-20060903
make salvager deal with zero link count files
2006-09-03 06:50:12 +00:00
Chaskiel M Grundman
cd341e2fd7 nuke-do-not-pass-null-rock-20060903
don't pass a null rock inot nuke(), fixing earlier introduced bug
2006-09-03 06:32:33 +00:00
Jeffrey Hutzelman
bfdf13de06 vol-init-locallock-20060824
we never init this. oops.
2006-08-24 21:18:56 +00:00
Russ Allbery
b32073b9d3 death-to-efs-20060802
We never define AFS_SGI_EFS_IOPS_ENV any more, so kill all the now-dead
EFS code.
2006-08-03 03:57:06 +00:00
Russ Allbery
3a34d8cb4f autoconf-likes-relative-paths-20060802
When using the install-sh that ships with the source tree, Autoconf
substitutes in a relative path just to be annoying.  Define the INSTALL
variables in each individual Makefile so that they find the proper file.
Remove the definitions from Makefile.config so that no one will
accidentally get the wrong ones.
2006-08-03 03:37:12 +00:00
Russ Allbery
fc90c24df1 fs-conv-sol26-move-20060802
Take advantage of the new platform infrastructure to move fs_conv_sol26 out
of the vol directory and remove the annoying Autoconf support for
optionally build it in favor of the platform support.  We no longer care
about upgrading inode file servers on DUX, so make fs_conv_DUX4 go away.
2006-08-02 18:33:30 +00:00
Russ Allbery
4736c08e8f volume-static-mismatch-20060801
VPrintExtendedCacheStats_r should not be static.
2006-08-01 23:15:45 +00:00
Russ Allbery
8df5dcbc91 death-to-pinstall-20060801
Delete pinstall and convert the entire tree to use the install program
found by configure (falling back on install-sh in the local tree).  This
means that we have to pre-create directories with install -d.  Also redo
the install and dest rules to be lists of install rules rather than
dependencies driving separate make rules so that running make install will
always update the target directory with the current code, even if there are
files in the install area that are newer.

Stop installing libafssetpag; we're about to kill it in favor of a
different library.  Remove some djgpp rules.
2006-08-01 21:03:54 +00:00
Derrick Brashear
8c4496602b namei_mapper-20060731
add chaskiel's namei mapping tool to cvs and make a rule to build it
2006-07-31 17:50:32 +00:00
Derrick Brashear
8d2dbc51f4 call-bzero-in-convertvolumeinfo-with-correct-size-for-dotreadonly-20060731
FIXES 36442

and slipstream in bzero() killing
2006-07-31 16:18:13 +00:00
Derrick Brashear
6878e0b634 vpurge-needs-no-lock-20060713
don't hold the VOL_LOCK during vpurgevolume
volserver's transaction stuff (NewTrans, actually) precludes any problem
2006-07-13 19:17:20 +00:00
Tom Keiser
2dcf63ef4e salvager-20060628
make ClearROInUseBit actually do it
2006-06-30 14:57:43 +00:00
Tom Keiser
7826b31386 aix-largefile-cleanup-20060620
some largefile cleanup and other minor aix tweaking
2006-06-21 18:57:24 +00:00
Derrick Brashear
1e5f6a17fc namei-dec-drop-lock-20060612
FIXES 17638

unsure why yet, or even if, but this is all that makes sense
2006-06-13 00:58:33 +00:00
Rainer Toebbicke
b2b3aa1afb namei-delay-fsync-20060426
FIXES 30632

group fsync calls to speed up operations
2006-04-26 16:43:17 +00:00
Jim Rees
a64e7f34bd syntax-err-20060404
Fix syntax error (missing braces)
Fix include file ordering
Don't declare *tmpdir extern, we're initializing it here (even though
  there's no reason to)
Fix OnlyOneVolume args to match proto
2006-04-04 22:32:22 +00:00
Derrick Brashear
54ce580ef3 time-t-casting-fixes-20060404
FIXES 15169

hopefully the rest of this
2006-04-04 21:51:13 +00:00
Jim Rees
4671270758 ignore-new-targets-20060327
cvsignore new targets
2006-03-27 18:27:38 +00:00
Jeffrey Altman
095f64a7e9 windows-dafs-20060320
64-bit time_t pointer update

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

correct a type for consistency

====================

corrections to the dafs delta to allow compilation on Windows
2006-03-20 17:29:52 +00:00
Tom Keiser
51ec267011 dafs-20060317
FIXES 26648

demand attach/fast restart fileserver
2006-03-17 19:54:26 +00:00
Ed Moy
9f94892f8d darwin-x86-and-leopard-20060309
updates for darwin x86, and pre-leopard
2006-03-09 06:35:14 +00:00
Jim Rees
edd97cb225 viced-cleanup-20060222
Prototypes, dead code removal, and other minor cleanups
2006-02-22 20:29:01 +00:00
Jeffrey Altman
b02d80508f windows-64-bit-type-safety-20051105
64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

more corrections for use of 64-bit types on Windows

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler

====================

64-bit type safety changes required for successful compilation
on Windows 64-bit systems with the VS 2005 compiler
2005-11-06 09:29:36 +00:00
Derrick Brashear
93cd1ed389 hpux-vol-package-cleanup-20051101
make inode salvager large partition compliant
make namei compile cleanly again
2005-11-01 16:42:47 +00:00
Ervin Fenyak
cfa7b866c8 add-volupdate-counter-20051015
FIXES 18349

add a volume update counter. danger will robinson. see ticket for details.

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

add configure gunk

====================

add configure gunk

====================

make this happy in libadmin on e.g. solaris

====================

make this work on Windows
2005-10-23 20:05:40 +00:00
Chas Williams
1ed8428d1e irix-no-xfs-checks-for-namei-20051017
FIXES 22435

don't do inode checks when using namei
2005-10-17 21:45:39 +00:00
Hans-Werner Paulsen
2f3bdd36ee fssync-fix-log-20050721
don't call Log like it's ViceLog
2005-07-21 06:06:27 +00:00
Derrick Brashear
ea20d8d6c2 vnrehash-avoid-cachecheck-change-20050618
unlocking and locking lets us race and makes cacheCheck potentially go bad
2005-07-19 15:44:53 +00:00
Jeffrey Altman
5343ad18e3 not-cplusplus-20050530
variables must be declared at the start of a block.
2005-05-30 11:49:30 +00:00
Tom Keiser
b9ae6e9547 parallel-attaching-20050529
FIXES 18999

allow parallelization of VInitVolumePackage so attaching volumes can be sped up
2005-05-30 06:22:04 +00:00
Chaskiel M Grundman
f519e0457c volinfo-fixes-20050508
FIXES 18391

large (>31bit) volume id handling and fixed handling of cloned volumes
2005-05-08 07:09:19 +00:00
Derrick Brashear
1e75a2fdc1 vnode-nusers-avoid-potential-overflow-20050428
a byte is very small...
2005-04-28 06:02:19 +00:00
Derrick Brashear
e911b292af daemonize-log-somewhere-so-fds-can-close-without-harm-20050426
FIXES 18405

switch to VLog from printf
2005-04-27 02:36:40 +00:00
Rainer Toebbicke
6115ace770 maintain-volume-filecounts-20050424
maintain file counts in volume header
2005-04-24 15:19:55 +00:00
Peter Somogyi
9307de2fe7 aix-volser-fix-retry-20050413
FIXES 18240

destroy lock only after we gave up permanently
2005-04-14 02:59:34 +00:00
Derrick Brashear
706530c295 openafs-kill-dead-code-20050403
Code ifdef'd any of AFS_MACH_ENV, AFS_GFS_ENV, AFS_DEC_ENV dies

Code ifdef'd AFS_SUN_ENV either becomes AFS_SUN5_ENV or dies as appropriate,
in the kernel only. The database servers etc are probably still buildable,
and I still have a SunOS 4.1.4 machine. ;-) But the Solaris vnops get all
SunOS 4 code nuked.

Uses of AFS_ALPHA_ENV which secretly meant OSF/1,D/UX,Tru64 become
AFS_OSF_ENV.

Bozon lock use gets its own ifdef. OSF and Solaris define it. Darwin and any
BSDs have bozon lock usage removed: note that only OSF and Solaris were
bothering to *init* the bozon lock during NewVCache. Bozon locks are for
platforms where basically we could end up deadlocking ourselves because of
how locks are handled.

Some nonsensical ifdefs removed.
Some if 0'd code removed.
Some obsolete code (hpux pre-10, for instance) removed.
2005-04-03 19:09:05 +00:00
Derrick Brashear
af22fcd182 revert-salvager-verbosity-entirely-20050319
simply remove the verbosity added to salvager
2005-03-19 20:42:04 +00:00
Derrick Brashear
d82d85f7c4 volinfo-dont-bomb-on-attach-failure-20050310
let volinfo keep going in the face of failure
2005-03-11 02:54:49 +00:00
Karl Ramm
7c3aeba686 salvager-less-verbose-20050227
make the salvager less verbose
2005-02-27 18:31:42 +00:00
Jeffrey Hutzelman
19ff527496 implement-vpeek-for-listvol-20041211
FIXES 16765

 All of AFSVolListOneVolume, AFSVolXListOneVolume, AFSVolListVolumes,
 AFSVolXListVolumes currrently attach each volume to be listed with
 V_READONLY.  This makes the fileserver update and sync the volume header
 before releasing the volume to the volserver.  The result is that volume
 list operations are slow, and generate lots of fileserver load, as Jimmy
 pointed out during his talk this afternoon.

 The attached patch introduces a new attach mode, V_PEEK, which is like a
 cross between V_READONLY and V_SECRETLY.  It can be used for read-only
 operations on the volume header, where it is not necessary to inform the
 fileserver that the volume is being accessed.  The patch also changes
 the above-named RPC's to use the new mode.
2004-12-11 11:02:00 +00:00
Jeffrey Hutzelman
93bc285e69 vol-bless-20041202
FIXES 15928

add volume blesser
2004-12-01 22:53:30 +00:00
Horst Birthelmer
c0dd32748f aix-vol-salvage-make-malloc-not-be-cast-20041106
When you have a 64bit big endian machine with a 64bit off_t in the stat
the salvager won't work.

Malloc takes an "unsigned long" and a implicit cast will be almost
always zero :-).
2004-11-08 19:59:57 +00:00
Derrick Brashear
ee23c5f90a any-way-damnit-20041107
no comment.
2004-11-08 04:03:10 +00:00
Derrick Brashear
3f2e943d43 vol-fix-nuke-iteration-and-nuke-globals-20040928
allInodes global dies; don't use ti as an iterator right after freeing it.
2004-10-02 16:54:28 +00:00
Nickolai Zeldovich
788ca86bdc fix-indent-bug-with-lock-macros-part-two-20040818
Add trailing semicolons to _LOCK and _UNLOCK macros and re-indent.
This should've been in fix-indent-bug-with-lock-macros-20030729
but somehow it slipped by and I've only found it now.
2004-08-19 01:22:38 +00:00
Derrick Brashear
1a7e336a16 dux-vol-cleanup-20040808
make partition code work again on dux
2004-08-09 00:59:51 +00:00
Derrick Brashear
5dc0642264 fssync-more-offline-volumes-20040728
just let the offline volumes array be larger
2004-07-28 22:49:18 +00:00
Jeffrey Altman
f02a7996b9 win32-fd_set-20040719
Make sure that we do not alter the FD_SETSIZE on Windows.
On Windows this is an array of FD_SETSIZE.  FD_SETSIZE does
not define the maximum socket handle value.
2004-07-19 15:39:38 +00:00
Jeffrey Hutzelman
775933e895 rx-lwp-fdsetsize-20040708
FIXES 5615

limit our fd set size so we don't "lose" fds.
2004-07-08 06:16:55 +00:00
Derrick Brashear
4e2c9285f4 prototyping-20040623
i had this laying around, i don't know from when, but i should flush it to cvs
2004-06-23 15:27:35 +00:00
Nathan Neulinger
5191f00383 volinfo-large-size-update-20040602
FIXES 4679

make volinfo useful for >4gb
2004-06-02 08:04:15 +00:00
Love Hörnquist-Åstrand
e59d92b03e salvager-log-instead-of-abort-20040515
FIXES 4533

insert of assert, log an error
2004-05-15 07:11:40 +00:00
Nickolai Zeldovich
6f22e163a5 memory-leak-fixes-20040417
Fix some memory leaks.
2004-04-18 07:13:47 +00:00
Ed Moy
3ee6917895 macos-fstab-fun-so-fileserver-works-20040401
so we use getfsent and actually find vice partitions (and make volinfo work)
2004-04-01 23:26:22 +00:00
Chaskiel M Grundman
e1281a2014 inode-largefile-attempt-20040311
FIXES 3519

attempt to deal with large file fileservers for inode versions. not done yet
2004-03-11 20:22:07 +00:00
Derrick Brashear
ebd13b0272 fix-ih-lock-macros-20031209
FIXES 1774

probably safe to remove trailing ; in ihandle.h now too.
2003-12-09 19:58:28 +00:00
Derrick Brashear
36ac69eedc vol-linux-dont-assume-ext2-20031208
to deal simply with /usr/include/linux potentially having 2.6 kernel headers
in newer linuxes. given that we might not have ext2 as root, this check
probably wasn't sufficient anyway.
2003-12-08 07:31:57 +00:00
Derrick Brashear
6dc76e27f0 fssync-extern-loglevel-20031208
wanna use LogLevel to determine whether to log? make sure it's declared.
2003-12-08 06:09:12 +00:00
Jeffrey Altman
21caaae64f ticket-2618-patches-20031207
TICKET 2618

flexelint patches for prototype handling from Joe Beuhler

>>>>>>>>>>>>>>>>>>>>>>>>>>>>

This patch adds a bunch of missing prototypes, makes various
corrections to global prototypes, and removes global declarations that
are not needed.

One set of added prototypes is commented out because it applies to
some printf-like functions that are implemented the way it used to be
done before varargs existed, and they need to be unprototyped or the
code will fail to compile.  (There are a number of functions in the
OpenAFS code that need to be converted to use varargs...)

There is one place of note in src/WINNT/afsd/fs.c where typedefs for
afs_int32 and afs_uint32 conflict with afs/stds.h.  I just added a
note to that effect.

Prototypes in src/WINNT/afsd/fs.c are incorrect for Windows NT.  I
don't know whether the return type involved changes from platform to
platform -- they come from .xg files.

Some prototypes are now commented out or #ifdef'd to match the code
that uses them.

Some global variables conflict between modules and have been made static.
The bufferBlock variable was of two completely different types...

In src/config/stds.h, I changed the declaration of afs_intmax_t to
reflect the fact that the Windows platform supports 64 bit integers.
This may be incorrect semantically, but I believe it is needed for the
%llx format to match afs_intmax_t arguments (for printing of inodes
mainly, I believe).

There were two different declarations for the rxkad_stats structure --
I synced them up.

- Joe

Removed the conflicting typedefs from src/WINNT/afsd/fs.c

Removed the changes to src/config/stds.h.  Added declaration of
AFS_64BIT_CLIENT to src/config/NTMakefile.i386_nt40 instead.

Do not remove unused variables which are defintions of data type
values.  Instead comment them out to avoid space utilization and
warnings.
2003-12-07 22:49:00 +00:00
Derrick Brashear
ebe5567b3b salvager-remove-orphaned-header-20031204
FIXES 2522

this should be fixed for the global case, but that's harder to test
2003-12-04 17:02:38 +00:00
Kris Van Hees
8be29dc516 salvager-fix-misparented-vnode-1-20031204
if vnode 1 gets a parent (which is incorrect) arrange for it to be cleaned
up properly
2003-12-04 16:23:28 +00:00
Jeffrey Altman
61cf9fa731 jbeuhler-flexelint-bugs-found-20031128
This patch covers bugs found by running flexelint on
the CVS code on Windows NT.

- incorrect enum used in al_creds.cpp and various other files
- use of local after it goes out of scope in al_wizard.cpp
- uninitialized class members in afsclass/*
- cm_config.c looks like it has code commented out accidentally
- useless statement in alert.cpp
- no default case handling in problems.cpp
- strange use of & on booleans in set_clone.cpp
- fgets() and fclose() on closed stream in cellconfig.c
- memory leak in cellconfig.c
- *scanf into variables of unknown length in cellconfig.c
- incorrect pointer passed to getAFSServer() in cellconfig.c
- possible buffer overflows in userok.c
- address of array in bos.c
- too many arguments for printf() in commands.c
- return code not saved in bucoord/main.c
- bad types for argv arrays in bucoord/main.c
- probably incorrect initializer list in ol_verify.c
- extra argument to TLog() in lwps.c
- memory leak in cmd/cmd.c
- lack of typecast on malloc() in a couple files
- lower-case L for long constant in touch.c (is it a 1 or an l...)
- parentheses nesting error in util_cr.c
- apparently invalid case fall-through in util_cr.c
- various memory leaks in util_cr.c
- macro missing parens in crypt.c
- macro missing parens in quad_cksum.c
- null pointer deref in kpasswd.c (CVS work in progress?)
- Print_bos_ProcessState_p() code does not look correct
- extra argument to printf() in kas.c
- typo in vsprocs.c
- macro missing parens in iomgr.c
- address of array in threadname.c
- storing result of getch() in char type in waitkey.c (may not match EOF constant)
- storing pointer to local car in global in ptserver.c (benign -- it is in main())
- address of array in rx_lwp.c
- macro missing parens in rx_packet.h
- impossible == (signed vs. unsigned?) in rxdebug.c
- bogus constants in xdr.c and xdr_array.c (possible security implications?)
- incorrect test of fd for open file in update/server.c
- dangerous unparenthesized macro in get_krbrlm.c
- buffer overrun in regex.c
- missing comma causes string concat and bad array init in vlclient.c
- comparison of string < 0 in ntops.c
- default case has no code in vos.c
--
Joe Buehler

>>>>

Comments: Several comments for FIXME left in the code - unaddressed
2003-11-29 22:07:57 +00:00
Jeffrey Altman
21ca232974 jbeuhler-flexelint-fun-with-printf-20031128
This patch addresses a number of problems with printf-like functions.

Most of them are %x formats applied to pointers (which could be a
problem depending on the architecture I would assume).  There is a
%p format for pointers on many machines but I don't know if it
applies to all supported OpenAFS platforms so I didn't go that route.

There is a buffer overflow fix to ktime.c

There are a couple places where incorrect format characters were used.

One call had two arguments swapped.

Other fixes include the use of PrintInode() and %s formats for
printing inode numbers.  The code was inconsistent in this regard -- sometimes
PrintInode() was used, sometimes it was side-stepped.

There is one place where a local shadowed another variable, so I renamed
the local.

The last segment points out that an fdset need not be anything printable
with an integer format.
--
Joe Buehler

Comments - The fdset comment relates to a WinSock only file on which
the size is a pointer to int.  Modified the source to use a %p instead
of %x as it is supported on Windows.

Added an assert(p != NULL) to src/rx/rx_packet.c
2003-11-29 21:37:50 +00:00
Jeffrey Altman
10750393dc jbuelhler-flexelint-aggregate-initialization-patches-20031129
This patch mainly makes explicit some initializations that were implicit.

There are several places where it looks like the missing initialization
may be a bug, and I have inserted comments to that effect in the
relevant patches.  Someone needs to look at them and supply
whatever is missing (if anything is).

In make_keyperm.c, an array was sized too large.
--
Joe Buehler
2003-11-29 20:23:24 +00:00
Jeffrey Altman
fc7931f4f2 joe-beuhler-patches-20031122
Joe Beuhler's many patches merged into the tree
2003-11-23 04:52:52 +00:00
Derrick Brashear
5e52289abf tvolser-update-20031121
add transaction mutex to handle global list of transactions
2003-11-22 02:57:04 +00:00
Jeffrey Altman
98544e6ab4 patch-from-shadow-to-jaltman-bkbox-20031120
This massive patch contains changes in several significant areas for Windows:

- the ability to specify the mount point to be something other than /afs

- functionality to assist debugging of the NT Services

- support for languages other than English (NTLang.bat)

- revisions to the Build system to support separate trees for src, obj,
  dest and free or checked; allow any MS compiler to be used

- updates to NSIS installer build

- mutex locking added to critical locations

- updates to IS5 directory tree creation

- update to afswsNetscape_config.sh
2003-11-21 07:59:35 +00:00
Derrick Brashear
b1dd6e87cb threaded-volserver-progress-20031114
not ready for primetime. not even close.
2003-11-15 04:59:08 +00:00
Derrick Brashear
79b67c7461 namei-ihandle-leak-20031114
FIXES 2518

namei_dec now logs if you have open ihandles when you unlink a file

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================
FIXES 2518

flush all dir buffers we have cached when rewriting a volume from a restore

avoids holding an ihandle which has an open fdhandle for an unlinked file

====================
FIXES 2518

remove logging code for now. it appears to trigger on some possibly legitimate operations.
2003-11-14 23:36:16 +00:00
Ed Moy
e2e93aa892 macos103-20031024
FIXES 2325

support for macos 10.3 for 1.2.10
2003-10-24 07:25:58 +00:00
Nathan Neulinger
3467c69702 voldump-builds-with-volser-20030827
avoid circular dependancy issue.
2003-08-28 04:16:33 +00:00
Nathan Neulinger
0f97dbabce vol-dump-tool-20030824
FIXES 2008

create direct-from-disk volume dump tool
2003-08-24 22:22:39 +00:00
Derrick Brashear
8f00fdfd5f reindent-again-20030808
FIXES 1774

catch things which crept in. if emacs hadn't started ignoring my code
formatting settings this would suck so much less....
2003-08-08 22:54:30 +00:00
R. Lindsay Todd
08db75c196 large-file-support-20030808
FIXES 1493

large file support in the fileserver, again
2003-08-08 21:40:42 +00:00
Derrick Brashear
872bc94f8c reindent-20030715
FIXES 1774

thanks to nneul@umr.edu for providing a script to do this.
gnu indent 2.2.9 options:
-npro -nbad -bap -nbc -bbo -br -ce -cdw -brs -ncdb -cp1 -ncs -di2 -ndj -nfc1
-nfca -i4 -lp -npcs -nprs -psl -sc -nsob -ts8

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================
FIXES 1774

fix subst mistake
2003-07-16 00:28:24 +00:00
R. Lindsay Todd
4dd74ef182 splint-support-20030701
FIXES 1493

add splint support targets to makefiles
add support files
2003-07-02 02:03:17 +00:00
Hartmut Reuter
f43c2f4412 aix-51-support-20030701
FIXES 1661

make afs work for aix5.1 64 bit.
some code cleanup
2003-07-01 23:02:58 +00:00
Nathan Neulinger
725db719ee vol-extra-logging-on-attach-detach-20030623
FIXES 1387

add extra logging, revert in cases where you don't have log level turned up
2003-06-23 17:04:29 +00:00
Nathan Neulinger
8236e418cc more-warnings-and-prototyping-work-20030619
FIXES 1816

abstracted from work by toddr@rpi.edu
2003-06-20 01:40:15 +00:00
Chaskiel M Grundman
bc9ff0f640 windows-file-versioning-20030619
FIXES 1488

It adds:

- the binary version of the file version/productversion, which the MSI
engine sort of want files in MSI packages to all have. This requires
another variable to be maintained in NTMakefile.i386_nt40 (Please don't
change the value from 1,2,910,0 to 1,2,9,1 or something like that. The last
number group in the version is considered completely insignificant by some
things)
- some file typing, which I don't know if anything cares about
- Some new items in the stringfileinfo table, (InternalName and
OriginalFilename) without which explorer won't show use the version info in
constructing tooltip text.
- Actually setting ProductVersion and FileVersion to something real
- Language codes, which the MSI engine also wants
2003-06-19 20:00:31 +00:00
R. Lindsay Todd
befd22d01d logging-changes-for-large-files-20030619
FIXES 1493

create afs_vsnprintf. use it in FSLog. add new types which are intmax and uintmax,
32 or 64 bit as needed.. some casting.
2003-06-19 18:35:44 +00:00
R. Lindsay Todd
e110b1d34a logging-cleanup-20030602
FIXES 1493

logging function cleanup and protoizing
2003-06-02 15:37:48 +00:00
R. Lindsay Todd
df3dbd1578 splint-fileserver-volserver-cleanup-20030602
FIXES 1493

add "make splint" target for viced, vol, volser and clean up for splint
2003-06-02 15:35:59 +00:00
R. Lindsay Todd
a04ba28f72 largefile-2nd-try-base-work-20030602
FIXES 1433

another try at largefile support. macroize so things can be easily cut over
2003-06-02 15:27:54 +00:00
Jeffrey Hutzelman
e011b31bfa syslog-tags-20030515
FIXES 1266

include a program tag in syslog output
2003-05-29 19:03:14 +00:00
Derrick Brashear
36225d6573 vol-more-logging-20030515
FIXES 1453

much more to do here. start with this.
2003-05-15 17:41:25 +00:00
Jeffrey Hutzelman
5012151295 salvage-allow-hardlinked-logs-by-date-20030515
FIXES 1259

a switch causes salvager to create salvagelog hardlinks by date so
logs are preserved forever
2003-05-15 17:23:37 +00:00
Nathan Neulinger
1932dede05 vol-additional-logging-20030513
FIXES 1387

additional logging for attach/detach.
2003-05-14 15:54:53 +00:00
Nathan Neulinger
bdd9476a9a vol-gi-prototyping-20030513
FIXES 1432

changed slightly by shadow@dementia.org to not need forward decl.
2003-05-13 05:11:01 +00:00
Michael Niksch
3ab37f7148 salvager-aix-update-20030407
make it work with namei
2003-04-07 18:56:28 +00:00
Nathan Neulinger
73b4283116 revert-large-file-support-20030328
FIXES 1341

sadly there are problems. how long before this comes to the fore again
i don't know.
2003-03-28 09:35:53 +00:00
Thomas Mueller
8af8241e94 vol-ro-to-rw-tool-20030314
FIXES 1262

allow converting an ro to an rw on namei servers
2003-03-14 20:46:51 +00:00
James Peterson
5df76f7321 windows-build-updates-20030314
support for V6.0 and .Net complier, compile from either NT4.0 or XP
Source and object are separated into different directories.  The directory
tree would look as follows:

Base from %AFSROOT% environment variable
%AFSROOT%\src\... - all source and generated source
%AFSROOT%\obj\checked\... objects from a checked build
%AFSROOT%\obj\free\...    objects from a free build
%AFSROOT%\obj\dest\checked\...  DEST folder from a checked build
%AFSROOT%\obj\dest\free\....    DEST folder from a free build

Before you start the build, you must build an object tree by issuing the
following:

nmake -f NTMAKEFILE mkdir

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

support for V6.0 and .Net complier, compile from either NT4.0 or XP
Source and object are separated into different directories.  The directory
tree would look as follows:
2003-03-14 20:11:44 +00:00
Derrick Brashear
644c4935f8 vol-prototyping-20030309
prototype much of the vol package
2003-03-10 02:08:33 +00:00
Derrick Brashear
db942233a5 viced-vol-ansification-20030303
some more code ansified
2003-03-03 15:37:03 +00:00
Harald Barth
54f056cc7a nuke-create-windows-pathnames-only-on-windows-thanks-20030228
don't construct a windows path on unix
2003-03-01 01:22:08 +00:00
Derrick Brashear
0385de10a1 salvager-create-larger-buffer-for-inodes-tmpfile-and-avoid-overrun-20030224
FIXES 1318

pointed out by Hartmut Reuter
2003-02-24 16:37:03 +00:00
Derrick Brashear
454af39fbc vol-check-malloc-return-20030208
make sure malloc doesn't fail in vol package either
2003-02-08 07:38:39 +00:00
Rainer Toebbicke
cff48dcb52 rx-thread-id-assignment-fixes-20030203
in rx_pthread.c the
++rxi_pthread_hinum;
has to be protected by the rx_stats_mutex in all three cases. In the file I
attached in the openafs-devel article the last one was accidentally
unprotected.

the FSYNC_sync thread (fssync.c) needs needs to be handled as well.
2003-02-03 20:45:51 +00:00
Derrick Brashear
ec111ccc44 vol-clone-inc-failure-logging-20030117
log info in event of assert

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

same change for IH_DEC
2003-01-17 06:46:39 +00:00
Nickolai Zeldovich
3ba961ca00 Wrap our assert() macro in do{..}while(0) to make it look
just like a real function.  Fix instances of use of this
macro that lacked a trailing semicolon of their own.
2003-01-14 01:05:11 +00:00
Nathan Neulinger
ab64672f2b salvager-fast-restart-log-to-syslog-also-20030111
if -syslog, also log this to syslog
2003-01-12 02:02:48 +00:00
Nathan Neulinger
580af44321 makefiles-cflag-cleanup-20030111
move cflags back to makefile.config, more cleanup, dup removal
2003-01-11 07:33:52 +00:00
Derrick Brashear
bd72450f80 vol-package-avoid-race-on-invalidating-hashed-vnode-20030111
thanks to whichever of jhutz@cmu.edu or cg2v@andrew.cmu.edu (or both)
noticed the race; also deal with wrap problem in VolumeCacheCheck that i
noticed
2003-01-11 07:26:35 +00:00
Sam Hartman
92e76f7eb2 include-errno-dont-declare-it-20030111
include errno.h instead of extern int errno ourselves
2003-01-11 07:22:14 +00:00
R. Lindsay Todd
800b103f0a fileserver-largefile-support-20020109
Fix compile problems for 64BIT_ENV with large files turned off
2003-01-09 19:16:50 +00:00
R. Lindsay Todd
a038124edc fileserver-largefile-support-20020107
fileserver-side large file support
2003-01-07 23:38:02 +00:00
Derrick Brashear
c9f2a72c91 fssync-interface-change-to-deal-with-callback-delays-20021204
move callback breaking into a separate thread

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================

the rest of it. somehow the original version of this was lost.

====================

the rest of it. somehow the original version of this was lost.

====================

the rest of it. somehow the original version of this was lost.
2002-12-04 16:52:53 +00:00
Chaskiel M Grundman
fb3ca24729 REVERT-volserver-dont-deal-poorly-with-fssync-blockage-20021016
not ready yet, needs work
2002-12-03 02:00:24 +00:00
Derrick Brashear
3a7d53e8bd vputvnode-print-error-number-on-write-failure-20021104
make log message include error when taking volume offline
2002-11-04 20:15:38 +00:00