Index: openafs/src/JAVA/libjafs/File.c
diff -c openafs/src/JAVA/libjafs/File.c:1.3.2.1 openafs/src/JAVA/libjafs/File.c:1.3.2.2
*** openafs/src/JAVA/libjafs/File.c:1.3.2.1 Fri Oct 14 22:14:11 2005
--- openafs/src/JAVA/libjafs/File.c Tue Apr 10 14:43:28 2007
***************
*** 168,174 ****
return JNI_TRUE; /* not really an error */
} else {
fprintf(stderr, "File::setAttributes(): uafs_statmountpoint failed "
! "for %s (%s)\n", dirName, error_message(errno));
return JNI_FALSE;
}
}
--- 168,174 ----
return JNI_TRUE; /* not really an error */
} else {
fprintf(stderr, "File::setAttributes(): uafs_statmountpoint failed "
! "for %s (%s)\n", dirName, afs_error_message(errno));
return JNI_FALSE;
}
}
***************
*** 208,214 ****
}
fprintf(stderr,
"File::setAttributes(): uafs_stat failed for %s (%s)\n",
! dirName, error_message(errno));
return JNI_FALSE;
}
}
--- 208,214 ----
}
fprintf(stderr,
"File::setAttributes(): uafs_stat failed for %s (%s)\n",
! dirName, afs_error_message(errno));
return JNI_FALSE;
}
}
***************
*** 427,433 ****
dirp = uafs_opendir(dirName);
if(dirp == NULL) {
fprintf(stderr, "File::listNative(): uafs_opendir(%s) failed(%s)\n",
! dirName, error_message(errno));
setError(env, &obj, errno);
//throwAFSSecurityException( env, errno );
return 0;
--- 427,433 ----
dirp = uafs_opendir(dirName);
if(dirp == NULL) {
fprintf(stderr, "File::listNative(): uafs_opendir(%s) failed(%s)\n",
! dirName, afs_error_message(errno));
setError(env, &obj, errno);
//throwAFSSecurityException( env, errno );
return 0;
Index: openafs/src/WINNT/afsd/afskfw.c
diff -c openafs/src/WINNT/afsd/afskfw.c:1.8.2.20 openafs/src/WINNT/afsd/afskfw.c:1.8.2.21
*** openafs/src/WINNT/afsd/afskfw.c:1.8.2.20 Wed Jul 26 08:54:36 2006
--- openafs/src/WINNT/afsd/afskfw.c Wed Apr 18 11:58:22 2007
***************
*** 1422,1428 ****
}
free(principals);
}
! pkrb5_free_context(ctx);
return 0;
}
--- 1422,1429 ----
}
free(principals);
}
! if (ctx)
! pkrb5_free_context(ctx);
return 0;
}
***************
*** 1476,1482 ****
free(cells);
}
! pkrb5_free_context(ctx);
return 0;
}
--- 1477,1484 ----
free(cells);
}
! if (ctx)
! pkrb5_free_context(ctx);
return 0;
}
***************
*** 1700,1706 ****
code = -1; // we did not renew the tokens
cleanup:
! pkrb5_free_context(ctx);
return (code ? FALSE : TRUE);
}
--- 1702,1709 ----
code = -1; // we did not renew the tokens
cleanup:
! if (ctx)
! pkrb5_free_context(ctx);
return (code ? FALSE : TRUE);
}
Index: openafs/src/WINNT/afsd/cklog.c
diff -c openafs/src/WINNT/afsd/cklog.c:1.3 openafs/src/WINNT/afsd/cklog.c:1.3.2.1
*** openafs/src/WINNT/afsd/cklog.c:1.3 Fri Nov 14 22:20:01 2003
--- openafs/src/WINNT/afsd/cklog.c Tue Apr 10 14:43:34 2007
***************
*** 311,317 ****
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! com_err (rn, code, "writing Kerberos ticket file");
else fprintf (stderr, "Wrote ticket file to /tmp\n");
}
}
--- 311,317 ----
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! afs_com_err (rn, code, "writing Kerberos ticket file");
else fprintf (stderr, "Wrote ticket file to /tmp\n");
}
}
Index: openafs/src/WINNT/afsd/fs.c
diff -c openafs/src/WINNT/afsd/fs.c:1.16.2.20 openafs/src/WINNT/afsd/fs.c:1.16.2.21
*** openafs/src/WINNT/afsd/fs.c:1.16.2.20 Fri Mar 2 20:30:45 2007
--- openafs/src/WINNT/afsd/fs.c Tue Apr 10 14:43:35 2007
***************
*** 4594,4600 ****
#ifdef WIN32
fprintf(stderr, ": code 0x%x\n", code);
#else /* not WIN32 */
! fprintf(stderr,": %s\n", error_message(code));
#endif /* not WIN32 */
}
} /*Die*/
--- 4594,4600 ----
#ifdef WIN32
fprintf(stderr, ": code 0x%x\n", code);
#else /* not WIN32 */
! fprintf(stderr,": %s\n", afs_error_message(code));
#endif /* not WIN32 */
}
} /*Die*/
Index: openafs/src/WINNT/afsd/lanahelper.cpp
diff -c openafs/src/WINNT/afsd/lanahelper.cpp:1.8.2.6 openafs/src/WINNT/afsd/lanahelper.cpp:1.8.2.7
*** openafs/src/WINNT/afsd/lanahelper.cpp:1.8.2.6 Tue Feb 27 19:39:55 2007
--- openafs/src/WINNT/afsd/lanahelper.cpp Mon Oct 1 16:07:14 2007
***************
*** 445,450 ****
--- 445,451 ----
rv = RegOpenKeyEx(HKEY_LOCAL_MACHINE,AFSREG_CLT_SVC_PARAM_SUBKEY,0,KEY_READ,&hkConfig);
if (rv == ERROR_SUCCESS) {
+ dummyLen = sizeof(regLana);
rv = RegQueryValueEx(hkConfig, szForceLanaLoopback, NULL, NULL, (LPBYTE) ®Lana, &dummyLen);
RegCloseKey(hkConfig);
Index: openafs/src/WINNT/afsd/symlink.c
diff -c openafs/src/WINNT/afsd/symlink.c:1.2.20.4 openafs/src/WINNT/afsd/symlink.c:1.2.20.5
*** openafs/src/WINNT/afsd/symlink.c:1.2.20.4 Wed Aug 31 07:00:31 2005
--- openafs/src/WINNT/afsd/symlink.c Tue Apr 10 14:43:36 2007
***************
*** 652,658 ****
#ifdef WIN32
fprintf(stderr, ": code 0x%x\n", code);
#else /* not WIN32 */
! fprintf(stderr,": %s\n", error_message(code));
#endif /* not WIN32 */
}
} /*Die*/
--- 652,658 ----
#ifdef WIN32
fprintf(stderr, ": code 0x%x\n", code);
#else /* not WIN32 */
! fprintf(stderr,": %s\n", afs_error_message(code));
#endif /* not WIN32 */
}
} /*Die*/
Index: openafs/src/WINNT/afsd/sample/token.c
diff -c openafs/src/WINNT/afsd/sample/token.c:1.3 openafs/src/WINNT/afsd/sample/token.c:1.3.2.1
*** openafs/src/WINNT/afsd/sample/token.c:1.3 Fri Nov 21 02:59:45 2003
--- openafs/src/WINNT/afsd/sample/token.c Tue Apr 10 14:43:36 2007
***************
*** 276,282 ****
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! com_err (rn, code, "writing Kerberos ticket file");
else fprintf (stderr, "Wrote ticket file to /tmp\n");
}
}
--- 276,282 ----
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! afs_com_err (rn, code, "writing Kerberos ticket file");
else fprintf (stderr, "Wrote ticket file to /tmp\n");
}
}
Index: openafs/src/WINNT/afsreg/test/regman.c
diff -c openafs/src/WINNT/afsreg/test/regman.c:1.3 openafs/src/WINNT/afsreg/test/regman.c:1.3.8.1
*** openafs/src/WINNT/afsreg/test/regman.c:1.3 Tue Sep 18 00:26:55 2001
--- openafs/src/WINNT/afsreg/test/regman.c Tue Apr 10 14:43:37 2007
***************
*** 60,71 ****
vpDev = as->parms[1].items->data;
if (!vpt_PartitionNameValid(vpName)) {
! com_err(whoami, 0, "Partition name invalid");
return 1;
}
if (!vpt_DeviceNameValid(vpDev)) {
! com_err(whoami, 0, "Device name invalid");
return 1;
}
--- 60,71 ----
vpDev = as->parms[1].items->data;
if (!vpt_PartitionNameValid(vpName)) {
! afs_com_err(whoami, 0, "Partition name invalid");
return 1;
}
if (!vpt_DeviceNameValid(vpDev)) {
! afs_com_err(whoami, 0, "Device name invalid");
return 1;
}
***************
*** 73,79 ****
strcpy(vpentry.vp_dev, vpDev);
if (vpt_AddEntry(&vpentry)) {
! com_err(whoami, 0, "Unable to create vice partition table entry");
return 1;
}
return 0;
--- 73,79 ----
strcpy(vpentry.vp_dev, vpDev);
if (vpt_AddEntry(&vpentry)) {
! afs_com_err(whoami, 0, "Unable to create vice partition table entry");
return 1;
}
return 0;
***************
*** 86,97 ****
vpName = as->parms[0].items->data;
if (!vpt_PartitionNameValid(vpName)) {
! com_err(whoami, 0, "Partition name invalid");
return 1;
}
if (vpt_RemoveEntry(vpName) && errno != ENOENT) {
! com_err(whoami, 0, "Unable to remove vice partition table entry");
return 1;
}
return 0;
--- 86,97 ----
vpName = as->parms[0].items->data;
if (!vpt_PartitionNameValid(vpName)) {
! afs_com_err(whoami, 0, "Partition name invalid");
return 1;
}
if (vpt_RemoveEntry(vpName) && errno != ENOENT) {
! afs_com_err(whoami, 0, "Unable to remove vice partition table entry");
return 1;
}
return 0;
***************
*** 103,109 ****
char *buf;
if (afssw_GetServerInstallDir(&buf)) {
! com_err(whoami, 0,
"Failed reading AFS install dir entry (or does not exist)");
return 1;
}
--- 103,109 ----
char *buf;
if (afssw_GetServerInstallDir(&buf)) {
! afs_com_err(whoami, 0,
"Failed reading AFS install dir entry (or does not exist)");
return 1;
}
***************
*** 136,142 ****
}
if (status) {
! com_err(whoami, 0, "Unable to set AFS installation directory entry");
}
return (status ? 1 : 0);
--- 136,142 ----
}
if (status) {
! afs_com_err(whoami, 0, "Unable to set AFS installation directory entry");
}
return (status ? 1 : 0);
***************
*** 157,163 ****
char *dirBuf;
if (afssw_GetServerInstallDir(&dirBuf)) {
! com_err(whoami, 0,
"binary path not specified and AFS server installation directory not set");
return 1;
}
--- 157,163 ----
char *dirBuf;
if (afssw_GetServerInstallDir(&dirBuf)) {
! afs_com_err(whoami, 0,
"binary path not specified and AFS server installation directory not set");
return 1;
}
***************
*** 177,183 ****
if (status == ERROR_ACCESS_DENIED) {
reason = "(insufficient privilege)";
}
! com_err(whoami, 0, "unable to connect to the SCM %s", reason);
return 1;
}
--- 177,183 ----
if (status == ERROR_ACCESS_DENIED) {
reason = "(insufficient privilege)";
}
! afs_com_err(whoami, 0, "unable to connect to the SCM %s", reason);
return 1;
}
***************
*** 202,208 ****
if (status == ERROR_SERVICE_EXISTS || status == ERROR_DUP_NAME) {
reason = "(service or display name already exists)";
}
! com_err(whoami, 0, "unable to create service %s", reason);
CloseServiceHandle(scmHandle);
return 1;
}
--- 202,208 ----
if (status == ERROR_SERVICE_EXISTS || status == ERROR_DUP_NAME) {
reason = "(service or display name already exists)";
}
! afs_com_err(whoami, 0, "unable to create service %s", reason);
CloseServiceHandle(scmHandle);
return 1;
}
***************
*** 227,233 ****
if (status == ERROR_ACCESS_DENIED) {
reason = "(insufficient privilege)";
}
! com_err(whoami, 0, "unable to connect to the SCM %s", reason);
return 1;
}
--- 227,233 ----
if (status == ERROR_ACCESS_DENIED) {
reason = "(insufficient privilege)";
}
! afs_com_err(whoami, 0, "unable to connect to the SCM %s", reason);
return 1;
}
***************
*** 238,244 ****
DWORD status = GetLastError();
if (status != ERROR_SERVICE_DOES_NOT_EXIST) {
! com_err(whoami, 0, "unable to open service");
rc = 1;
}
CloseServiceHandle(scmHandle);
--- 238,244 ----
DWORD status = GetLastError();
if (status != ERROR_SERVICE_DOES_NOT_EXIST) {
! afs_com_err(whoami, 0, "unable to open service");
rc = 1;
}
CloseServiceHandle(scmHandle);
***************
*** 249,255 ****
DWORD status = GetLastError();
if (status != ERROR_SERVICE_MARKED_FOR_DELETE) {
! com_err(whoami, 0, "service delete failed");
rc = 1;
}
}
--- 249,255 ----
DWORD status = GetLastError();
if (status != ERROR_SERVICE_MARKED_FOR_DELETE) {
! afs_com_err(whoami, 0, "service delete failed");
rc = 1;
}
}
Index: openafs/src/WINNT/aklog/NTMakefile
diff -c openafs/src/WINNT/aklog/NTMakefile:1.2.2.1 openafs/src/WINNT/aklog/NTMakefile:1.2.2.2
*** openafs/src/WINNT/aklog/NTMakefile:1.2.2.1 Sun Jun 12 07:26:15 2005
--- openafs/src/WINNT/aklog/NTMakefile Tue Apr 10 14:43:38 2007
***************
*** 28,35 ****
EXELIBS = \
$(DESTDIR)\lib\afs\afspioctl.lib \
! $(DESTDIR)\lib\afsauthent.lib \
! $(DESTDIR)\lib\afs\afskauth.lib
OTHERLIBS = \
..\kfw\lib\i386\krbv4w32.lib \
--- 28,37 ----
EXELIBS = \
$(DESTDIR)\lib\afs\afspioctl.lib \
! $(DESTDIR)\lib\afsauthent.lib \
! $(DESTDIR)\lib\afs\afskauth.lib \
! $(DESTDIR)\lib\afs\afscom_err.lib \
! $(DESTDIR)\lib\afs\afsutil.lib
OTHERLIBS = \
..\kfw\lib\i386\krbv4w32.lib \
Index: openafs/src/WINNT/aklog/asetkey.c
diff -c openafs/src/WINNT/aklog/asetkey.c:1.1.2.2 openafs/src/WINNT/aklog/asetkey.c:1.1.2.3
*** openafs/src/WINNT/aklog/asetkey.c:1.1.2.2 Sun Jun 12 07:26:15 2005
--- openafs/src/WINNT/aklog/asetkey.c Tue Apr 10 14:43:39 2007
***************
*** 1,5 ****
/*
! * $Id: asetkey.c,v 1.1.2.2 2005/06/12 11:26:15 jaltman Exp $
*
* asetkey - Manipulates an AFS KeyFile
*
--- 1,5 ----
/*
! * $Id: asetkey.c,v 1.1.2.3 2007/04/10 18:43:39 shadow Exp $
*
* asetkey - Manipulates an AFS KeyFile
*
***************
*** 17,22 ****
--- 17,23 ----
#ifndef PRE_AFS35
#include
#endif /* !PRE_AFS35 */
+ #include
int
main(int argc, char **argv)
***************
*** 61,73 ****
kvno = atoi(argv[2]);
retval = krb5_parse_name(context, argv[4], &principal);
if (retval != 0) {
! com_err(argv[0], retval, "while parsing AFS principal");
exit(1);
}
retval = krb5_kt_read_service_key(context, argv[3], principal, kvno,
ENCTYPE_DES_CBC_CRC, &key);
if (retval != 0) {
! com_err(argv[0], retval, "while extracting AFS service key");
exit(1);
}
--- 62,74 ----
kvno = atoi(argv[2]);
retval = krb5_parse_name(context, argv[4], &principal);
if (retval != 0) {
! afs_com_err(argv[0], retval, "while parsing AFS principal");
exit(1);
}
retval = krb5_kt_read_service_key(context, argv[3], principal, kvno,
ENCTYPE_DES_CBC_CRC, &key);
if (retval != 0) {
! afs_com_err(argv[0], retval, "while extracting AFS service key");
exit(1);
}
Index: openafs/src/WINNT/doc/install/Documentation/en_US/html/index.htm
diff -c openafs/src/WINNT/doc/install/Documentation/en_US/html/index.htm:1.1.24.6 openafs/src/WINNT/doc/install/Documentation/en_US/html/index.htm:1.1.24.7
*** openafs/src/WINNT/doc/install/Documentation/en_US/html/index.htm:1.1.24.6 Fri Jan 5 15:15:41 2007
--- openafs/src/WINNT/doc/install/Documentation/en_US/html/index.htm Sat Jun 23 10:48:26 2007
***************
*** 198,204 ****
OpenAFS for Windows
! Version 1.4.3
--- 198,204 ----
OpenAFS for Windows
! Version 1.4.4
***************
*** 223,229 ****
mso-fareast-font-family:Symbol;mso-bidi-font-family:Symbol'>·
OpenAFS for Windows
Release Notes
·
OpenAFS for Windows 1.4.4
Release Notes
tproa.net #The People's Republic of Ames
! 209.234.76.70 #service-3.tproa.net
! 209.234.76.75 #service-4.tproa.net
! 209.234.76.76 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
--- 488,496 ----
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 72.13.4.23 #service-3.tproa.net
! 72.13.4.24 #service-4.tproa.net
! 72.13.4.25 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
***************
*** 519,526 ****
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
- 130.237.209.39 #ezri.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
--- 529,536 ----
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
+ 130.237.209.5 #afsdb2.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
***************
*** 546,552 ****
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.237.230 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
--- 556,562 ----
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.234.101 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
Index: openafs/src/WINNT/install/Win9x/CellServDB
diff -c openafs/src/WINNT/install/Win9x/CellServDB:1.2.2.6 openafs/src/WINNT/install/Win9x/CellServDB:1.2.2.7
*** openafs/src/WINNT/install/Win9x/CellServDB:1.2.2.6 Fri Mar 9 23:52:52 2007
--- openafs/src/WINNT/install/Win9x/CellServDB Thu Jul 5 19:44:59 2007
***************
*** 1,4 ****
! >grand.central.org #GCO Public CellServDB 09 Mar 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
--- 1,4 ----
! >grand.central.org #GCO Public CellServDB 05 Jul 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
***************
*** 18,23 ****
--- 18,26 ----
129.27.161.7 #faepafs1.tu-graz.ac.at
129.27.161.15 #faepafs2.tu-graz.ac.at
129.27.161.114 #faepafs3.tu-graz.ac.at
+ >sums.math.mcgill.ca #Society of Undergraduate Mathematics Students of McGill Universi
+ 132.216.24.122 #germain.sums.math.mcgill.ca
+ 132.216.24.125 #turing.sums.math.mcgill.ca
>cern.ch #European Laboratory for Particle Physics, Geneva
137.138.128.148 #afsdb1.cern.ch
137.138.246.50 #afsdb3.cern.ch
***************
*** 110,115 ****
--- 113,120 ----
141.35.2.180 #afs00.rz.uni-jena.de
141.35.2.181 #afs01.rz.uni-jena.de
141.35.2.182 #afs02.rz.uni-jena.de
+ >impetus.uni-koeln.de #Univ. of Cologne - Geophysics/Meteorology Inst.
+ 134.95.80.39 #forano.meteo.uni-koeln.de
>meteo.uni-koeln.de #Univ. of Cologne - Inst. for Geophysics & Meteorology
134.95.144.22 #afs1.meteo.uni-koeln.de
134.95.144.24 #afs2.meteo.uni-koeln.de
***************
*** 161,183 ****
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.194.178 #cherry.srv.cs.cmu.edu
! 128.2.194.179 #pumpkin.srv.cs.cmu.edu
! 128.2.194.180 #strawberry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar Campus Cell
! 204.194.25.7 #afs1.qatar.cmu.edu
! 204.194.25.8 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #Cornell Nanoscale Science and Technology Facility
128.253.198.9 #hole.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
--- 166,189 ----
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.201.46 #strawberry.srv.cs.cmu.edu
! 128.2.201.47 #pumpkin.srv.cs.cmu.edu
! 128.2.201.48 #cherry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar
! 86.36.46.6 #afs1.qatar.cmu.edu
! 86.36.46.7 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #CNF
128.253.198.9 #hole.cnf.cornell.edu
+ 128.253.198.27 #smoke.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
***************
*** 285,290 ****
--- 291,300 ----
128.174.251.8 #alnitak.acm.uiuc.edu
128.174.251.9 #alnilam.acm.uiuc.edu
128.174.251.10 #mintaka.acm.uiuc.edu
+ >illigal.uiuc.edu #Illinois Genetic Algorithms Labaratory
+ 128.174.193.200 #ial.illigal.uiuc.edu
+ 128.174.193.201 #cac.illigal.uiuc.edu
+ 128.174.193.202 #gcs.illigal.uiuc.edu
>ncsa.uiuc.edu #University of Illinois
141.142.3.5 #congo.ncsa.uiuc.edu
141.142.3.8 #nile.ncsa.uiuc.edu
***************
*** 478,486 ****
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 209.234.76.70 #service-3.tproa.net
! 209.234.76.75 #service-4.tproa.net
! 209.234.76.76 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
--- 488,496 ----
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 72.13.4.23 #service-3.tproa.net
! 72.13.4.24 #service-4.tproa.net
! 72.13.4.25 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
***************
*** 519,526 ****
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
- 130.237.209.39 #ezri.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
--- 529,536 ----
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
+ 130.237.209.5 #afsdb2.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
***************
*** 546,552 ****
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.237.230 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
--- 556,562 ----
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.234.101 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
Index: openafs/src/WINNT/install/wix/CellServDB
diff -c openafs/src/WINNT/install/wix/CellServDB:1.2.2.6 openafs/src/WINNT/install/wix/CellServDB:1.2.2.7
*** openafs/src/WINNT/install/wix/CellServDB:1.2.2.6 Fri Mar 9 23:52:52 2007
--- openafs/src/WINNT/install/wix/CellServDB Thu Jul 5 19:44:59 2007
***************
*** 1,4 ****
! >grand.central.org #GCO Public CellServDB 09 Mar 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
--- 1,4 ----
! >grand.central.org #GCO Public CellServDB 05 Jul 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
***************
*** 18,23 ****
--- 18,26 ----
129.27.161.7 #faepafs1.tu-graz.ac.at
129.27.161.15 #faepafs2.tu-graz.ac.at
129.27.161.114 #faepafs3.tu-graz.ac.at
+ >sums.math.mcgill.ca #Society of Undergraduate Mathematics Students of McGill Universi
+ 132.216.24.122 #germain.sums.math.mcgill.ca
+ 132.216.24.125 #turing.sums.math.mcgill.ca
>cern.ch #European Laboratory for Particle Physics, Geneva
137.138.128.148 #afsdb1.cern.ch
137.138.246.50 #afsdb3.cern.ch
***************
*** 110,115 ****
--- 113,120 ----
141.35.2.180 #afs00.rz.uni-jena.de
141.35.2.181 #afs01.rz.uni-jena.de
141.35.2.182 #afs02.rz.uni-jena.de
+ >impetus.uni-koeln.de #Univ. of Cologne - Geophysics/Meteorology Inst.
+ 134.95.80.39 #forano.meteo.uni-koeln.de
>meteo.uni-koeln.de #Univ. of Cologne - Inst. for Geophysics & Meteorology
134.95.144.22 #afs1.meteo.uni-koeln.de
134.95.144.24 #afs2.meteo.uni-koeln.de
***************
*** 161,183 ****
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.194.178 #cherry.srv.cs.cmu.edu
! 128.2.194.179 #pumpkin.srv.cs.cmu.edu
! 128.2.194.180 #strawberry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar Campus Cell
! 204.194.25.7 #afs1.qatar.cmu.edu
! 204.194.25.8 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #Cornell Nanoscale Science and Technology Facility
128.253.198.9 #hole.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
--- 166,189 ----
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.201.46 #strawberry.srv.cs.cmu.edu
! 128.2.201.47 #pumpkin.srv.cs.cmu.edu
! 128.2.201.48 #cherry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar
! 86.36.46.6 #afs1.qatar.cmu.edu
! 86.36.46.7 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #CNF
128.253.198.9 #hole.cnf.cornell.edu
+ 128.253.198.27 #smoke.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
***************
*** 285,290 ****
--- 291,300 ----
128.174.251.8 #alnitak.acm.uiuc.edu
128.174.251.9 #alnilam.acm.uiuc.edu
128.174.251.10 #mintaka.acm.uiuc.edu
+ >illigal.uiuc.edu #Illinois Genetic Algorithms Labaratory
+ 128.174.193.200 #ial.illigal.uiuc.edu
+ 128.174.193.201 #cac.illigal.uiuc.edu
+ 128.174.193.202 #gcs.illigal.uiuc.edu
>ncsa.uiuc.edu #University of Illinois
141.142.3.5 #congo.ncsa.uiuc.edu
141.142.3.8 #nile.ncsa.uiuc.edu
***************
*** 478,486 ****
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 209.234.76.70 #service-3.tproa.net
! 209.234.76.75 #service-4.tproa.net
! 209.234.76.76 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
--- 488,496 ----
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 72.13.4.23 #service-3.tproa.net
! 72.13.4.24 #service-4.tproa.net
! 72.13.4.25 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
***************
*** 519,526 ****
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
- 130.237.209.39 #ezri.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
--- 529,536 ----
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
+ 130.237.209.5 #afsdb2.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
***************
*** 546,552 ****
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.237.230 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
--- 556,562 ----
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.234.101 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
Index: openafs/src/WINNT/install/wix/files.wxi
diff -c openafs/src/WINNT/install/wix/files.wxi:1.9.2.11 openafs/src/WINNT/install/wix/files.wxi:1.9.2.12
*** openafs/src/WINNT/install/wix/files.wxi:1.9.2.11 Tue Jul 18 12:10:22 2006
--- openafs/src/WINNT/install/wix/files.wxi Fri Apr 20 06:59:41 2007
***************
*** 686,692 ****
!
--- 686,692 ----
!
Index: openafs/src/WINNT/win9xpanel/CAfs.cpp
diff -c openafs/src/WINNT/win9xpanel/CAfs.cpp:1.2 openafs/src/WINNT/win9xpanel/CAfs.cpp:1.2.14.1
*** openafs/src/WINNT/win9xpanel/CAfs.cpp:1.2 Sun Aug 19 10:44:46 2001
--- openafs/src/WINNT/win9xpanel/CAfs.cpp Tue Apr 10 14:43:40 2007
***************
*** 353,359 ****
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! com_err (rn, code, "writing Kerberos ticket file");
else {
m_pParent->Log("Wrote ticket file to /tmp");
}
--- 353,359 ----
code = krb_write_ticket_file (realm);
if (!Silent) {
if (code)
! afs_com_err (rn, code, "writing Kerberos ticket file");
else {
m_pParent->Log("Wrote ticket file to /tmp");
}
Index: openafs/src/WINNT/win9xpanel/CellServDB
diff -c openafs/src/WINNT/win9xpanel/CellServDB:1.1.18.6 openafs/src/WINNT/win9xpanel/CellServDB:1.1.18.7
*** openafs/src/WINNT/win9xpanel/CellServDB:1.1.18.6 Fri Mar 9 23:52:52 2007
--- openafs/src/WINNT/win9xpanel/CellServDB Thu Jul 5 19:44:59 2007
***************
*** 1,4 ****
! >grand.central.org #GCO Public CellServDB 09 Mar 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
--- 1,4 ----
! >grand.central.org #GCO Public CellServDB 05 Jul 2007
18.92.0.108 #grand-opening.mit.edu
128.2.203.61 #penn.central.org
130.237.48.87 #andrew.e.kth.se
***************
*** 18,23 ****
--- 18,26 ----
129.27.161.7 #faepafs1.tu-graz.ac.at
129.27.161.15 #faepafs2.tu-graz.ac.at
129.27.161.114 #faepafs3.tu-graz.ac.at
+ >sums.math.mcgill.ca #Society of Undergraduate Mathematics Students of McGill Universi
+ 132.216.24.122 #germain.sums.math.mcgill.ca
+ 132.216.24.125 #turing.sums.math.mcgill.ca
>cern.ch #European Laboratory for Particle Physics, Geneva
137.138.128.148 #afsdb1.cern.ch
137.138.246.50 #afsdb3.cern.ch
***************
*** 110,115 ****
--- 113,120 ----
141.35.2.180 #afs00.rz.uni-jena.de
141.35.2.181 #afs01.rz.uni-jena.de
141.35.2.182 #afs02.rz.uni-jena.de
+ >impetus.uni-koeln.de #Univ. of Cologne - Geophysics/Meteorology Inst.
+ 134.95.80.39 #forano.meteo.uni-koeln.de
>meteo.uni-koeln.de #Univ. of Cologne - Inst. for Geophysics & Meteorology
134.95.144.22 #afs1.meteo.uni-koeln.de
134.95.144.24 #afs2.meteo.uni-koeln.de
***************
*** 161,183 ****
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.194.178 #cherry.srv.cs.cmu.edu
! 128.2.194.179 #pumpkin.srv.cs.cmu.edu
! 128.2.194.180 #strawberry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar Campus Cell
! 204.194.25.7 #afs1.qatar.cmu.edu
! 204.194.25.8 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #Cornell Nanoscale Science and Technology Facility
128.253.198.9 #hole.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
--- 166,189 ----
128.2.40.134 #afs.chem.cmu.edu
128.2.40.140 #afs2.chem.cmu.edu
>cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
! 128.2.201.46 #strawberry.srv.cs.cmu.edu
! 128.2.201.47 #pumpkin.srv.cs.cmu.edu
! 128.2.201.48 #cherry.srv.cs.cmu.edu
>ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
128.2.129.7 #porok.ece.cmu.edu
128.2.129.8 #vicio.ece.cmu.edu
128.2.129.9 #e-xing.ece.cmu.edu
>scotch.ece.cmu.edu #CMU ECE CALCM research group
128.2.134.82 #lagavulin.ece.cmu.edu
! >qatar.cmu.edu #Carnegie Mellon University - Qatar
! 86.36.46.6 #afs1.qatar.cmu.edu
! 86.36.46.7 #afs2.qatar.cmu.edu
>sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
128.2.179.12 #nihao.sbp.ri.cmu.edu
128.2.179.113 #youtheman.sbp.ri.cmu.edu
! >cnf.cornell.edu #CNF
128.253.198.9 #hole.cnf.cornell.edu
+ 128.253.198.27 #smoke.cnf.cornell.edu
>msc.cornell.edu #Cornell University Materials Science Center
128.84.231.242 #miranda.ccmr.cornell.edu
128.84.241.35 #co.ccmr.cornell.edu
***************
*** 285,290 ****
--- 291,300 ----
128.174.251.8 #alnitak.acm.uiuc.edu
128.174.251.9 #alnilam.acm.uiuc.edu
128.174.251.10 #mintaka.acm.uiuc.edu
+ >illigal.uiuc.edu #Illinois Genetic Algorithms Labaratory
+ 128.174.193.200 #ial.illigal.uiuc.edu
+ 128.174.193.201 #cac.illigal.uiuc.edu
+ 128.174.193.202 #gcs.illigal.uiuc.edu
>ncsa.uiuc.edu #University of Illinois
141.142.3.5 #congo.ncsa.uiuc.edu
141.142.3.8 #nile.ncsa.uiuc.edu
***************
*** 478,486 ****
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 209.234.76.70 #service-3.tproa.net
! 209.234.76.75 #service-4.tproa.net
! 209.234.76.76 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
--- 488,496 ----
>slackers.net #The Slackers' Network
63.201.48.27 #alexandria.slackers.net
>tproa.net #The People's Republic of Ames
! 72.13.4.23 #service-3.tproa.net
! 72.13.4.24 #service-4.tproa.net
! 72.13.4.25 #service-5.tproa.net
>nikhef.nl #The Dutch National Institute for High Energy Physics
192.16.185.26 #afs1.nikhef.nl
192.16.185.27 #afs2.nikhef.nl
***************
*** 519,526 ****
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
- 130.237.209.39 #ezri.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
--- 529,536 ----
130.237.24.104 #afs2.hallf.kth.se
>isk.kth.se #Royal Institute of Technology, ISK
130.237.202.3 #afsdb1.isk.kth.se
+ 130.237.209.5 #afsdb2.isk.kth.se
130.237.209.9 #afsdb3.isk.kth.se
>it.kth.se #Royal Institute of Technology, IT
130.237.212.15 #ptah.it.kth.se
130.237.212.16 #toth.it.kth.se
***************
*** 546,552 ****
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.237.230 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
--- 556,562 ----
>stacken.kth.se #Stacken Computer Club
130.237.234.3 #milko.stacken.kth.se
130.237.234.43 #hot.stacken.kth.se
! 130.237.234.101 #fishburger.stacken.kth.se
>syd.kth.se #Royal Institute of Technology, KTH-Syd
130.237.83.23 #afs.haninge.kth.se
>physto.se #Physics department Stockholm University
Index: openafs/src/afs/afs.h
diff -c openafs/src/afs/afs.h:1.48.2.29 openafs/src/afs/afs.h:1.48.2.30
*** openafs/src/afs/afs.h:1.48.2.29 Thu Nov 9 19:08:52 2006
--- openafs/src/afs/afs.h Wed Oct 10 12:57:54 2007
***************
*** 268,273 ****
--- 268,276 ----
extern afs_int32 afs_gcpags;
extern afs_int32 afs_gcpags_procsize;
extern afs_int32 afs_bkvolpref;
+ extern char afs_cachebasedir[1024];
+ extern afs_int32 afs_numcachefiles;
+ extern afs_int32 afs_numfilesperdir;
struct unixuser {
struct unixuser *next; /* next hash pointer */
Index: openafs/src/afs/afs_call.c
diff -c openafs/src/afs/afs_call.c:1.74.2.17 openafs/src/afs/afs_call.c:1.74.2.23
*** openafs/src/afs/afs_call.c:1.74.2.17 Thu Feb 8 20:07:54 2007
--- openafs/src/afs/afs_call.c Wed Oct 10 12:57:54 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_call.c,v 1.74.2.17 2007/02/09 01:07:54 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_call.c,v 1.74.2.23 2007/10/10 16:57:54 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 29,35 ****
#ifdef AFS_LINUX22_ENV
#include "h/smp_lock.h"
#endif
!
#if defined(AFS_SUN5_ENV) || defined(AFS_AIX_ENV) || defined(AFS_SGI_ENV) || defined(AFS_HPUX_ENV)
#define AFS_MINBUFFERS 100
--- 29,38 ----
#ifdef AFS_LINUX22_ENV
#include "h/smp_lock.h"
#endif
! #ifdef AFS_SUN510_ENV
! #include "h/ksynch.h"
! #include "h/sunddi.h"
! #endif
#if defined(AFS_SUN5_ENV) || defined(AFS_AIX_ENV) || defined(AFS_SGI_ENV) || defined(AFS_HPUX_ENV)
#define AFS_MINBUFFERS 100
***************
*** 84,89 ****
--- 87,97 ----
simple_lock_data afs_global_lock;
#endif
+ #ifdef AFS_SUN510_ENV
+ ddi_taskq_t *afs_taskq;
+ krwlock_t afsifinfo_lock;
+ #endif
+
afs_int32 afs_initState = 0;
afs_int32 afs_termState = 0;
afs_int32 afs_setTime = 0;
***************
*** 96,101 ****
--- 104,112 ----
extern struct interfaceAddr afs_cb_interface;
static int afs_RX_Running = 0;
static int afs_InitSetup_done = 0;
+ afs_int32 afs_numcachefiles = -1;
+ afs_int32 afs_numfilesperdir = -1;
+ char afs_cachebasedir[1024];
afs_int32 afs_rx_deadtime = AFS_RXDEADTIME;
afs_int32 afs_rx_harddead = AFS_HARDDEADTIME;
***************
*** 121,126 ****
--- 132,147 ----
if (afs_InitSetup_done)
return EAGAIN;
+ #ifdef AFS_SUN510_ENV
+ /* Initialize a RW lock for the ifinfo global array */
+ rw_init(&afsifinfo_lock, NULL, RW_DRIVER, NULL);
+
+ /* Create a taskq */
+ afs_taskq = ddi_taskq_create(NULL, "afs_taskq", 2, TASKQ_DEFAULTPRI, 0);
+
+ osi_StartNetIfPoller();
+ #endif
+
#ifndef AFS_NOSTATS
/*
* Set up all the AFS statistics variables. This should be done
***************
*** 484,489 ****
--- 505,521 ----
}
#endif
+ static void
+ wait_for_cachedefs(void) {
+ #ifdef AFS_CACHE_VNODE_PATH
+ while ((afs_numcachefiles < 1) || (afs_numfilesperdir < 1) ||
+ (afs_cachebasedir[0] != '/')) {
+ printf("afs: waiting for cache parameter definitions\n");
+ afs_osi_Sleep(&afs_initState);
+ }
+ #endif
+ }
+
/* leaving as is, probably will barf if we add prototypes here since it's likely being called
with partial list */
int
***************
*** 498,523 ****
#endif /* AFS_SGI61_ENV */
AFS_STATCNT(afs_syscall_call);
#ifdef AFS_SUN5_ENV
! if (!afs_suser(CRED()) && (parm != AFSOP_GETMTU)
! && (parm != AFSOP_GETMASK)) {
! /* only root can run this code */
! return (EACCES);
#else
! if (!afs_suser(NULL) && (parm != AFSOP_GETMTU)
! && (parm != AFSOP_GETMASK)) {
/* only root can run this code */
#if defined(KERNEL_HAVE_UERROR)
! setuerror(EACCES);
! return (EACCES);
#else
! #if defined(AFS_OSF_ENV)
! return EACCES;
! #else /* AFS_OSF_ENV */
! return EPERM;
! #endif /* AFS_OSF_ENV */
#endif
#endif
}
AFS_GLOCK();
#ifdef AFS_DARWIN80_ENV
--- 530,556 ----
#endif /* AFS_SGI61_ENV */
AFS_STATCNT(afs_syscall_call);
+ if (
#ifdef AFS_SUN5_ENV
! !afs_suser(CRED())
#else
! !afs_suser(NULL)
! #endif
! && (parm != AFSOP_GETMTU) && (parm != AFSOP_GETMASK)) {
/* only root can run this code */
+ #if defined(AFS_OSF_ENV) || defined(AFS_SUN5_ENV) || defined(KERNEL_HAVE_UERROR)
#if defined(KERNEL_HAVE_UERROR)
! setuerror(EACCES);
! #endif
! code = EACCES;
#else
! code = EPERM;
#endif
+ AFS_GLOCK();
+ #ifdef AFS_DARWIN80_ENV
+ put_vfs_context();
#endif
+ goto out;
}
AFS_GLOCK();
#ifdef AFS_DARWIN80_ENV
***************
*** 792,798 ****
afs_osi_Sleep(&afs_initState);
#ifdef AFS_DARWIN80_ENV
! get_vfs_context();
#endif
/* do it by inode */
#ifdef AFS_SGI62_ENV
--- 825,831 ----
afs_osi_Sleep(&afs_initState);
#ifdef AFS_DARWIN80_ENV
! get_vfs_context();
#endif
/* do it by inode */
#ifdef AFS_SGI62_ENV
***************
*** 800,807 ****
#endif
code = afs_InitCacheFile(NULL, ainode);
#ifdef AFS_DARWIN80_ENV
! put_vfs_context();
#endif
} else if (parm == AFSOP_ROOTVOLUME) {
/* wait for basic init */
while (afs_initState < AFSOP_START_BKG)
--- 833,846 ----
#endif
code = afs_InitCacheFile(NULL, ainode);
#ifdef AFS_DARWIN80_ENV
! put_vfs_context();
#endif
+ } else if (parm == AFSOP_CACHEDIRS) {
+ afs_numfilesperdir = parm2;
+ afs_osi_Wakeup(&afs_initState);
+ } else if (parm == AFSOP_CACHEFILES) {
+ afs_numcachefiles = parm2;
+ afs_osi_Wakeup(&afs_initState);
} else if (parm == AFSOP_ROOTVOLUME) {
/* wait for basic init */
while (afs_initState < AFSOP_START_BKG)
***************
*** 815,821 ****
code = 0;
} else if (parm == AFSOP_CACHEFILE || parm == AFSOP_CACHEINFO
|| parm == AFSOP_VOLUMEINFO || parm == AFSOP_AFSLOG
! || parm == AFSOP_CELLINFO) {
char *tbuffer = osi_AllocSmallSpace(AFS_SMALLOCSIZ);
code = 0;
--- 854,860 ----
code = 0;
} else if (parm == AFSOP_CACHEFILE || parm == AFSOP_CACHEINFO
|| parm == AFSOP_VOLUMEINFO || parm == AFSOP_AFSLOG
! || parm == AFSOP_CELLINFO || parm == AFSOP_CACHEBASEDIR) {
char *tbuffer = osi_AllocSmallSpace(AFS_SMALLOCSIZ);
code = 0;
***************
*** 829,850 ****
tbuffer[AFS_SMALLOCSIZ - 1] = '\0'; /* null-terminate the name */
/* We have the cache dir copied in. Call the cache init routine */
#ifdef AFS_DARWIN80_ENV
! get_vfs_context();
#endif
! if (parm == AFSOP_CACHEFILE)
code = afs_InitCacheFile(tbuffer, 0);
! else if (parm == AFSOP_CACHEINFO)
code = afs_InitCacheInfo(tbuffer);
! else if (parm == AFSOP_VOLUMEINFO)
code = afs_InitVolumeInfo(tbuffer);
! else if (parm == AFSOP_CELLINFO)
code = afs_InitCellInfo(tbuffer);
#ifdef AFS_DARWIN80_ENV
! put_vfs_context();
#endif
}
osi_FreeSmallSpace(tbuffer);
} else if (parm == AFSOP_GO) {
/* the generic initialization calls come here. One parameter: should we do the
* set-time operation on this workstation */
if (afs_Go_Done)
--- 868,916 ----
tbuffer[AFS_SMALLOCSIZ - 1] = '\0'; /* null-terminate the name */
/* We have the cache dir copied in. Call the cache init routine */
#ifdef AFS_DARWIN80_ENV
! get_vfs_context();
#endif
! if (parm == AFSOP_CACHEBASEDIR) {
! strncpy(afs_cachebasedir, tbuffer, 1024);
! afs_cachebasedir[1023] = '\0';
! afs_osi_Wakeup(&afs_initState);
! } else if (parm == AFSOP_CACHEFILE) {
! wait_for_cachedefs();
code = afs_InitCacheFile(tbuffer, 0);
! } else if (parm == AFSOP_CACHEINFO) {
! wait_for_cachedefs();
code = afs_InitCacheInfo(tbuffer);
! } else if (parm == AFSOP_VOLUMEINFO) {
! wait_for_cachedefs();
code = afs_InitVolumeInfo(tbuffer);
! } else if (parm == AFSOP_CELLINFO) {
! wait_for_cachedefs();
code = afs_InitCellInfo(tbuffer);
+ }
#ifdef AFS_DARWIN80_ENV
! put_vfs_context();
#endif
}
osi_FreeSmallSpace(tbuffer);
} else if (parm == AFSOP_GO) {
+ #ifdef AFS_CACHE_VNODE_PATH
+ afs_int32 dummy;
+
+ wait_for_cachedefs();
+
+ #ifdef AFS_DARWIN80_ENV
+ get_vfs_context();
+ #endif
+ if ((afs_numcachefiles > 0) && (afs_numfilesperdir > 0) &&
+ (afs_cachebasedir[0] == '/')) {
+ for (dummy = 0; dummy < afs_numcachefiles; dummy++) {
+ code = afs_InitCacheFile(NULL, dummy);
+ }
+ }
+ #ifdef AFS_DARWIN80_ENV
+ put_vfs_context();
+ #endif
+ #endif
/* the generic initialization calls come here. One parameter: should we do the
* set-time operation on this workstation */
if (afs_Go_Done)
***************
*** 858,863 ****
--- 924,930 ----
#if (!defined(AFS_NONFSTRANS)) || defined(AFS_AIX_IAUTH_ENV)
afs_nfsclient_init();
#endif
+ afs_uuid_create(&afs_cb_interface.uuid);
printf("found %d non-empty cache files (%d%%).\n",
afs_stats_cmperf.cacheFilesReused,
(100 * afs_stats_cmperf.cacheFilesReused) /
***************
*** 866,871 ****
--- 933,940 ----
} else if (parm == AFSOP_ADVISEADDR) {
/* pass in the host address to the rx package */
int rxbind = 0;
+ int refresh = 0;
+
afs_int32 count = parm2;
afs_int32 *buffer =
afs_osi_Alloc(sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
***************
*** 875,880 ****
--- 944,957 ----
afs_osi_Alloc(sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
int i;
+ /* This is a refresh */
+ if (count & 0x40000000) {
+ count &= ~0x40000000;
+ /* Can't bind after we start. Fix? */
+ count &= ~0x80000000;
+ refresh = 1;
+ }
+
/* Bind, but only if there's only one address configured */
if ( count & 0x80000000) {
count &= ~0x80000000;
***************
*** 914,929 ****
afs_cb_interface.mtu[i] = (parm5 ? mtubuffer[i] : htonl(1500));
#endif
}
- afs_uuid_create(&afs_cb_interface.uuid);
rxi_setaddr(buffer[0]);
! if (rxbind)
! rx_bindhost = buffer[0];
! else
! rx_bindhost = htonl(INADDR_ANY);
afs_osi_Free(buffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
afs_osi_Free(maskbuffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
afs_osi_Free(mtubuffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
}
#ifdef AFS_SGI53_ENV
else if (parm == AFSOP_NFSSTATICADDR) {
--- 991,1012 ----
afs_cb_interface.mtu[i] = (parm5 ? mtubuffer[i] : htonl(1500));
#endif
}
rxi_setaddr(buffer[0]);
! if (!refresh) {
! if (rxbind)
! rx_bindhost = buffer[0];
! else
! rx_bindhost = htonl(INADDR_ANY);
! }
afs_osi_Free(buffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
afs_osi_Free(maskbuffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
afs_osi_Free(mtubuffer, sizeof(afs_int32) * AFS_MAX_INTERFACE_ADDR);
+
+ if (refresh) {
+ afs_CheckServers(1, NULL); /* check down servers */
+ afs_CheckServers(0, NULL); /* check down servers */
+ }
}
#ifdef AFS_SGI53_ENV
else if (parm == AFSOP_NFSSTATICADDR) {
***************
*** 1072,1080 ****
code = EINVAL;
out:
- #ifdef AFS_DARWIN80_ENV /* to balance the put in afs3_syscall() */
- get_vfs_context();
- #endif
AFS_GUNLOCK();
#ifdef AFS_LINUX20_ENV
return -code;
--- 1155,1160 ----
***************
*** 1658,1664 ****
}
#if defined(AFS_DARWIN80_ENV)
! put_vfs_context();
#endif
#ifdef AFS_LINUX20_ENV
code = -code;
--- 1738,1745 ----
}
#if defined(AFS_DARWIN80_ENV)
! if (uap->syscall != AFSCALL_CALL)
! put_vfs_context();
#endif
#ifdef AFS_LINUX20_ENV
code = -code;
Index: openafs/src/afs/afs_dcache.c
diff -c openafs/src/afs/afs_dcache.c:1.42.2.20 openafs/src/afs/afs_dcache.c:1.42.2.22
*** openafs/src/afs/afs_dcache.c:1.42.2.20 Thu Nov 9 19:16:29 2006
--- openafs/src/afs/afs_dcache.c Mon Aug 20 13:53:15 2007
***************
*** 14,20 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_dcache.c,v 1.42.2.20 2006/11/10 00:16:29 shadow Exp $");
#include "afs/sysincludes.h" /*Standard vendor system headers */
#include "afsincludes.h" /*AFS-based standard headers */
--- 14,20 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_dcache.c,v 1.42.2.22 2007/08/20 17:53:15 shadow Exp $");
#include "afs/sysincludes.h" /*Standard vendor system headers */
#include "afsincludes.h" /*AFS-based standard headers */
***************
*** 1201,1214 ****
}
index = afs_dcnextTbl[index];
}
- MReleaseWriteLock(&afs_xdcache);
if (index != NULLIDX) {
hset(afs_indexTimes[tdc->index], afs_indexCounter);
hadd32(afs_indexCounter, 1);
return tdc;
! } else
! return NULL;
!
} /*afs_FindDCache */
--- 1201,1214 ----
}
index = afs_dcnextTbl[index];
}
if (index != NULLIDX) {
hset(afs_indexTimes[tdc->index], afs_indexCounter);
hadd32(afs_indexCounter, 1);
+ MReleaseWriteLock(&afs_xdcache);
return tdc;
! }
! MReleaseWriteLock(&afs_xdcache);
! return NULL;
} /*afs_FindDCache */
***************
*** 2382,2398 ****
}
ReleaseWriteLock(&tdc->lock);
afs_PutDCache(tdc);
! ObtainWriteLock(&afs_xcbhash, 454);
! afs_DequeueCallback(avc);
! avc->states &= ~(CStatd | CUnique);
! ReleaseWriteLock(&afs_xcbhash);
! if (avc->fid.Fid.Vnode & 1 || (vType(avc) == VDIR))
! osi_dnlc_purgedp(avc);
! /*
! * Locks held:
! * avc->lock(W); assert(!setLocks || slowPass)
! */
! osi_Assert(!setLocks || slowPass);
tdc = NULL;
goto done;
}
--- 2382,2400 ----
}
ReleaseWriteLock(&tdc->lock);
afs_PutDCache(tdc);
! if (!afs_IsDynroot(avc)) {
! ObtainWriteLock(&afs_xcbhash, 454);
! afs_DequeueCallback(avc);
! avc->states &= ~(CStatd | CUnique);
! ReleaseWriteLock(&afs_xcbhash);
! if (avc->fid.Fid.Vnode & 1 || (vType(avc) == VDIR))
! osi_dnlc_purgedp(avc);
! /*
! * Locks held:
! * avc->lock(W); assert(!setLocks || slowPass)
! */
! osi_Assert(!setLocks || slowPass);
! }
tdc = NULL;
goto done;
}
Index: openafs/src/afs/afs_init.c
diff -c openafs/src/afs/afs_init.c:1.28.2.5 openafs/src/afs/afs_init.c:1.28.2.7
*** openafs/src/afs/afs_init.c:1.28.2.5 Wed Oct 5 01:58:27 2005
--- openafs/src/afs/afs_init.c Wed Oct 10 13:43:35 2007
***************
*** 17,23 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_init.c,v 1.28.2.5 2005/10/05 05:58:27 shadow Exp $");
#include "afs/stds.h"
#include "afs/sysincludes.h" /* Standard vendor system headers */
--- 17,23 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_init.c,v 1.28.2.7 2007/10/10 17:43:35 shadow Exp $");
#include "afs/stds.h"
#include "afs/sysincludes.h" /* Standard vendor system headers */
***************
*** 244,251 ****
--- 244,255 ----
ino_t inode;
int code;
+ #ifdef AFS_CACHE_VNODE_PATH
+ return afs_cellname_init(AFS_CACHE_CELLS_INODE, code);
+ #else
code = LookupInodeByPath(afile, &inode, NULL);
return afs_cellname_init(inode, code);
+ #endif
}
/*
***************
*** 286,291 ****
--- 290,297 ----
* it in the cache...
*/
code = LookupInodeByPath(afile, &volumeInode, &volumeVnode);
+ #elif defined(AFS_CACHE_VNODE_PATH)
+ volumeInode = AFS_CACHE_VOLUME_INODE;
#else
code = LookupInodeByPath(afile, &volumeInode, NULL);
#endif
***************
*** 416,426 ****
#if defined(AFS_SGI62_ENV) || defined(AFS_HAVE_VXFS) || defined(AFS_DARWIN_ENV)
afs_InitDualFSCacheOps(filevp);
#endif
! cacheInode = afs_vnodeToInumber(filevp);
! cacheDev.dev = afs_vnodeToDev(filevp);
#ifndef AFS_DARWIN80_ENV
afs_cacheVfsp = filevp->v_vfsp;
#endif
#endif /* AFS_LINUX20_ENV */
AFS_RELE(filevp);
#endif /* AFS_LINUX22_ENV */
--- 422,436 ----
#if defined(AFS_SGI62_ENV) || defined(AFS_HAVE_VXFS) || defined(AFS_DARWIN_ENV)
afs_InitDualFSCacheOps(filevp);
#endif
! #ifndef AFS_CACHE_VNODE_PATH
#ifndef AFS_DARWIN80_ENV
afs_cacheVfsp = filevp->v_vfsp;
#endif
+ cacheInode = afs_vnodeToInumber(filevp);
+ #else
+ cacheInode = AFS_CACHE_ITEMS_INODE;
+ #endif
+ cacheDev.dev = afs_vnodeToDev(filevp);
#endif /* AFS_LINUX20_ENV */
AFS_RELE(filevp);
#endif /* AFS_LINUX22_ENV */
Index: openafs/src/afs/afs_memcache.c
diff -c openafs/src/afs/afs_memcache.c:1.15.2.5 openafs/src/afs/afs_memcache.c:1.15.2.6
*** openafs/src/afs/afs_memcache.c:1.15.2.5 Wed Oct 5 01:58:27 2005
--- openafs/src/afs/afs_memcache.c Sat Jun 23 11:31:11 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_memcache.c,v 1.15.2.5 2005/10/05 05:58:27 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#ifndef AFS_LINUX22_ENV
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_memcache.c,v 1.15.2.6 2007/06/23 15:31:11 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#ifndef AFS_LINUX22_ENV
***************
*** 247,252 ****
--- 247,259 ----
char *oldData = mceP->data;
mceP->data = afs_osi_Alloc(size + offset);
+ if (mceP->data == NULL) { /* no available memory */
+ mceP->data = oldData; /* revert back change that was made */
+ MReleaseWriteLock(&mceP->afs_memLock);
+ afs_warn("afs: afs_MemWriteBlk mem alloc failure (%d bytes)\n",
+ size + offset);
+ return -ENOMEM;
+ }
/* may overlap, but this is OK */
AFS_GUNLOCK();
***************
*** 285,290 ****
--- 292,304 ----
char *oldData = mceP->data;
mceP->data = afs_osi_Alloc(AFS_UIO_RESID(uioP) + AFS_UIO_OFFSET(uioP));
+ if (mceP->data == NULL) { /* no available memory */
+ mceP->data = oldData; /* revert back change that was made */
+ MReleaseWriteLock(&mceP->afs_memLock);
+ afs_warn("afs: afs_MemWriteBlk mem alloc failure (%d bytes)\n",
+ AFS_UIO_RESID(uioP) + AFS_UIO_OFFSET(uioP));
+ return -ENOMEM;
+ }
AFS_GUNLOCK();
memcpy(mceP->data, oldData, mceP->size);
***************
*** 314,322 ****
MObtainWriteLock(&mceP->afs_memLock, 313);
/* old directory entry; g.c. */
if (size == 0 && mceP->dataSize > memCacheBlkSize) {
! afs_osi_Free(mceP->data, mceP->dataSize);
mceP->data = afs_osi_Alloc(memCacheBlkSize);
! mceP->dataSize = memCacheBlkSize;
}
if (size < mceP->size)
--- 328,344 ----
MObtainWriteLock(&mceP->afs_memLock, 313);
/* old directory entry; g.c. */
if (size == 0 && mceP->dataSize > memCacheBlkSize) {
! char *oldData = mceP->data;
mceP->data = afs_osi_Alloc(memCacheBlkSize);
! if (mceP->data == NULL) { /* no available memory */
! mceP->data = oldData;
! MReleaseWriteLock(&mceP->afs_memLock);
! afs_warn("afs: afs_MemWriteBlk mem alloc failure (%d bytes)\n",
! memCacheBlkSize);
! } else {
! afs_osi_Free(oldData, mceP->dataSize);
! mceP->dataSize = memCacheBlkSize;
! }
}
if (size < mceP->size)
Index: openafs/src/afs/afs_nfsclnt.c
diff -c openafs/src/afs/afs_nfsclnt.c:1.12.2.2 openafs/src/afs/afs_nfsclnt.c:1.12.2.3
*** openafs/src/afs/afs_nfsclnt.c:1.12.2.2 Wed Dec 20 15:09:06 2006
--- openafs/src/afs/afs_nfsclnt.c Tue Mar 20 15:24:11 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_nfsclnt.c,v 1.12.2.2 2006/12/20 20:09:06 shadow Exp $");
#if !defined(AFS_NONFSTRANS) || defined(AFS_AIX_IAUTH_ENV)
#include "afs/sysincludes.h" /* Standard vendor system headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_nfsclnt.c,v 1.12.2.3 2007/03/20 19:24:11 shadow Exp $");
#if !defined(AFS_NONFSTRANS) || defined(AFS_AIX_IAUTH_ENV)
#include "afs/sysincludes.h" /* Standard vendor system headers */
***************
*** 314,324 ****
#endif
AFS_STATCNT(afs_nfsclient_sysname);
if (inname) {
- if (np->sysname) {
for(count=0; count < np->sysnamecount;++count) {
afs_osi_Free(np->sysname[count], MAXSYSNAME);
}
- }
for(count=0; count < *num;++count) {
np->sysname[count]= afs_osi_Alloc(MAXSYSNAME);
}
--- 314,323 ----
#endif
AFS_STATCNT(afs_nfsclient_sysname);
if (inname) {
for(count=0; count < np->sysnamecount;++count) {
afs_osi_Free(np->sysname[count], MAXSYSNAME);
+ np->sysname[count] = NULL;
}
for(count=0; count < *num;++count) {
np->sysname[count]= afs_osi_Alloc(MAXSYSNAME);
}
***************
*** 329,336 ****
cp += t+1;
}
np->sysnamecount = *num;
- } else if (!np->sysname) {
- return ENODEV; /* XXX */
}
*outname = np->sysname;
*num = np->sysnamecount;
--- 328,333 ----
***************
*** 346,351 ****
--- 343,349 ----
{
register struct nfsclientpag *np, **tnp, *nnp;
register afs_int32 i, delflag;
+ int count;
#if defined(AFS_SGIMP_ENV)
osi_Assert(ISAFS_GLOCK());
***************
*** 361,368 ****
if ((pag == -1) || (!pag && delflag)
|| (pag && (np->refCount == 0) && (np->pag == pag))) {
*tnp = np->next;
! if (np->sysname)
! afs_osi_Free(np->sysname, MAXSYSNAME);
afs_osi_Free(np, sizeof(struct nfsclientpag));
} else {
tnp = &np->next;
--- 359,367 ----
if ((pag == -1) || (!pag && delflag)
|| (pag && (np->refCount == 0) && (np->pag == pag))) {
*tnp = np->next;
! for(count=0; count < np->sysnamecount;++count) {
! afs_osi_Free(np->sysname[count], MAXSYSNAME);
! }
afs_osi_Free(np, sizeof(struct nfsclientpag));
} else {
tnp = &np->next;
Index: openafs/src/afs/afs_osi.c
diff -c openafs/src/afs/afs_osi.c:1.48.2.11 openafs/src/afs/afs_osi.c:1.48.2.12
*** openafs/src/afs/afs_osi.c:1.48.2.11 Thu Feb 8 20:30:32 2007
--- openafs/src/afs/afs_osi.c Tue Apr 3 14:57:06 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_osi.c,v 1.48.2.11 2007/02/09 01:30:32 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_osi.c,v 1.48.2.12 2007/04/03 18:57:06 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 807,812 ****
--- 807,815 ----
#endif
#if defined(AFS_LINUX22_ENV)
+ #ifdef EXPORTED_TASKLIST_LOCK
+ extern rwlock_t tasklist_lock __attribute__((weak));
+ #endif
void
afs_osi_TraverseProcTable()
{
***************
*** 814,821 ****
struct task_struct *p;
#ifdef EXPORTED_TASKLIST_LOCK
- extern rwlock_t tasklist_lock __attribute__((weak));
-
if (&tasklist_lock)
read_lock(&tasklist_lock);
#endif
--- 817,822 ----
Index: openafs/src/afs/afs_pioctl.c
diff -c openafs/src/afs/afs_pioctl.c:1.81.2.25 openafs/src/afs/afs_pioctl.c:1.81.2.28
*** openafs/src/afs/afs_pioctl.c:1.81.2.25 Thu Mar 2 01:44:05 2006
--- openafs/src/afs/afs_pioctl.c Tue Aug 21 22:15:33 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_pioctl.c,v 1.81.2.25 2006/03/02 06:44:05 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#ifdef AFS_OBSD_ENV
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_pioctl.c,v 1.81.2.28 2007/08/22 02:15:33 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#ifdef AFS_OBSD_ENV
***************
*** 90,96 ****
DECL_PIOCTL(PPrefetchFromTape);
DECL_PIOCTL(PResidencyCmd);
DECL_PIOCTL(PCallBackAddr);
!
/*
* A macro that says whether we're going to need HandleClientContext().
* This is currently used only by the nfs translator.
--- 90,96 ----
DECL_PIOCTL(PPrefetchFromTape);
DECL_PIOCTL(PResidencyCmd);
DECL_PIOCTL(PCallBackAddr);
! DECL_PIOCTL(PNewUuid);
/*
* A macro that says whether we're going to need HandleClientContext().
* This is currently used only by the nfs translator.
***************
*** 192,197 ****
--- 192,203 ----
PNewAlias, /* 1 -- create new cell alias */
PListAliases, /* 2 -- list cell aliases */
PCallBackAddr, /* 3 -- request addr for callback rxcon */
+ PBogus, /* 0 */
+ PBogus, /* 0 */
+ PBogus, /* 0 */
+ PBogus, /* 0 */
+ PBogus, /* 0 */
+ PNewUuid, /* 9 -- generate new uuid */
};
#define PSetClientContext 99 /* Special pioctl to setup caller's creds */
***************
*** 3354,3359 ****
--- 3360,3366 ----
struct afs_exporter *exporter, *outexporter;
struct AFS_UCRED *newcred;
struct unixuser *au;
+ afs_uint32 comp = *com & 0xff00;
#if defined(AFS_SGIMP_ENV)
osi_Assert(ISAFS_GLOCK());
***************
*** 3479,3484 ****
--- 3486,3493 ----
} else if (!code) {
EXP_RELE(outexporter);
}
+ if (!code)
+ *com = (*com) | comp;
return code;
}
#endif /* AFS_NEED_CLIENTCONTEXT */
***************
*** 3830,3835 ****
--- 3839,3859 ----
return code;
}
+ DECL_PIOCTL(PNewUuid)
+ {
+ /*AFS_STATCNT(PNewUuid); */
+ if (!afs_resourceinit_flag) /* afs deamons havn't started yet */
+ return EIO; /* Inappropriate ioctl for device */
+
+ if (!afs_osi_suser(acred))
+ return EACCES;
+
+ ObtainWriteLock(&afs_xinterface, 555);
+ afs_uuid_create(&afs_cb_interface.uuid);
+ ReleaseWriteLock(&afs_xinterface);
+ ForceAllNewConnections();
+ }
+
DECL_PIOCTL(PCallBackAddr)
{
#ifndef UKERNEL
Index: openafs/src/afs/afs_prototypes.h
diff -c openafs/src/afs/afs_prototypes.h:1.53.2.19 openafs/src/afs/afs_prototypes.h:1.53.2.20
*** openafs/src/afs/afs_prototypes.h:1.53.2.19 Mon Jan 15 15:51:57 2007
--- openafs/src/afs/afs_prototypes.h Wed Jun 27 12:32:12 2007
***************
*** 692,697 ****
--- 692,698 ----
afs_int32 acell, u_short aport,
afs_int32 locktype, afsUUID * uuidp,
afs_int32 addr_uniquifier);
+ extern void ForceAllNewConnections(void);
extern void afs_MarkServerUpOrDown(struct srvAddr *sa, int a_isDown);
extern void afs_ServerDown(struct srvAddr *sa);
extern void afs_CountServers(void);
Index: openafs/src/afs/afs_server.c
diff -c openafs/src/afs/afs_server.c:1.33.2.8 openafs/src/afs/afs_server.c:1.33.2.10
*** openafs/src/afs/afs_server.c:1.33.2.8 Thu Nov 9 19:16:29 2006
--- openafs/src/afs/afs_server.c Thu Oct 4 22:54:08 2007
***************
*** 33,39 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_server.c,v 1.33.2.8 2006/11/10 00:16:29 shadow Exp $");
#include "afs/stds.h"
#include "afs/sysincludes.h" /* Standard vendor system headers */
--- 33,39 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/afs_server.c,v 1.33.2.10 2007/10/05 02:54:08 shadow Exp $");
#include "afs/stds.h"
#include "afs/sysincludes.h" /* Standard vendor system headers */
***************
*** 488,493 ****
--- 488,529 ----
} /*afs_CountServers */
+ void
+ ForceAllNewConnections()
+ {
+ int srvAddrCount;
+ struct srvAddr **addrs;
+ struct srvAddr *sa;
+ afs_int32 i, j;
+
+ ObtainReadLock(&afs_xserver); /* Necessary? */
+ ObtainReadLock(&afs_xsrvAddr);
+
+ srvAddrCount = 0;
+ for (i = 0; i < NSERVERS; i++) {
+ for (sa = afs_srvAddrs[i]; sa; sa = sa->next_bkt) {
+ srvAddrCount++;
+ }
+ }
+
+ addrs = afs_osi_Alloc(srvAddrCount * sizeof(*addrs));
+ j = 0;
+ for (i = 0; i < NSERVERS; i++) {
+ for (sa = afs_srvAddrs[i]; sa; sa = sa->next_bkt) {
+ if (j >= srvAddrCount)
+ break;
+ addrs[j++] = sa;
+ }
+ }
+
+ ReleaseReadLock(&afs_xsrvAddr);
+ ReleaseReadLock(&afs_xserver);
+ for (i = 0; i < j; i++) {
+ sa = addrs[i];
+ ForceNewConnections(sa);
+ }
+ }
+
/* check down servers (if adown), or running servers (if !adown) */
void
afs_CheckServers(int adown, struct cell *acellp)
***************
*** 1237,1259 ****
#else /* AFS_USERSPACE_IP_ADDR */
#if defined(AFS_SUN5_ENV)
#ifdef AFS_SUN510_ENV
! ill_walk_context_t ctx;
#else
extern struct ill_s *ill_g_headp;
long *addr = (long *)ill_g_headp;
- #endif
ill_t *ill;
ipif_t *ipif;
int subnet, subnetmask, net, netmask;
if (sa)
sa->sa_iprank = 0;
#ifdef AFS_SUN510_ENV
! for (ill = ILL_START_WALK_ALL(&ctx) ; ill ; ill = ill_next(&ctx, ill)) {
#else
for (ill = (struct ill_s *)*addr /*ill_g_headp */ ; ill;
ill = ill->ill_next) {
- #endif
#ifdef AFS_SUN58_ENV
/* Make sure this is an IPv4 ILL */
if (ill->ill_isv6)
--- 1273,1346 ----
#else /* AFS_USERSPACE_IP_ADDR */
#if defined(AFS_SUN5_ENV)
#ifdef AFS_SUN510_ENV
! int i = 0;
#else
extern struct ill_s *ill_g_headp;
long *addr = (long *)ill_g_headp;
ill_t *ill;
ipif_t *ipif;
+ #endif
int subnet, subnetmask, net, netmask;
if (sa)
sa->sa_iprank = 0;
#ifdef AFS_SUN510_ENV
! rw_enter(&afsifinfo_lock, RW_READER);
!
! for (i = 0; (afsifinfo[i].ipaddr != NULL) && (i < ADDRSPERSITE); i++) {
!
! if (IN_CLASSA(afsifinfo[i].ipaddr)) {
! netmask = IN_CLASSA_NET;
! } else if (IN_CLASSB(afsifinfo[i].ipaddr)) {
! netmask = IN_CLASSB_NET;
! } else if (IN_CLASSC(afsifinfo[i].ipaddr)) {
! netmask = IN_CLASSC_NET;
! } else {
! netmask = 0;
! }
! net = afsifinfo[i].ipaddr & netmask;
!
! #ifdef notdef
! if (!s) {
! if (afsifinfo[i].ipaddr != 0x7f000001) { /* ignore loopback */
! *cnt += 1;
! if (*cnt > 16)
! return;
! *addrp++ = afsifinfo[i].ipaddr;
! }
! } else
! #endif /* notdef */
! {
! /* XXXXXX Do the individual ip ranking below XXXXX */
! if ((sa->sa_ip & netmask) == net) {
! if ((sa->sa_ip & subnetmask) == subnet) {
! if (afsifinfo[i].ipaddr == sa->sa_ip) { /* ie, ME! */
! sa->sa_iprank = TOPR;
! } else {
! sa->sa_iprank = HI + afsifinfo[i].metric; /* case #2 */
! }
! } else {
! sa->sa_iprank = MED + afsifinfo[i].metric; /* case #3 */
! }
! } else {
! sa->sa_iprank = LO + afsifinfo[i].metric; /* case #4 */
! }
! /* check for case #5 -- point-to-point link */
! if ((afsifinfo[i].flags & IFF_POINTOPOINT)
! && (afsifinfo[i].dstaddr == sa->sa_ip)) {
!
! if (afsifinfo[i].metric >= (MAXDEFRANK - MED) / PPWEIGHT)
! sa->sa_iprank = MAXDEFRANK;
! else
! sa->sa_iprank = MED + (PPWEIGHT << afsifinfo[i].metric);
! }
! }
! }
!
! rw_exit(&afsifinfo_lock);
#else
for (ill = (struct ill_s *)*addr /*ill_g_headp */ ; ill;
ill = ill->ill_next) {
#ifdef AFS_SUN58_ENV
/* Make sure this is an IPv4 ILL */
if (ill->ill_isv6)
***************
*** 1313,1318 ****
--- 1400,1406 ----
}
}
}
+ #endif /* AFS_SUN510_ENV */
#else
#ifndef USEIFADDR
struct ifnet *ifn = NULL;
Index: openafs/src/afs/AIX/osi_file.c
diff -c openafs/src/afs/AIX/osi_file.c:1.9.2.1 openafs/src/afs/AIX/osi_file.c:1.9.2.2
*** openafs/src/afs/AIX/osi_file.c:1.9.2.1 Thu Nov 9 18:26:25 2006
--- openafs/src/afs/AIX/osi_file.c Wed Aug 15 23:54:26 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_file.c,v 1.9.2.1 2006/11/09 23:26:25 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_file.c,v 1.9.2.2 2007/08/16 03:54:26 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 30,36 ****
{
struct inode *ip;
register struct osi_file *afile = NULL;
- extern struct vfs *rootvfs;
struct vnode *vp = NULL;
extern int cacheDiskType;
afs_int32 code = 0;
--- 30,35 ----
***************
*** 48,54 ****
afile = (struct osi_file *)osi_AllocSmallSpace(sizeof(struct osi_file));
setuerror(0);
AFS_GUNLOCK();
! ip = (struct inode *)igetinode((dev_t) cacheDev.dev, rootvfs,
(ino_t) ainode, &vp, &dummy);
AFS_GLOCK();
if (getuerror()) {
--- 47,53 ----
afile = (struct osi_file *)osi_AllocSmallSpace(sizeof(struct osi_file));
setuerror(0);
AFS_GUNLOCK();
! ip = (struct inode *)igetinode((dev_t) cacheDev.dev, afs_cacheVfsp,
(ino_t) ainode, &vp, &dummy);
AFS_GLOCK();
if (getuerror()) {
Index: openafs/src/afs/AIX/osi_inode.c
diff -c openafs/src/afs/AIX/osi_inode.c:1.8.2.2 openafs/src/afs/AIX/osi_inode.c:1.8.2.3
*** openafs/src/afs/AIX/osi_inode.c:1.8.2.2 Sat Oct 15 10:24:25 2005
--- openafs/src/afs/AIX/osi_inode.c Wed Aug 15 23:54:26 2007
***************
*** 17,23 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_inode.c,v 1.8.2.2 2005/10/15 14:24:25 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 17,23 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_inode.c,v 1.8.2.3 2007/08/16 03:54:26 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 262,268 ****
struct inode *ip, *newip, *pip;
register int err, rval1, rc = 0;
struct vnode *vp = NULL;
- extern struct vfs *rootvfs;
register struct vfs *vfsp;
struct vfs *nvfsp = NULL;
char error;
--- 262,267 ----
Index: openafs/src/afs/AIX/osi_sleep.c
diff -c openafs/src/afs/AIX/osi_sleep.c:1.10 openafs/src/afs/AIX/osi_sleep.c:1.10.2.1
*** openafs/src/afs/AIX/osi_sleep.c:1.10 Tue Jul 15 19:14:17 2003
--- openafs/src/afs/AIX/osi_sleep.c Mon Jun 25 16:25:31 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_sleep.c,v 1.10 2003/07/15 23:14:17 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/AIX/osi_sleep.c,v 1.10.2.1 2007/06/25 20:25:31 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 26,32 ****
--- 26,35 ----
static void
AfsWaitHack(struct trb *trb)
{
+ #if 0
+ /* this gets called at interrupt context; let's not tempt fate... */
AFS_STATCNT(WaitHack);
+ #endif
e_clear_wait(trb->func_data, THREAD_TIMED_OUT);
}
***************
*** 121,127 ****
evp = evp->next;
}
if (!newp) {
! newp = (afs_event_t *) osi_AllocSmallSpace(sizeof(afs_event_t));
afs_evhashcnt++;
newp->next = afs_evhasht[hashcode];
afs_evhasht[hashcode] = newp;
--- 124,130 ----
evp = evp->next;
}
if (!newp) {
! newp = (afs_event_t *) xmalloc(sizeof(afs_event_t), 5, pinned_heap);
afs_evhashcnt++;
newp->next = afs_evhasht[hashcode];
afs_evhasht[hashcode] = newp;
Index: openafs/src/afs/DARWIN/osi_file.c
diff -c openafs/src/afs/DARWIN/osi_file.c:1.8.2.6 openafs/src/afs/DARWIN/osi_file.c:1.8.2.7
*** openafs/src/afs/DARWIN/osi_file.c:1.8.2.6 Thu Nov 9 18:26:25 2006
--- openafs/src/afs/DARWIN/osi_file.c Wed Oct 10 12:57:55 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/DARWIN/osi_file.c,v 1.8.2.6 2006/11/09 23:26:25 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/DARWIN/osi_file.c,v 1.8.2.7 2007/10/10 16:57:55 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 141,146 ****
--- 141,149 ----
extern int cacheDiskType;
afs_int32 code = 0;
int dummy;
+ char fname[1024];
+ struct osi_stat tstat;
+
AFS_STATCNT(osi_UFSOpen);
if (cacheDiskType != AFS_FCACHE_TYPE_UFS) {
osi_Panic("UFSOpen called for non-UFS cache\n");
***************
*** 154,159 ****
--- 157,184 ----
}
afile = (struct osi_file *)osi_AllocSmallSpace(sizeof(struct osi_file));
AFS_GUNLOCK();
+ #ifdef AFS_CACHE_VNODE_PATH
+ if (ainode < 0) {
+ switch (ainode) {
+ case AFS_CACHE_CELLS_INODE:
+ snprintf(fname, 1024, "%s/%s", afs_cachebasedir, "CellItems");
+ break;
+ case AFS_CACHE_ITEMS_INODE:
+ snprintf(fname, 1024, "%s/%s", afs_cachebasedir, "CacheItems");
+ break;
+ case AFS_CACHE_VOLUME_INODE:
+ snprintf(fname, 1024, "%s/%s", afs_cachebasedir, "VolumeItems");
+ break;
+ default:
+ osi_Panic("Invalid negative inode");
+ }
+ } else {
+ dummy = ainode / afs_numfilesperdir;
+ snprintf(fname, 1024, "%s/D%d/V%d", afs_cachebasedir, dummy, ainode);
+ }
+
+ code = vnode_open(fname, O_RDWR, 0, 0, &vp, afs_osi_ctxtp);
+ #else
#ifndef AFS_DARWIN80_ENV
if (afs_CacheFSType == AFS_APPL_HFS_CACHE)
code = igetinode(afs_cacheVfsp, (dev_t) cacheDev.dev, &ainode, &vp, &va, &dummy); /* XXX hfs is broken */
***************
*** 166,181 ****
else
panic("osi_UFSOpen called before cacheops initialized\n");
#endif
AFS_GLOCK();
if (code) {
osi_FreeSmallSpace(afile);
osi_Panic("UFSOpen: igetinode failed");
}
afile->vnode = vp;
- afile->size = va.va_size;
afile->offset = 0;
afile->proc = (int (*)())0;
afile->inum = ainode; /* for hint validity checking */
return (void *)afile;
}
--- 191,212 ----
else
panic("osi_UFSOpen called before cacheops initialized\n");
#endif
+ #endif
AFS_GLOCK();
if (code) {
osi_FreeSmallSpace(afile);
osi_Panic("UFSOpen: igetinode failed");
}
afile->vnode = vp;
afile->offset = 0;
afile->proc = (int (*)())0;
afile->inum = ainode; /* for hint validity checking */
+ #ifndef AFS_CACHE_VNODE_PATH
+ afile->size = va.va_size;
+ #else
+ code = afs_osi_Stat(afile, &tstat);
+ afile->size = tstat.size;
+ #endif
return (void *)afile;
}
Index: openafs/src/afs/DARWIN/osi_vnodeops.c
diff -c openafs/src/afs/DARWIN/osi_vnodeops.c:1.18.2.21 openafs/src/afs/DARWIN/osi_vnodeops.c:1.18.2.23
*** openafs/src/afs/DARWIN/osi_vnodeops.c:1.18.2.21 Wed Feb 14 19:29:51 2007
--- openafs/src/afs/DARWIN/osi_vnodeops.c Sat Jul 28 10:35:06 2007
***************
*** 5,11 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/afs/DARWIN/osi_vnodeops.c,v 1.18.2.21 2007/02/15 00:29:51 shadow Exp $");
#include /* Standard vendor system headers */
#include /* Afs-based standard headers */
--- 5,11 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/afs/DARWIN/osi_vnodeops.c,v 1.18.2.23 2007/07/28 14:35:06 shadow Exp $");
#include /* Standard vendor system headers */
#include /* Afs-based standard headers */
***************
*** 1194,1201 ****
cache_purge(vp);
if (!error) {
#ifdef AFS_DARWIN80_ENV
! ubc_setsize(vp, (off_t)0);
! vnode_recycle(vp);
#else
/* necessary so we don't deadlock ourselves in vclean */
VOP_UNLOCK(vp, 0, cnp->cn_proc);
--- 1194,1205 ----
cache_purge(vp);
if (!error) {
#ifdef AFS_DARWIN80_ENV
! struct vcache *tvc = VTOAFS(vp);
!
! if (!(tvc->states & CUnlinked)) {
! ubc_setsize(vp, (off_t)0);
! vnode_recycle(vp);
! }
#else
/* necessary so we don't deadlock ourselves in vclean */
VOP_UNLOCK(vp, 0, cnp->cn_proc);
***************
*** 1626,1634 ****
vprint("afs_vop_inactive(): pushing active", vp);
#endif
if (tvc) {
! AFS_GLOCK();
! afs_InactiveVCache(tvc, 0); /* decrs ref counts */
! AFS_GUNLOCK();
}
#ifndef AFS_DARWIN80_ENV
VOP_UNLOCK(vp, 0, ap->a_p);
--- 1630,1647 ----
vprint("afs_vop_inactive(): pushing active", vp);
#endif
if (tvc) {
! #ifdef AFS_DARWIN80_ENV
! int unlinked = tvc->states & CUnlinked;
! #endif
! AFS_GLOCK();
! afs_InactiveVCache(tvc, 0); /* decrs ref counts */
! AFS_GUNLOCK();
! #ifdef AFS_DARWIN80_ENV
! if (unlinked) {
! vnode_recycle(vp);
! cache_purge(vp);
! }
! #endif
}
#ifndef AFS_DARWIN80_ENV
VOP_UNLOCK(vp, 0, ap->a_p);
***************
*** 2083,2093 ****
par.vnfs_markroot = 1;
error = vnode_create(VNCREATE_FLAVOR, VCREATESIZE, &par, &nvp);
if (!error) {
! vnode_addfsref(nvp);
! avc->v = nvp;
! avc->states &=~ CDeadVnode;
! vnode_clearfsnode(ovp);
! vnode_removefsref(ovp);
}
AFS_GLOCK();
ReleaseWriteLock(&avc->lock);
--- 2096,2108 ----
par.vnfs_markroot = 1;
error = vnode_create(VNCREATE_FLAVOR, VCREATESIZE, &par, &nvp);
if (!error) {
! vnode_addfsref(nvp);
! avc->v = nvp;
! avc->states &=~ CDeadVnode;
! if (!(avc->states & CVInit)) {
! vnode_clearfsnode(ovp);
! vnode_removefsref(ovp);
! }
}
AFS_GLOCK();
ReleaseWriteLock(&avc->lock);
Index: openafs/src/afs/LINUX/osi_alloc.c
diff -c openafs/src/afs/LINUX/osi_alloc.c:1.22.2.1 openafs/src/afs/LINUX/osi_alloc.c:1.22.2.2
*** openafs/src/afs/LINUX/osi_alloc.c:1.22.2.1 Tue Dec 7 01:12:12 2004
--- openafs/src/afs/LINUX/osi_alloc.c Wed Apr 18 14:04:10 2007
***************
*** 15,21 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_alloc.c,v 1.22.2.1 2004/12/07 06:12:12 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
--- 15,21 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_alloc.c,v 1.22.2.2 2007/04/18 18:04:10 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
***************
*** 98,104 ****
--- 98,109 ----
if (new) /* piggy back alloc type */
new = (void *)(KM_TYPE | (unsigned long)new);
} else {
+ osi_Assert(drop_glock || !haveGlock);
+ if (drop_glock && haveGlock)
+ AFS_GUNLOCK();
new = (void *)vmalloc(asize);
+ if (drop_glock && haveGlock)
+ AFS_GLOCK();
if (new) /* piggy back alloc type */
new = (void *)(VM_TYPE | (unsigned long)new);
}
Index: openafs/src/afs/LINUX/osi_groups.c
diff -c openafs/src/afs/LINUX/osi_groups.c:1.25.2.8 openafs/src/afs/LINUX/osi_groups.c:1.25.2.10
*** openafs/src/afs/LINUX/osi_groups.c:1.25.2.8 Mon Jan 15 10:52:46 2007
--- openafs/src/afs/LINUX/osi_groups.c Tue Mar 20 14:48:52 2007
***************
*** 20,26 ****
#endif
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_groups.c,v 1.25.2.8 2007/01/15 15:52:46 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
--- 20,26 ----
#endif
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_groups.c,v 1.25.2.10 2007/03/20 18:48:52 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
***************
*** 594,606 ****
--- 594,611 ----
{
afs_uint32 pag = key->payload.value;
struct unixuser *pu;
+ int locked = ISAFS_GLOCK();
+ if (!locked)
+ AFS_GLOCK();
pu = afs_FindUser(pag, -1, READ_LOCK);
if (pu) {
pu->ct.EndTimestamp = 0;
pu->tokenTime = 0;
afs_PutUser(pu, READ_LOCK);
}
+ if (!locked)
+ AFS_GUNLOCK();
}
struct key_type key_type_afs_pag =
***************
*** 612,624 ****
.destroy = afs_pag_destroy,
};
void osi_keyring_init(void)
{
struct task_struct *p;
!
p = find_task_by_pid(1);
if (p && p->user->session_keyring)
__key_type_keyring = p->user->session_keyring->type;
register_key_type(&key_type_afs_pag);
}
--- 617,652 ----
.destroy = afs_pag_destroy,
};
+ #ifdef EXPORTED_TASKLIST_LOCK
+ extern rwlock_t tasklist_lock __attribute__((weak));
+ #endif
+
void osi_keyring_init(void)
{
struct task_struct *p;
! #ifdef EXPORTED_TASKLIST_LOCK
! if (&tasklist_lock)
! read_lock(&tasklist_lock);
! #endif
! #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16)
! #ifdef EXPORTED_TASKLIST_LOCK
! else
! #endif
! rcu_read_lock();
! #endif
p = find_task_by_pid(1);
if (p && p->user->session_keyring)
__key_type_keyring = p->user->session_keyring->type;
+ #ifdef EXPORTED_TASKLIST_LOCK
+ if (&tasklist_lock)
+ read_unlock(&tasklist_lock);
+ #endif
+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16)
+ #ifdef EXPORTED_TASKLIST_LOCK
+ else
+ #endif
+ rcu_read_unlock();
+ #endif
register_key_type(&key_type_afs_pag);
}
Index: openafs/src/afs/LINUX/osi_module.c
diff -c openafs/src/afs/LINUX/osi_module.c:1.52.2.26 openafs/src/afs/LINUX/osi_module.c:1.52.2.28
*** openafs/src/afs/LINUX/osi_module.c:1.52.2.26 Thu Feb 8 20:30:33 2007
--- openafs/src/afs/LINUX/osi_module.c Tue Aug 21 22:19:28 2007
***************
*** 15,21 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_module.c,v 1.52.2.26 2007/02/09 01:30:33 shadow Exp $");
#include /* early to avoid printf->printk mapping */
#include "afs/sysincludes.h"
--- 15,21 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_module.c,v 1.52.2.28 2007/08/22 02:19:28 shadow Exp $");
#include /* early to avoid printf->printk mapping */
#include "afs/sysincludes.h"
***************
*** 370,378 ****
if (err)
return err;
err = afs_init_inodecache();
! if (err)
return err;
! register_filesystem(&afs_fs_type);
osi_sysctl_init();
#ifdef LINUX_KEYRING_SUPPORT
osi_keyring_init();
--- 370,390 ----
if (err)
return err;
err = afs_init_inodecache();
! if (err) {
! #ifndef LINUX_KEYRING_SUPPORT
! osi_syscall_clean();
! #endif
! return err;
! }
! err = register_filesystem(&afs_fs_type);
! if (err) {
! afs_destroy_inodecache();
! #ifndef LINUX_KEYRING_SUPPORT
! osi_syscall_clean();
! #endif
return err;
! }
!
osi_sysctl_init();
#ifdef LINUX_KEYRING_SUPPORT
osi_keyring_init();
***************
*** 392,400 ****
--- 404,416 ----
cleanup_module(void)
#endif
{
+ #ifdef LINUX_KEYRING_SUPPORT
osi_keyring_shutdown();
+ #endif
osi_sysctl_clean();
+ #ifndef LINUX_KEYRING_SUPPORT
osi_syscall_clean();
+ #endif
unregister_filesystem(&afs_fs_type);
afs_destroy_inodecache();
Index: openafs/src/afs/LINUX/osi_probe.c
diff -c openafs/src/afs/LINUX/osi_probe.c:1.1.2.20 openafs/src/afs/LINUX/osi_probe.c:1.1.2.24
*** openafs/src/afs/LINUX/osi_probe.c:1.1.2.20 Tue Feb 13 17:54:20 2007
--- openafs/src/afs/LINUX/osi_probe.c Tue Aug 21 17:31:59 2007
***************
*** 59,64 ****
--- 59,65 ----
#include "afsincludes.h"
#endif
#include
+ #include
#ifdef CONFIG_H_EXISTS
#include
#endif
***************
*** 128,134 ****
/* If this is set, we are more careful about avoiding duplicate matches */
static int probe_carefully = 1;
! #ifdef module_param
module_param(probe_carefully, int, 0);
#else
MODULE_PARM(probe_carefully, "i");
--- 129,135 ----
/* If this is set, we are more careful about avoiding duplicate matches */
static int probe_carefully = 1;
! #if defined(module_param) && LINUX_VERSION_CODE > KERNEL_VERSION(2,6,9)
module_param(probe_carefully, int, 0);
#else
MODULE_PARM(probe_carefully, "i");
***************
*** 153,161 ****
* 0x0010 - detail - check_harder
* 0x0020 - detail - check_harder/zapped
* 0x0040 - automatically ignore setgroups and afs_syscall
*/
static int probe_debug = 0x41;
! #ifdef module_param
module_param(probe_debug, int, 0);
#else
MODULE_PARM(probe_debug, "i");
--- 154,163 ----
* 0x0010 - detail - check_harder
* 0x0020 - detail - check_harder/zapped
* 0x0040 - automatically ignore setgroups and afs_syscall
+ * 0x0080 - detail - check_table_readable
*/
static int probe_debug = 0x41;
! #if defined(module_param) && LINUX_VERSION_CODE > KERNEL_VERSION(2,6,9)
module_param(probe_debug, int, 0);
#else
MODULE_PARM(probe_debug, "i");
***************
*** 171,177 ****
MODULE_PARM_DESC(probe_debug_addr, "Debug range starting locations");
static unsigned long probe_debug_range = 0;
! #ifdef module_param
module_param(probe_debug_range, long, 0);
#else
MODULE_PARM(probe_debug_range, "l");
--- 173,179 ----
MODULE_PARM_DESC(probe_debug_addr, "Debug range starting locations");
static unsigned long probe_debug_range = 0;
! #if defined(module_param) && LINUX_VERSION_CODE > KERNEL_VERSION(2,6,9)
module_param(probe_debug_range, long, 0);
#else
MODULE_PARM(probe_debug_range, "l");
***************
*** 179,185 ****
MODULE_PARM_DESC(probe_debug_range, "Debug range length");
static unsigned long probe_debug_tag = 0;
! #ifdef module_param
module_param(probe_debug_tag, long, 0);
#else
MODULE_PARM(probe_debug_tag, "l");
--- 181,187 ----
MODULE_PARM_DESC(probe_debug_range, "Debug range length");
static unsigned long probe_debug_tag = 0;
! #if defined(module_param) && LINUX_VERSION_CODE > KERNEL_VERSION(2,6,9)
module_param(probe_debug_tag, long, 0);
#else
MODULE_PARM(probe_debug_tag, "l");
***************
*** 298,303 ****
--- 300,309 ----
int debug_ignore_NR[4]; /* syscalls to ignore for debugging */
} probectl;
+ #if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
+ static int check_access(unsigned long, int);
+ static int check_table_readable(probectl *, PROBETYPE *);
+ #endif
/********** Probing Configuration: sys_call_table **********/
***************
*** 512,520 ****
/* symbol in section to try scanning */
#if defined(AFS_SPARC64_LINUX20_ENV) || defined(AFS_S390_LINUX20_ENV) || defined(AFS_S390X_LINUX20_ENV)
(unsigned long)&sys_close,
! #elif defined(AFS_AMD64_LINUX20_ENV)
/* On this platform, it's in a different section! */
(unsigned long)&generic_ro_fops,
#else
(unsigned long)&init_mm,
#endif
--- 518,529 ----
/* symbol in section to try scanning */
#if defined(AFS_SPARC64_LINUX20_ENV) || defined(AFS_S390_LINUX20_ENV) || defined(AFS_S390X_LINUX20_ENV)
(unsigned long)&sys_close,
! #elif defined(AFS_AMD64_LINUX26_ENV)
/* On this platform, it's in a different section! */
(unsigned long)&generic_ro_fops,
+ #elif defined(AFS_AMD64_LINUX20_ENV)
+ /* On this platform, it's in a different section! */
+ (unsigned long)&tasklist_lock,
#else
(unsigned long)&init_mm,
#endif
***************
*** 535,544 ****
(unsigned long)(&init_mm),
0x1fffff,
0x30000,
! #elif defined(AFS_AMD64_LINUX20_ENV)
(unsigned long)(&generic_ro_fops) - 0x30000,
0,
0x6000,
#elif defined(AFS_PPC64_LINUX26_ENV)
(unsigned long)(&do_signal),
0xfff,
--- 544,557 ----
(unsigned long)(&init_mm),
0x1fffff,
0x30000,
! #elif defined(AFS_AMD64_LINUX26_ENV)
(unsigned long)(&generic_ro_fops) - 0x30000,
0,
0x6000,
+ #elif defined(AFS_AMD64_LINUX20_ENV)
+ (unsigned long)(&tasklist_lock) - 0x30000,
+ 0,
+ 0x6000,
#elif defined(AFS_PPC64_LINUX26_ENV)
(unsigned long)(&do_signal),
0xfff,
***************
*** 940,945 ****
--- 953,963 ----
PROBETYPE *x;
int i, j;
+ #if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
+ i = check_table_readable(P, ptr);
+ if (i >= 0) return i;
+ #endif
+
for (x = ptr, i = 0; i < _SS(NR_syscalls); i++, x++) {
#ifdef OSI_PROBE_DEBUG
if (probe_debug & 0x0040) {
***************
*** 1062,1067 ****
--- 1080,1090 ----
unsigned long ip1;
int i, s;
+ #if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
+ i = check_table_readable(P, p);
+ if (i >= 0) return 0;
+ #endif
+
/* Check zapped syscalls */
for (i = 1; i < P->n_zapped_syscalls; i++) {
if (p[_SS(P->zapped_syscalls[i])] != p[_SS(P->zapped_syscalls[0])]) {
***************
*** 1349,1355 ****
}
#if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
! static int check_writable(unsigned long address)
{
pgd_t *pgd = pgd_offset_k(address);
#ifdef PUD_SIZE
--- 1372,1378 ----
}
#if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
! static int check_access(unsigned long address, int mode)
{
pgd_t *pgd = pgd_offset_k(address);
#ifdef PUD_SIZE
***************
*** 1374,1383 ****
pte = (pte_t *)pmd;
else
pte = pte_offset_kernel(pmd, address);
! if (pte_none(*pte) || !pte_present(*pte) || !pte_write(*pte))
return 0;
return 1;
}
#endif
void *osi_find_syscall_table(int which)
--- 1397,1430 ----
pte = (pte_t *)pmd;
else
pte = pte_offset_kernel(pmd, address);
! if (pte_none(*pte) || !pte_present(*pte))
! return 0;
! if (mode && !pte_write(*pte))
return 0;
return 1;
}
+
+ static int check_table_readable(probectl *P, PROBETYPE *ptr)
+ {
+ PROBETYPE *next_page;
+ int i = 0, delta;
+
+ while (i < _SS(NR_syscalls)) {
+ next_page = (PROBETYPE *)PAGE_ALIGN((unsigned long)(ptr+1));
+ delta = next_page - ptr;
+ if (!check_access((unsigned long)ptr, 0)) {
+ #ifdef OSI_PROBE_DEBUG
+ if (probe_debug & 0x0080)
+ printk("<7>osi_probe: %s 0x%016lx not readable; delta=0x%lx\n",
+ P->symbol, (unsigned long)ptr, delta);
+ #endif
+ return delta - 1;
+ }
+ ptr += delta;
+ i += delta;
+ }
+ return -1;
+ }
#endif
void *osi_find_syscall_table(int which)
***************
*** 1405,1411 ****
}
printk("Found %s at 0x%lx (%s)\n", P->desc, (unsigned long)answer, method);
#if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
! if (!check_writable((unsigned long)answer)) {
printk("Address 0x%lx is not writable.\n", (unsigned long)answer);
printk("System call hooks will not be installed; proceeding anyway\n");
return 0;
--- 1452,1458 ----
}
printk("Found %s at 0x%lx (%s)\n", P->desc, (unsigned long)answer, method);
#if defined(AFS_I386_LINUX26_ENV) || defined(AFS_AMD64_LINUX26_ENV)
! if (!check_access((unsigned long)answer, 1)) {
printk("Address 0x%lx is not writable.\n", (unsigned long)answer);
printk("System call hooks will not be installed; proceeding anyway\n");
return 0;
Index: openafs/src/afs/LINUX/osi_sleep.c
diff -c openafs/src/afs/LINUX/osi_sleep.c:1.22.2.10 openafs/src/afs/LINUX/osi_sleep.c:1.22.2.11
*** openafs/src/afs/LINUX/osi_sleep.c:1.22.2.10 Thu Jan 4 16:26:34 2007
--- openafs/src/afs/LINUX/osi_sleep.c Tue Jun 12 01:47:47 2007
***************
*** 11,17 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_sleep.c,v 1.22.2.10 2007/01/04 21:26:34 shadow Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
--- 11,17 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_sleep.c,v 1.22.2.11 2007/06/12 05:47:47 rra Exp $");
#include "afs/sysincludes.h" /* Standard vendor system headers */
#include "afsincludes.h" /* Afs-based standard headers */
***************
*** 205,211 ****
--- 205,215 ----
#if defined(STRUCT_TASK_STRUCT_HAS_TODO)
!current->todo
#else
+ #if defined(STRUCT_TASK_STRUCT_HAS_THREAD_INFO)
test_ti_thread_flag(current->thread_info, TIF_FREEZE)
+ #else
+ test_ti_thread_flag(task_thread_info(current), TIF_FREEZE)
+ #endif
#endif
#endif
)
***************
*** 303,309 ****
--- 307,317 ----
#if defined(STRUCT_TASK_STRUCT_HAS_TODO)
!current->todo
#else
+ #if defined(STRUCT_TASK_STRUCT_HAS_THREAD_INFO)
test_ti_thread_flag(current->thread_info, TIF_FREEZE)
+ #else
+ test_ti_thread_flag(task_thread_info(current), TIF_FREEZE)
+ #endif
#endif
#endif
)
Index: openafs/src/afs/LINUX/osi_syscall.c
diff -c openafs/src/afs/LINUX/osi_syscall.c:1.1.2.8 openafs/src/afs/LINUX/osi_syscall.c:1.1.2.9
*** openafs/src/afs/LINUX/osi_syscall.c:1.1.2.8 Fri Dec 1 13:49:28 2006
--- openafs/src/afs/LINUX/osi_syscall.c Mon Mar 26 23:22:25 2007
***************
*** 15,21 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_syscall.c,v 1.1.2.8 2006/12/01 18:49:28 shadow Exp $");
#ifdef AFS_LINUX24_ENV
#include /* early to avoid printf->printk mapping */
--- 15,21 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_syscall.c,v 1.1.2.9 2007/03/27 03:22:25 shadow Exp $");
#ifdef AFS_LINUX24_ENV
#include /* early to avoid printf->printk mapping */
***************
*** 56,64 ****
#if defined(AFS_S390X_LINUX24_ENV)
#define INSERT_SYSCALL(SLOT, TMPPAGE, FUNC) \
! if (POINTER2SYSCALL FUNC > 0x7fffffff) { \
TMPPAGE = kmalloc ( PAGE_SIZE, GFP_DMA|GFP_KERNEL ); \
! if (POINTER2SYSCALL TMPPAGE > 0x7fffffff) { \
printf("Cannot allocate page for FUNC syscall jump vector\n"); \
return EINVAL; \
} \
--- 56,64 ----
#if defined(AFS_S390X_LINUX24_ENV)
#define INSERT_SYSCALL(SLOT, TMPPAGE, FUNC) \
! if (SYSCALL2POINTER FUNC > 0x7fffffff) { \
TMPPAGE = kmalloc ( PAGE_SIZE, GFP_DMA|GFP_KERNEL ); \
! if (SYSCALL2POINTER TMPPAGE > 0x7fffffff) { \
printf("Cannot allocate page for FUNC syscall jump vector\n"); \
return EINVAL; \
} \
Index: openafs/src/afs/LINUX/osi_sysctl.c
diff -c openafs/src/afs/LINUX/osi_sysctl.c:1.7.2.4 openafs/src/afs/LINUX/osi_sysctl.c:1.7.2.5
*** openafs/src/afs/LINUX/osi_sysctl.c:1.7.2.4 Thu Feb 22 16:49:01 2007
--- openafs/src/afs/LINUX/osi_sysctl.c Tue Jun 12 14:28:49 2007
***************
*** 1,7 ****
/*
* osi_sysctl.c: Linux sysctl interface to OpenAFS
*
! * $Id: osi_sysctl.c,v 1.7.2.4 2007/02/22 21:49:01 shadow Exp $
*
* Written Jan 30, 2002 by Kris Van Hees (Sine Nomine Associates)
*/
--- 1,7 ----
/*
* osi_sysctl.c: Linux sysctl interface to OpenAFS
*
! * $Id: osi_sysctl.c,v 1.7.2.5 2007/06/12 18:28:49 shadow Exp $
*
* Written Jan 30, 2002 by Kris Van Hees (Sine Nomine Associates)
*/
***************
*** 27,61 ****
static struct ctl_table_header *afs_sysctl = NULL;
static ctl_table afs_sysctl_table[] = {
! {1, "hm_retry_RO",
! &hm_retry_RO, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
! {2, "hm_retry_RW",
! &hm_retry_RW, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
! {3, "hm_retry_int",
! &hm_retry_int, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
! {4, "GCPAGs",
! &afs_gcpags, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
! {5, "rx_deadtime",
! &afs_rx_deadtime, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
! {6, "bkVolPref",
! &afs_bkvolpref, sizeof(afs_int32), 0644, NULL,
! &proc_dointvec}
! ,
{0}
};
static ctl_table fs_sysctl_table[] = {
! {1, "afs", NULL, 0, 0555, afs_sysctl_table},
{0}
};
--- 27,90 ----
static struct ctl_table_header *afs_sysctl = NULL;
static ctl_table afs_sysctl_table[] = {
! {
! .ctl_name = 1,
! .procname = "hm_retry_RO",
! .data = &hm_retry_RO,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
! {
! .ctl_name = 2,
! .procname = "hm_retry_RW",
! .data = &hm_retry_RW,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
! {
! .ctl_name = 3,
! .procname = "hm_retry_int",
! .data = &hm_retry_int,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
! {
! .ctl_name = 4,
! .procname = "GCPAGs",
! .data = &afs_gcpags,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
! {
! .ctl_name = 5,
! .procname = "rx_deadtime",
! .data = &afs_rx_deadtime,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
! {
! .ctl_name = 6,
! .procname = "bkVolPref",
! .data = &afs_bkvolpref,
! .maxlen = sizeof(afs_int32),
! .mode = 0644,
! .proc_handler = &proc_dointvec
! },
{0}
};
static ctl_table fs_sysctl_table[] = {
! {
! .ctl_name = 1,
! .procname = "afs",
! .mode = 0555,
! .child = afs_sysctl_table
! },
{0}
};
Index: openafs/src/afs/LINUX/osi_vfsops.c
diff -c openafs/src/afs/LINUX/osi_vfsops.c:1.29.2.23 openafs/src/afs/LINUX/osi_vfsops.c:1.29.2.25
*** openafs/src/afs/LINUX/osi_vfsops.c:1.29.2.23 Thu Feb 8 20:25:48 2007
--- openafs/src/afs/LINUX/osi_vfsops.c Tue Jun 12 01:47:47 2007
***************
*** 16,22 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vfsops.c,v 1.29.2.23 2007/02/09 01:25:48 shadow Exp $");
#define __NO_VERSION__ /* don't define kernel_version in module.h */
#include /* early to avoid printf->printk mapping */
--- 16,22 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vfsops.c,v 1.29.2.25 2007/06/12 05:47:47 rra Exp $");
#define __NO_VERSION__ /* don't define kernel_version in module.h */
#include /* early to avoid printf->printk mapping */
***************
*** 292,299 ****
--- 292,301 ----
{
struct vcache *vcp = (struct vcache *) foo;
+ #if defined(SLAB_CTOR_VERIFY)
if ((flags & (SLAB_CTOR_VERIFY|SLAB_CTOR_CONSTRUCTOR)) ==
SLAB_CTOR_CONSTRUCTOR)
+ #endif
inode_init_once(AFSTOV(vcp));
}
***************
*** 316,322 ****
void
afs_destroy_inodecache(void)
{
! (void) kmem_cache_destroy(afs_inode_cachep);
}
#else
int
--- 318,325 ----
void
afs_destroy_inodecache(void)
{
! if (afs_inode_cachep)
! (void) kmem_cache_destroy(afs_inode_cachep);
}
#else
int
Index: openafs/src/afs/LINUX/osi_vnodeops.c
diff -c openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.51 openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.56
*** openafs/src/afs/LINUX/osi_vnodeops.c:1.81.2.51 Tue Feb 20 13:06:24 2007
--- openafs/src/afs/LINUX/osi_vnodeops.c Tue Jun 12 14:35:48 2007
***************
*** 22,28 ****
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vnodeops.c,v 1.81.2.51 2007/02/20 18:06:24 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
--- 22,28 ----
#include "afs/param.h"
RCSID
! ("$Header: /cvs/openafs/src/afs/LINUX/osi_vnodeops.c,v 1.81.2.56 2007/06/12 18:35:48 shadow Exp $");
#include "afs/sysincludes.h"
#include "afsincludes.h"
***************
*** 473,483 ****
#ifdef AFS_LINUX24_ENV
if ((code == 0 || flp->fl_type == F_UNLCK) &&
(cmd == F_SETLK || cmd == F_SETLKW)) {
! #ifdef AFS_LINUX26_ENV
flp->fl_flags &=~ FL_SLEEP;
code = posix_lock_file(fp, flp);
- #else
- code = posix_lock_file(fp, flp, 0);
#endif
if (code && flp->fl_type != F_UNLCK) {
struct AFS_FLOCK flock2;
--- 473,483 ----
#ifdef AFS_LINUX24_ENV
if ((code == 0 || flp->fl_type == F_UNLCK) &&
(cmd == F_SETLK || cmd == F_SETLKW)) {
! #ifdef POSIX_LOCK_FILE_WAIT_ARG
! code = posix_lock_file(fp, flp, 0);
! #else
flp->fl_flags &=~ FL_SLEEP;
code = posix_lock_file(fp, flp);
#endif
if (code && flp->fl_type != F_UNLCK) {
struct AFS_FLOCK flock2;
***************
*** 557,563 ****
--- 557,567 ----
* afs_StoreAllSegments() with AFS_LASTSTORE
*/
static int
+ #if defined(FOP_FLUSH_TAKES_FL_OWNER_T)
+ afs_linux_flush(struct file *fp, fl_owner_t id)
+ #else
afs_linux_flush(struct file *fp)
+ #endif
{
struct vrequest treq;
struct vcache *vcp = VTOAFS(FILE_INODE(fp));
***************
*** 1091,1096 ****
--- 1095,1102 ----
}
tvc->uncred = credp;
tvc->states |= CUnlinked;
+ } else {
+ osi_FreeSmallSpace(__name);
}
AFS_GUNLOCK();
***************
*** 1279,1285 ****
return -code;
}
! #if !defined(AFS_LINUX24_ENV)
/* afs_linux_readlink
* Fill target (which is in user space) with contents of symlink.
*/
--- 1285,1291 ----
return -code;
}
! #if !defined(USABLE_KERNEL_PAGE_SYMLINK_CACHE)
/* afs_linux_readlink
* Fill target (which is in user space) with contents of symlink.
*/
***************
*** 1299,1304 ****
--- 1305,1340 ----
/* afs_linux_follow_link
* a file system dependent link following routine.
*/
+ #if defined(AFS_LINUX24_ENV)
+ static int afs_linux_follow_link(struct dentry *dentry, struct nameidata *nd)
+ {
+ int code;
+ char *name;
+
+ name = osi_Alloc(PATH_MAX);
+ if (!name) {
+ return -EIO;
+ }
+
+ AFS_GLOCK();
+ code = afs_linux_ireadlink(dentry->d_inode, name, PATH_MAX - 1, AFS_UIOSYS);
+ AFS_GUNLOCK();
+
+ if (code < 0) {
+ goto out;
+ }
+
+ name[code] = '\0';
+ code = vfs_follow_link(nd, name);
+
+ out:
+ osi_Free(name, PATH_MAX);
+
+ return code;
+ }
+
+ #else /* !defined(AFS_LINUX24_ENV) */
+
static struct dentry *
afs_linux_follow_link(struct dentry *dp, struct dentry *basep,
unsigned int follow)
***************
*** 1332,1338 ****
AFS_GUNLOCK();
return res;
}
! #endif
/* afs_linux_readpage
* all reads come through here. A strategy-like read call.
--- 1368,1375 ----
AFS_GUNLOCK();
return res;
}
! #endif /* AFS_LINUX24_ENV */
! #endif /* USABLE_KERNEL_PAGE_SYMLINK_CACHE */
/* afs_linux_readpage
* all reads come through here. A strategy-like read call.
***************
*** 1697,1703 ****
/* We really need a separate symlink set of ops, since do_follow_link()
* determines if it _is_ a link by checking if the follow_link op is set.
*/
! #if defined(AFS_LINUX24_ENV)
static int
afs_symlink_filler(struct file *file, struct page *page)
{
--- 1734,1740 ----
/* We really need a separate symlink set of ops, since do_follow_link()
* determines if it _is_ a link by checking if the follow_link op is set.
*/
! #if defined(USABLE_KERNEL_PAGE_SYMLINK_CACHE)
static int
afs_symlink_filler(struct file *file, struct page *page)
{
***************
*** 1732,1741 ****
static struct address_space_operations afs_symlink_aops = {
.readpage = afs_symlink_filler
};
! #endif
static struct inode_operations afs_symlink_iops = {
! #if defined(AFS_LINUX24_ENV)
.readlink = page_readlink,
#if defined(HAVE_KERNEL_PAGE_FOLLOW_LINK)
.follow_link = page_follow_link,
--- 1769,1778 ----
static struct address_space_operations afs_symlink_aops = {
.readpage = afs_symlink_filler
};
! #endif /* USABLE_KERNEL_PAGE_SYMLINK_CACHE */
static struct inode_operations afs_symlink_iops = {
! #if defined(USABLE_KERNEL_PAGE_SYMLINK_CACHE)
.readlink = page_readlink,
#if defined(HAVE_KERNEL_PAGE_FOLLOW_LINK)
.follow_link = page_follow_link,
***************
*** 1743,1755 ****
.follow_link = page_follow_link_light,
.put_link = page_put_link,
#endif
! .setattr = afs_notify_change,
! #else
.readlink = afs_linux_readlink,
.follow_link = afs_linux_follow_link,
.permission = afs_linux_permission,
.revalidate = afs_linux_revalidate,
#endif
};
void
--- 1780,1796 ----
.follow_link = page_follow_link_light,
.put_link = page_put_link,
#endif
! #else /* !defined(USABLE_KERNEL_PAGE_SYMLINK_CACHE) */
.readlink = afs_linux_readlink,
.follow_link = afs_linux_follow_link,
+ #if !defined(AFS_LINUX24_ENV)
.permission = afs_linux_permission,
.revalidate = afs_linux_revalidate,
#endif
+ #endif /* USABLE_KERNEL_PAGE_SYMLINK_CACHE */
+ #if defined(AFS_LINUX24_ENV)
+ .setattr = afs_notify_change,
+ #endif
};
void
***************
*** 1775,1781 ****
} else if (S_ISLNK(ip->i_mode)) {
ip->i_op = &afs_symlink_iops;
! #if defined(AFS_LINUX24_ENV)
ip->i_data.a_ops = &afs_symlink_aops;
ip->i_mapping = &ip->i_data;
#endif
--- 1816,1822 ----
} else if (S_ISLNK(ip->i_mode)) {
ip->i_op = &afs_symlink_iops;
! #if defined(USABLE_KERNEL_PAGE_SYMLINK_CACHE)
ip->i_data.a_ops = &afs_symlink_aops;
ip->i_mapping = &ip->i_data;
#endif
Index: openafs/src/afs/SOLARIS/osi_machdep.h
diff -c openafs/src/afs/SOLARIS/osi_machdep.h:1.7.2.4 openafs/src/afs/SOLARIS/osi_machdep.h:1.7.2.6
*** openafs/src/afs/SOLARIS/osi_machdep.h:1.7.2.4 Tue Jan 2 02:36:10 2007
--- openafs/src/afs/SOLARIS/osi_machdep.h Fri Oct 5 18:23:49 2007
***************
*** 104,107 ****
--- 104,126 ----
#define AfsLargeFileSize(pos, off) ( ((offset_t)(pos)+(offset_t)(off) > (offset_t)0x7fffffff)?1:0)
#endif
+ #if defined(AFS_SUN510_ENV)
+ #include "h/sunddi.h"
+ extern ddi_taskq_t *afs_taskq;
+ extern krwlock_t afsifinfo_lock;
+
+ /* this should be in rx/SOLARIS/rx_knet.c accessed via accessor functions,
+ eventually */
+ #include "net/if.h"
+ /* Global interface info struct */
+ struct afs_ifinfo {
+ char ifname[LIFNAMSIZ];
+ ipaddr_t ipaddr;
+ ipaddr_t netmask;
+ uint_t mtu;
+ uint64_t flags;
+ int metric;
+ ipaddr_t dstaddr;
+ };
+ #endif
#endif /* _OSI_MACHDEP_H_ */
Index: openafs/src/afsd/CellServDB
diff -c /dev/null openafs/src/afsd/CellServDB:1.1.4.2
*** /dev/null Thu Oct 11 16:05:05 2007
--- openafs/src/afsd/CellServDB Wed Sep 5 17:54:41 2007
***************
*** 0 ****
--- 1,589 ----
+ >grand.central.org #GCO Public CellServDB 05 Jul 2007
+ 18.92.0.108 #grand-opening.mit.edu
+ 128.2.203.61 #penn.central.org
+ 130.237.48.87 #andrew.e.kth.se
+ >wu-wien.ac.at #University of Economics, Vienna, Austria
+ 137.208.3.33 #goya.wu-wien.ac.at
+ 137.208.7.57 #caravaggio.wu-wien.ac.at
+ 137.208.127.57 #vermeer.wu-wien.ac.at
+ >hephy.at #hephy-vienna
+ 193.170.243.10 #mowgli.oeaw.ac.at
+ 193.170.243.12 #baloo.oeaw.ac.at
+ 193.170.243.14 #akela.oeaw.ac.at
+ >cgv.tugraz.at #CGV cell
+ 129.27.224.133 #phobos.cgv.tugraz.at
+ 129.27.224.134 #deimos.cgv.tugraz.at
+ 129.27.224.210 #trinculo.cgv.tugraz.at
+ >itp.tugraz.at #Institute of Theoretical and Computational Physics, TU Graz, Aus
+ 129.27.161.7 #faepafs1.tu-graz.ac.at
+ 129.27.161.15 #faepafs2.tu-graz.ac.at
+ 129.27.161.114 #faepafs3.tu-graz.ac.at
+ >sums.math.mcgill.ca #Society of Undergraduate Mathematics Students of McGill Universi
+ 132.216.24.122 #germain.sums.math.mcgill.ca
+ 132.216.24.125 #turing.sums.math.mcgill.ca
+ >cern.ch #European Laboratory for Particle Physics, Geneva
+ 137.138.128.148 #afsdb1.cern.ch
+ 137.138.246.50 #afsdb3.cern.ch
+ 137.138.246.51 #afsdb2.cern.ch
+ >ams.cern.ch #AMS Experiment
+ 137.138.188.185 #ams.cern.ch
+ 137.138.199.58 #pcamsf4.cern.ch
+ >epfl.ch #Swiss Federal Institute of Technology at Lausanne
+ 128.178.109.111 #kd1.epfl.ch
+ 128.178.109.112 #kd2.epfl.ch
+ 128.178.109.113 #kd3.epfl.ch
+ >ethz.ch #Swiss Federal Inst. of Tech. - Zurich, Switzerland
+ 129.132.97.19 #amalthea.ethz.ch
+ 129.132.97.27 #nethzafs-001.ethz.ch
+ 129.132.115.3 #himalia.ethz.ch
+ 129.132.115.37 #nethzafs-005.ethz.ch
+ 129.132.115.38 #nethzafs-006.ethz.ch
+ >psi.ch #Paul Scherrer Institut - Villigen, Switzerland
+ 129.129.190.140 #afs00.psi.ch
+ 129.129.190.141 #afs01.psi.ch
+ 129.129.190.142 #afs02.psi.ch
+ >extundo.com #Simon Josefsson's cell
+ 195.42.214.241 #slipsten.extundo.com
+ >membrain.com #membrain.com
+ 66.93.118.125 #stormy
+ 130.85.24.11 #weasel
+ 130.85.24.13 #straykitten
+ >midnightlinux.com #Midnight Linux, Pittsburgh PA
+ 208.10.142.82 #outpost.midnightlinux.com
+ >setfilepointer.com #SetFilePointer.com
+ 63.224.10.2 #hamlet.SetFilePointer.com
+ 63.224.10.4 #troilus.SetFilePointer.com
+ >sodre.cx #Sodre.cx
+ 128.8.140.165 #greed.sodre.cx
+ >desy.de #Deutsches Elektronen-Synchrotron
+ 131.169.40.62 #vayu.desy.de
+ 131.169.244.60 #solar00.desy.de
+ >gppc.de #GPP Chemnitz mbH
+ 213.187.92.33 #gpp1.gppc.de
+ 213.187.92.34 #paulchen.gppc.de
+ 213.187.92.35 #lotus.gppc.de
+ >ifh.de #DESY Zeuthen
+ 141.34.22.10 #romulus.ifh.de
+ 141.34.22.11 #remus.ifh.de
+ 141.34.22.29 #hekate.ifh.de
+ >lrz-muenchen.de #Leibniz Computing Centre, Germany
+ 129.187.10.36 #afs1.lrz-muenchen.de
+ 129.187.10.56 #afs3.lrz-muenchen.de
+ 129.187.10.57 #afs2.lrz-muenchen.de
+ >ipp-garching.mpg.de #Institut fuer Plasmaphysik
+ 130.183.9.5 #afs-db1.rzg.mpg.de
+ 130.183.100.10 #afs-db2.aug.ipp-garching.mpg.de
+ 130.183.100.23 #afs-db3.aug.ipp-garching.mpg.de
+ >mpe.mpg.de #MPE cell
+ 130.183.130.7 #irafs1.mpe-garching.mpg.de
+ 130.183.134.20 #irafs2.mpe-garching.mpg.de
+ >i1.informatik.rwth-aachen.de #Informatik I, RWTH Aachen
+ 137.226.244.79 #remus.informatik.rwth-aachen.de
+ >tu-bs.de #Technical University of Braunschweig, Germany
+ 134.169.1.1 #rzafs1.rz.tu-bs.de
+ 134.169.1.5 #rzafs2.rz.tu-bs.de
+ 134.169.1.6 #rzafs3.rz.tu-bs.de
+ >tu-chemnitz.de #Technische Universitaet Chemnitz, Germany
+ 134.109.2.1 #zuse.hrz.tu-chemnitz.de
+ 134.109.2.15 #phoenix.hrz.tu-chemnitz.de
+ 134.109.200.7 #aetius.hrz.tu-chemnitz.de
+ >e18.ph.tum.de #Experimental Physics, TU Munich, Germany
+ 129.187.154.223 #hamlet.e18.physik.tu-muenchen.de
+ >uni-bonn.de #University of Bonn, Computing Center
+ 131.220.14.198 #work15-eth.rhrz.uni-bonn.de
+ 131.220.14.205 #node05.rhrz.uni-bonn.de
+ 131.220.15.197 #afs-db1.rhrz.uni-bonn.de
+ >atlass01.physik.uni-bonn.de #Bonn ATLAS
+ 131.220.165.43 #atlass01.physik.uni-bonn.de
+ >uni-freiburg.de #Albert-Ludwigs-Universitat Freiburg
+ 132.230.6.235 #sv6.ruf.uni-freiburg.de
+ 132.230.6.236 #sv7.ruf.uni-freiburg.de
+ 132.230.6.237 #sv8.ruf.uni-freiburg.de
+ >physik.uni-freiburg.de #institute of physics, university Freiburg, Germany
+ 132.230.77.16 #hepafs.physik.uni-freiburg.de
+ >urz.uni-heidelberg.de #Uni Heidelberg (Rechenzentrum)
+ 129.206.119.10 #afsdb.urz.uni-heidelberg.de
+ 129.206.119.16 #afsdb1.urz.uni-heidelberg.de
+ 129.206.119.17 #afsdb2.urz.uni-heidelberg.de
+ >uni-hohenheim.de #University of Hohenheim
+ 144.41.2.2 #rs13.serv.uni-hohenheim.de
+ 144.41.2.3 #rs14.serv.uni-hohenheim.de
+ 144.41.2.4 #rs15.serv.uni-hohenheim.de
+ >rz.uni-jena.de #Rechenzentrum University of Jena, Germany
+ 141.35.2.180 #afs00.rz.uni-jena.de
+ 141.35.2.181 #afs01.rz.uni-jena.de
+ 141.35.2.182 #afs02.rz.uni-jena.de
+ >impetus.uni-koeln.de #Univ. of Cologne - Geophysics/Meteorology Inst.
+ 134.95.80.39 #forano.meteo.uni-koeln.de
+ >meteo.uni-koeln.de #Univ. of Cologne - Inst. for Geophysics & Meteorology
+ 134.95.144.22 #afs1.meteo.uni-koeln.de
+ 134.95.144.24 #afs2.meteo.uni-koeln.de
+ >rrz.uni-koeln.de #University of Cologne - Reg Comp Center
+ 134.95.19.3 #afsdb1.rrz.uni-koeln.de
+ 134.95.19.10 #lyra.rrz.uni-koeln.de
+ 134.95.67.97 #afs.thp.uni-koeln.de
+ 134.95.141.243 #agrippina.rrz.uni-koeln.de
+ >physik.uni-mainz.de #institute of physics, university Mainz, Germany
+ 134.93.130.93 #hardy.physik.uni-mainz.de
+ >uni-mannheim.de #Uni Mannheim (Rechenzentrum)
+ 134.155.97.204 #afsdb1.uni-mannheim.de
+ 134.155.97.205 #afsdb2.uni-mannheim.de
+ 134.155.97.206 #afsdb3.uni-mannheim.de
+ >uni-paderborn.de #University of Paderborn, Germany
+ 131.234.137.10 #afsdb1.uni-paderborn.de
+ 131.234.137.11 #afsdb2.uni-paderborn.de
+ 131.234.137.12 #afsdb3.uni-paderborn.de
+ >physik.uni-wuppertal.de #Physics department of Bergische Universität Wuppertal
+ 132.195.104.3 #afs1.physik.uni-wuppertal.de
+ 132.195.104.230 #afs2.physik.uni-wuppertal.de
+ >s-et.aau.dk #Aalborg Univ., The Student Society, Denmark
+ 130.225.196.22 #afs.s-et.aau.dk
+ >ies.auc.dk #Aalborg Univ., Inst. of Electronic Systems, Denmark
+ 130.225.51.73 #afsdb1.kom.auc.dk
+ 130.225.51.74 #afsdb2.kom.auc.dk
+ 130.225.51.85 #afsdb3.kom.auc.dk
+ >asu.edu #Arizona State University
+ 129.219.10.69 #authen2.asu.edu
+ 129.219.10.70 #authen1.asu.edu
+ 129.219.10.72 #authen3.asu.edu
+ 129.219.100.16 #authen4.asu.edu
+ >hep.caltech.edu #CalTech High Energy Physics
+ 131.215.126.150 #afs.hep.caltech.edu
+ >clarkson.edu #Clarkson University, Potsdam, New York USA
+ 128.153.1.111 #arthur.clarkson.edu
+ 128.153.9.111 #lancelot.clarkson.edu
+ 128.153.17.111 #uther.clarkson.edu
+ >andrew.cmu.edu #Carnegie Mellon University - Computing Services Cell
+ 128.2.10.2 #vice2.fs.andrew.cmu.edu
+ 128.2.10.7 #vice7.fs.andrew.cmu.edu
+ 128.2.10.11 #vice11.fs.andrew.cmu.edu
+ 128.2.10.28 #vice28.fs.andrew.cmu.edu
+ 128.2.32.44 #new-vice12.fs.andrew.cmu.edu
+ >club.cc.cmu.edu #Carnegie Mellon University Computer Club
+ 128.237.157.11 #sodium.club.cc.cmu.edu
+ 128.237.157.13 #potassium.club.cc.cmu.edu
+ >chem.cmu.edu #Carnegie Mellon University - Chemistry Dept.
+ 128.2.40.134 #afs.chem.cmu.edu
+ 128.2.40.140 #afs2.chem.cmu.edu
+ >cs.cmu.edu #Carnegie Mellon University - School of Comp. Sci.
+ 128.2.201.46 #strawberry.srv.cs.cmu.edu
+ 128.2.201.47 #pumpkin.srv.cs.cmu.edu
+ 128.2.201.48 #cherry.srv.cs.cmu.edu
+ >ece.cmu.edu #Carnegie Mellon University - Elec. Comp. Eng. Dept.
+ 128.2.129.7 #porok.ece.cmu.edu
+ 128.2.129.8 #vicio.ece.cmu.edu
+ 128.2.129.9 #e-xing.ece.cmu.edu
+ >scotch.ece.cmu.edu #CMU ECE CALCM research group
+ 128.2.134.82 #lagavulin.ece.cmu.edu
+ >qatar.cmu.edu #Carnegie Mellon University - Qatar
+ 86.36.46.6 #afs1.qatar.cmu.edu
+ 86.36.46.7 #afs2.qatar.cmu.edu
+ >sbp.ri.cmu.edu #Carnegie Mellon University - Sensor Based Planning Lab
+ 128.2.179.12 #nihao.sbp.ri.cmu.edu
+ 128.2.179.113 #youtheman.sbp.ri.cmu.edu
+ >cnf.cornell.edu #CNF
+ 128.253.198.9 #hole.cnf.cornell.edu
+ 128.253.198.27 #smoke.cnf.cornell.edu
+ >msc.cornell.edu #Cornell University Materials Science Center
+ 128.84.231.242 #miranda.ccmr.cornell.edu
+ 128.84.241.35 #co.ccmr.cornell.edu
+ 128.84.249.78 #dax.ccmr.cornell.edu
+ >dbic.dartmouth.edu #Dartmouth Brain Imaging Center
+ 129.170.30.143 #dbicafs1.dartmouth.edu
+ 129.170.30.144 #dbicafs2.dartmouth.edu
+ 129.170.30.145 #dbicafs3.dartmouth.edu
+ >northstar.dartmouth.edu #Dartmouth College Research Computing
+ 129.170.16.22 #halley.dartmouth.edu
+ 129.170.16.42 #oort.dartmouth.edu
+ 129.170.16.43 #cygnusx1.dartmouth.edu
+ >cs.fhm.edu #Department Computer Science Munich University Of Applied Science
+ 129.187.208.2 #srv1.informatik.fh-muenchen.de
+ >eecs.harvard.edu #Harvard - EECS
+ 140.247.60.61 #zermelo.eecs.harvard.edu
+ 140.247.60.83 #corfu.eecs.harvard.edu
+ >iastate.edu #Iowa State University
+ 129.186.1.243 #afsdb-1.iastate.edu
+ 129.186.6.243 #afsdb-2.iastate.edu
+ 129.186.142.243 #afsdb-3.iastate.edu
+ >athena.mit.edu #MIT/Athena cell
+ 18.7.1.66 #paris.mit.edu.
+ 18.7.1.74 #chimera.mit.edu.
+ 18.158.0.37 #prill.mit.edu.
+ >dev.mit.edu #MIT/IS Development cell
+ 18.7.1.70 #wham.mit.edu.
+ 18.92.1.219 #click.mit.edu.
+ 18.92.1.220 #whirr.mit.edu.
+ >net.mit.edu #MIT/Network Group cell
+ 18.7.7.73 #gracie.mit.edu
+ 18.7.21.95 #george.mit.edu
+ >sipb.mit.edu #MIT/SIPB cell
+ 18.181.0.19 #reynelda.mit.edu.
+ 18.181.0.22 #rosebud.mit.edu.
+ 18.181.0.23 #ronald-ann.mit.edu.
+ >soap.mit.edu #MIT School Of Architecture & Planning
+ 18.89.1.204 #crypt.mit.edu
+ 18.89.1.209 #grotto.mit.edu
+ 18.89.2.156 #ac.mit.edu
+ >msu.edu #Michigan State University Main Cell
+ 35.9.7.10 #afsdb0.cl.msu.edu
+ >nd.edu #University of Notre Dame
+ 129.74.223.17 #john.helios.nd.edu
+ 129.74.223.33 #lizardo.helios.nd.edu
+ 129.74.223.65 #buckaroo.helios.nd.edu
+ >pitt.edu #University of Pittsburgh
+ 136.142.8.15 #afs09.srv.cis.pitt.edu
+ 136.142.8.20 #afs10.srv.cis.pitt.edu
+ 136.142.8.21 #afs11.srv.cis.pitt.edu
+ >cs.pitt.edu #University of Pittsburgh - Computer Science
+ 130.49.220.11 #afs01.cs.pitt.edu
+ 130.49.220.12 #afs02.cs.pitt.edu
+ 130.49.220.13 #afs03.cs.pitt.edu
+ >psc.edu #PSC (Pittsburgh Supercomputing Center)
+ 128.182.59.182 #shaggy.psc.edu
+ 128.182.66.184 #velma.psc.edu
+ 128.182.66.185 #daphne.psc.edu
+ >scoobydoo.psc.edu #PSC Test Cell
+ 128.182.59.181 #scooby.psc.edu
+ >cede.psu.edu #Penn State - Center for Engr. Design & Entrepeneurship
+ 146.186.218.10 #greenly.cede.psu.edu
+ 146.186.218.60 #b50.cede.psu.edu
+ 146.186.218.246 #stalin.cede.psu.edu
+ >rose-hulman.edu #Rose-Hulman Institute of Technology
+ 137.112.7.11 #afs1.rose-hulman.edu
+ 137.112.7.12 #afs2.rose-hulman.edu
+ 137.112.7.13 #afs3.rose-hulman.edu
+ >cs.rose-hulman.edu #Rose-Hulman CS Department
+ 137.112.40.10 #galaxy.cs.rose-hulman.edu
+ >rpi.edu #Rensselaer Polytechnic Institute
+ 128.113.22.11 #saul.server.rpi.edu
+ 128.113.22.12 #joab.server.rpi.edu
+ 128.113.22.13 #korah.server.rpi.edu
+ 128.113.22.14 #achan.server.rpi.edu
+ >hep.sc.edu #University of South Carolina, Dept. of Physics
+ 129.252.78.77 #cpeven.physics.sc.edu
+ >cs.stanford.edu #Stanford University Computer Science Department
+ 171.64.64.10 #cs-afs-1.Stanford.EDU
+ 171.64.64.66 #cs-afs-2.stanford.edu
+ 171.64.64.69 #cs-afs-3.stanford.edu
+ >ir.stanford.edu #Stanford University
+ 171.64.7.222 #afsdb1.stanford.edu
+ 171.64.7.234 #afsdb2.stanford.edu
+ 171.64.7.246 #afsdb3.stanford.edu
+ >slac.stanford.edu #Stanford Linear Accelerator Center
+ 134.79.18.25 #afsdb1.slac.stanford.edu
+ 134.79.18.26 #afsdb2.slac.stanford.edu
+ 134.79.18.27 #afsdb3.slac.stanford.edu
+ >ucdavis.edu #University of California at Davis
+ 169.237.104.100 #afs1.ucdavis.edu
+ 169.237.235.176 #afs2.ucdavis.edu
+ 169.237.247.91 #afs3.ucdavis.edu
+ >home.ucdavis.edu #University of California at Davis home directories
+ 169.237.105.91 #home1.ucdavis.edu
+ 169.237.105.92 #home2.ucdavis.edu
+ 169.237.105.93 #home3.ucdavis.edu
+ >physics.ucsb.edu #UC Santa Barbara, Physics Dept
+ 128.111.18.161 #ledzeppelin.physics.ucsb.edu
+ >cats.ucsc.edu #UC Santa Cruz, Comp and Tech Services, California U.S.A
+ 128.114.123.14 #elan.ucsc.edu
+ 128.114.123.15 #ichabod.ucsc.edu
+ 128.114.123.18 #maneki.ucsc.edu
+ >acm.uiuc.edu #ACM at the University of Illinois
+ 128.174.251.8 #alnitak.acm.uiuc.edu
+ 128.174.251.9 #alnilam.acm.uiuc.edu
+ 128.174.251.10 #mintaka.acm.uiuc.edu
+ >illigal.uiuc.edu #Illinois Genetic Algorithms Labaratory
+ 128.174.193.200 #ial.illigal.uiuc.edu
+ 128.174.193.201 #cac.illigal.uiuc.edu
+ 128.174.193.202 #gcs.illigal.uiuc.edu
+ >ncsa.uiuc.edu #University of Illinois
+ 141.142.3.5 #congo.ncsa.uiuc.edu
+ 141.142.3.8 #nile.ncsa.uiuc.edu
+ 141.142.3.9 #kaskaskia.ncsa.uiuc.edu
+ >umbc.edu #University of Maryland, Baltimore County
+ 130.85.24.23 #db2.afs.umbc.edu
+ 130.85.24.87 #db3.afs.umbc.edu
+ 130.85.24.101 #db1.afs.umbc.edu
+ >glue.umd.edu #University of Maryland - Project Glue
+ 128.8.70.11 #olmec.umd.edu
+ 128.8.236.4 #egypt.umd.edu
+ 128.8.236.230 #babylon.umd.edu
+ >wam.umd.edu #University of Maryland Network WAM Project
+ 128.8.70.9 #csc-srv.wam.umd.edu
+ 128.8.236.5 #avw-srv.wam.umd.edu
+ 128.8.236.231 #ptx-srv.wam.umd.edu
+ >umich.edu #University of Michigan - Campus
+ 141.211.1.32 #fear.ifs.umich.edu
+ 141.211.1.33 #surprise.ifs.umich.edu
+ 141.211.1.34 #ruthless.ifs.umich.edu
+ >atlas.umich.edu #ATLAS group cell in physics at University of Michigan
+ 141.211.43.102 #linat02.grid.umich.edu
+ 141.211.43.103 #linat03.grid.umich.edu
+ 141.211.43.104 #linat04.grid.umich.edu
+ >citi.umich.edu #Center for Information Technology Integration
+ 141.211.133.5 #babylon.citi.umich.edu
+ >lsa.umich.edu #University of Michigan - College of LS&A
+ 141.211.211.53 #gerow.lsa.umich.edu
+ 141.211.211.72 #collines.lsa.umich.edu
+ 141.211.211.153 #hodges.lsa.umich.edu
+ >sph.umich.edu #University of Michigan -- School of Public Health
+ 141.211.51.137 #afssph7.sph.umich.edu
+ 141.211.51.139 #afssph0.sph.umich.edu
+ 141.211.51.142 #afssph6.sph.umich.edu
+ >isis.unc.edu #Univ. of NC at Chapel Hill - ITS
+ 152.2.1.5 #db0.isis.unc.edu
+ 152.2.1.6 #db1.isis.unc.edu
+ 152.2.1.7 #db2.isis.unc.edu
+ >physics.unc.edu #Univ. of NC at Chapel Hill, Dept. of Physics
+ 152.2.4.1 #who.physics.unc.edu
+ 152.2.4.3 #what.physics.unc.edu
+ 152.2.4.5 #when.physics.unc.edu
+ >uncc.edu #University of NC at Charlotte Mosaic AFS Cell
+ 152.15.10.70 #as-sm1.uncc.edu
+ 152.15.93.186 #as-ece1.uncc.edu
+ 152.15.181.175 #as-me1.uncc.edu
+ >eng.utah.edu #University of Utah - Engineering
+ 155.98.111.9 #lenny.eng.utah.edu
+ 155.98.111.10 #carl.eng.utah.edu
+ >cs.uwm.edu #University of Wisconsin--Milwaukee
+ 129.89.38.124 #solomons.cs.uwm.edu
+ >cs.wisc.edu #Univ. of Wisconsin-Madison, Computer Sciences Dept.
+ 128.105.132.14 #timon.cs.wisc.edu
+ 128.105.132.15 #pumbaa.cs.wisc.edu
+ 128.105.132.16 #zazu.cs.wisc.edu
+ >engr.wisc.edu #University of Wisconsin-Madison, College of Engineering
+ 144.92.13.14 #larry.cae.wisc.edu
+ 144.92.13.15 #curly.cae.wisc.edu
+ 144.92.13.16 #moe.cae.wisc.edu
+ >hep.wisc.edu #University of Wisconsin -- High Energy Physics
+ 128.104.28.219 #anise.hep.wisc.edu
+ >physics.wisc.edu #Univ. of Wisconsin-Madison, Physics Department
+ 128.104.160.13 #kendra.physics.wisc.edu
+ 128.104.160.14 #fray.physics.wisc.edu
+ 128.104.160.15 #buffy.physics.wisc.edu
+ >ciemat.es #Ciemat, Madrid, Spain
+ 130.206.11.42 #afsdb1.ciemat.es
+ 130.206.11.217 #afsdb2.ciemat.es
+ 130.206.11.247 #afsdb3.ciemat.es
+ >ifca.unican.es #Instituto de Fisica de Cantabria (IFCA), Santander, Spain
+ 193.144.209.20 #gridwall.ifca.unican.es
+ >ific.uv.es #Instituto de Fisica Corpuscular, Valencia, Spain
+ 147.156.163.11 #alpha.ific.uv.es
+ >biocenter.helsinki.fi #University of Helsinki, Institute of Biotechnology
+ 128.214.58.174 #afsdb1.biocenter.helsinki.fi
+ 128.214.88.114 #afsdb2.biocenter.helsinki.fi
+ >dapnia.saclay.cea.fr #CEA DAPNIA
+ 132.166.32.7 #dphrsg.saclay.cea.fr
+ 132.166.32.12 #dphrsl.saclay.cea.fr
+ >grif.fr #GRIF cell
+ 192.54.208.18 #node03.datagrid.cea.fr
+ >in2p3.fr #IN2P3 production cell
+ 134.158.232.11 #ccafsdb1.in2p3.fr
+ 134.158.232.12 #ccafsdb2.in2p3.fr
+ 134.158.232.13 #ccafsdb3.in2p3.fr
+ >anl.gov #Argonne National Laboratory
+ 146.137.96.33 #arteus.ctd.anl.gov
+ 146.137.162.88 #agamemnon.ctd.anl.gov
+ 146.137.194.80 #antenor.ctd.anl.gov
+ >rhic.bnl.gov #Relativistic Heavy Ion Collider
+ 130.199.6.51 #rafs03.rcf.bnl.gov
+ 130.199.6.52 #rafs02.rcf.bnl.gov
+ 130.199.6.69 #rafs01.rcf.bnl.gov
+ >usatlas.bnl.gov #US Atlas Tier 1 Facility at BNL
+ 130.199.48.32 #aafs01.usatlas.bnl.gov
+ 130.199.48.33 #aafs02.usatlas.bnl.gov
+ 130.199.48.34 #aafs03.usatlas.bnl.gov
+ >fnal.gov #Fermi National Acclerator Laboratory
+ 131.225.68.1 #fsus01.fnal.gov
+ 131.225.68.4 #fsus03.fnal.gov
+ 131.225.68.14 #fsus04.fnal.gov
+ >ic-afs.arc.nasa.gov #Code IC, Ames Research Center
+ 128.102.105.62 #udanax.arc.nasa.gov
+ >jpl.nasa.gov #Jet Propulsion Laboratory
+ 137.78.160.21 #afsdb08.jpl.nasa.gov
+ 137.78.160.22 #afsdb09.jpl.nasa.gov
+ 137.78.160.23 #afsdb10.jpl.nasa.gov
+ >nersc.gov #National Energy Research Supercomputer Center
+ 128.55.128.250 #mars.nersc.gov
+ 128.55.128.252 #alfred.nersc.gov
+ 128.55.128.254 #lurch.nersc.gov
+ >bme.hu #Budapest University of Technology and Economics
+ 152.66.241.6 #afs.iit.bme.hu
+ >kfki.hu #Research Institute for Nuclear and Particle Physics - Budapest,H
+ 148.6.8.14 #afs.kfki.hu
+ >caspur.it #CASPUR Inter-University Computing Consortium, Rome
+ 193.204.5.45 #pomodoro.caspur.it
+ 193.204.5.46 #banana.caspur.it
+ 193.204.5.50 #maslo.caspur.it
+ >enea.it #ENEA New Tech. Energy & Environment Agency, Italy
+ 192.107.54.5 #aixfs.frascati.enea.it
+ 192.107.54.11 #rs2ced.frascati.enea.it
+ 192.107.54.12 #43p.frascati.enea.it
+ 192.107.61.235 #serverinfo02.bologna.enea.it
+ 192.107.71.6 #glauco.casaccia.enea.it
+ 192.107.96.233 #riscdb.trisaia.enea.it
+ >fusione.it #Assoz. FUSIONE/Euratom, ENEA, Frascati-Italy
+ 192.107.90.2 #fusafs1.frascati.enea.it
+ 192.107.90.3 #fusafs2.frascati.enea.it
+ 192.107.90.4 #fusafs3.frascati.enea.it
+ >icemb.it #ICEMB, Universita' La Sapienza - Rome - Italy
+ 193.204.6.130 #icembfs.caspur.it
+ >infn.it #Istituto Nazionale di Fisica Nucleare (INFN), Italia
+ 131.154.1.7 #afscnaf.infn.it
+ 141.108.26.75 #afsrm1.roma1.infn.it
+ 192.84.134.75 #afsna.na.infn.it
+ >ba.infn.it #INFN, Sezione di Bari
+ 193.206.185.235 #baafsserver.ba.infn.it
+ 193.206.185.236 #debsrv.ba.infn.it
+ >kloe.infn.it #INFN, KLOE experiment at Laboratori di Frascati
+ 192.135.25.111 #kloeafs1.lnf.infn.it
+ 192.135.25.112 #kloeafs2.lnf.infn.it
+ >le.infn.it #INFN, Sezione di Lecce
+ 192.84.152.40 #afs01.le.infn.it
+ 192.84.152.148 #afs02.le.infn.it
+ >lnf.infn.it #INFN, Laboratori Nazionali di Frascati
+ 193.206.84.121 #afs1.lnf.infn.it
+ 193.206.84.122 #afs2.lnf.infn.it
+ 193.206.84.123 #afs3.lnf.infn.it
+ >lngs.infn.it #INFN, Laboratori Nazionali di Gran Sasso
+ 192.84.135.21 #rsgs05.lngs.infn.it
+ >pi.infn.it #INFN, Sezione di Pisa
+ 131.114.134.26 #unknownhost.pi.infn.it
+ 192.84.133.50 #aix1.pi.infn.it
+ >psm.it #Progetto San Marco, Universita' di Roma-1
+ 151.100.1.65 #atlante.psm.uniroma1.it
+ >tgrid.it #CASPUR-CILEA-CINECA Grid Cell
+ 193.204.5.33 #cccgrid.caspur.it
+ >ictp.trieste.it #The Abdus Salam International Centre for Theoretical Physics (IC
+ 140.105.16.8 #fs1.ictp.trieste.it
+ 140.105.16.9 #fs2.ictp.trieste.it
+ >math.unifi.it #math.unifi.it
+ 150.217.34.182 #xeno.math.unifi.it
+ >ing.uniroma1.it #Universita' La Sapienza, Fac. Ingeneria
+ 151.100.85.253 #alfa.ing.uniroma1.it
+ >dia.uniroma3.it #University Roma Tre - DIA
+ 193.204.161.79 #plm.dia.uniroma3.it
+ 193.204.161.118 #afs.dia.uniroma3.it
+ >vn.uniroma3.it #University of Rome 3, Area Vasca Navale
+ 193.204.161.136 #alfa.dia.uniroma3.it
+ 193.204.161.137 #beta.dia.uniroma3.it
+ 193.204.161.138 #gamma.dia.uniroma3.it
+ >italia #Italian public AFS cell
+ 193.204.5.9 #afs.caspur.it
+ >cmf.nrl.navy.mil #Naval Research Lab - CCS
+ 134.207.10.68 #picard.cmf.nrl.navy.mil
+ 134.207.10.69 #riker.cmf.nrl.navy.mil
+ 134.207.10.70 #kirk.cmf.nrl.navy.mil
+ >lcp.nrl.navy.mil #Naval Research Lab - Lab for Computational Physics
+ 132.250.114.2 #afs1.lcp.nrl.navy.mil
+ 132.250.114.4 #afs2.lcp.nrl.navy.mil
+ 132.250.114.6 #afs3.lcp.nrl.navy.mil
+ >es.net #Energy Sciences Net
+ 198.128.3.21 #fs1.es.net
+ 198.128.3.22 #fs2.es.net
+ 198.128.3.23 #fs3.es.net
+ >laroia.net #Laroia Networks
+ 66.66.102.254 #supercore.laroia.net
+ >sinenomine.net #Sine Nomine Associates
+ 192.204.203.218 #va.sinenomine.net
+ >slackers.net #The Slackers' Network
+ 63.201.48.27 #alexandria.slackers.net
+ >tproa.net #The People's Republic of Ames
+ 72.13.4.23 #service-3.tproa.net
+ 72.13.4.24 #service-4.tproa.net
+ 72.13.4.25 #service-5.tproa.net
+ >nikhef.nl #The Dutch National Institute for High Energy Physics
+ 192.16.185.26 #afs1.nikhef.nl
+ 192.16.185.27 #afs2.nikhef.nl
+ >1ts.org #1TS.ORG, Cambridge, MA
+ 69.25.196.51 #pancake.1ts.org
+ >acm-csuf.org #California State Univerisity Fullerton ACM
+ 137.151.29.193 #afs1.acm-csuf.org
+ >bazquux.org #Baz Quux Organization
+ 66.207.142.196 #baxquux.org
+ >coed.org #Adam Pennington's Cell
+ 66.93.61.184 #vice1.coed.org
+ 128.237.157.35 #vice3.coed.org
+ >dementia.org #Dementia Unlimited
+ 128.2.12.45 #alycia.dementia.org
+ 128.2.120.216 #meredith.dementia.org
+ >hackish.org #Hackish.org
+ 24.167.65.213 #avatar.sys.hackish.org
+ 128.2.120.138 #kurma.sys.hackish.org
+ >idahofuturetruck.org #University of Idaho hybrid vehicle development
+ 12.18.238.210 #dsle210.fsr.net
+ >nimlabs.org #Nimlabs, Ink. Cell.
+ 18.238.1.103 #olfin.nimlabs.org
+ 18.238.1.105 #caerbanog.nimlabs.org
+ >nomh.org #nomh.org
+ 204.29.154.12 #iota.nomh.org
+ 204.29.154.32 #adversity.xi.nomh.org
+ >oc7.org #The OC7 Project
+ 128.2.122.140 #knife.oc7.org
+ 207.22.77.170 #spoon.oc7.org
+ >kth.se #Royal Institute of Technology, Stockholm, Sweden
+ 130.237.32.145 #sonen.e.kth.se
+ 130.237.48.7 #anden.e.kth.se
+ 130.237.48.244 #fadern.e.kth.se
+ >hallf.kth.se #Royal Institute of Technology, HALLF
+ 130.237.24.11 #afs1.hallf.kth.se
+ 130.237.24.104 #afs2.hallf.kth.se
+ >isk.kth.se #Royal Institute of Technology, ISK
+ 130.237.202.3 #afsdb1.isk.kth.se
+ 130.237.209.5 #afsdb2.isk.kth.se
+ 130.237.209.9 #afsdb3.isk.kth.se
+ >it.kth.se #Royal Institute of Technology, IT
+ 130.237.212.15 #ptah.it.kth.se
+ 130.237.212.16 #toth.it.kth.se
+ 130.237.215.7 #isis.it.kth.se
+ >md.kth.se #Royal Institute of Technology, MMK
+ 130.237.57.68 #trinity.md.kth.se
+ 130.237.57.72 #morpheus.md.kth.se
+ 130.237.67.230 #neo.speech.kth.se
+ >mech.kth.se #Royal Institute of Technology, MECH
+ 130.237.233.142 #matterhorn.mech.kth.se
+ 130.237.233.143 #castor.mech.kth.se
+ 130.237.233.144 #pollux.mech.kth.se
+ >nada.kth.se #Royal Institute of Technology, NADA
+ 130.237.222.20 #kosmos.nada.kth.se
+ 130.237.223.12 #sputnik.nada.kth.se
+ 130.237.224.78 #mir.nada.kth.se
+ 130.237.227.23 #gagarin.nada.kth.se
+ 130.237.228.28 #laika.nada.kth.se
+ >pdc.kth.se #Royal Institute of Technology, PDC
+ 130.237.232.29 #crab.pdc.kth.se
+ 130.237.232.112 #anna.pdc.kth.se
+ 130.237.232.114 #hokkigai.pdc.kth.se
+ >stacken.kth.se #Stacken Computer Club
+ 130.237.234.3 #milko.stacken.kth.se
+ 130.237.234.43 #hot.stacken.kth.se
+ 130.237.234.101 #fishburger.stacken.kth.se
+ >syd.kth.se #Royal Institute of Technology, KTH-Syd
+ 130.237.83.23 #afs.haninge.kth.se
+ >physto.se #Physics department Stockholm University
+ 130.237.205.36 #sysafs1.physto.se
+ 130.237.205.72 #sysafs2.physto.se
+ >sanchin.se #Sanchin Consulting AB, Sweden
+ 192.195.148.10 #sesan.sanchin.se
+ >su.se #Stockholm University
+ 130.237.162.81 #afsdb1.su.se
+ 130.237.162.82 #afsdb2.su.se
+ 130.237.162.230 #afsdb3.su.se
+ >f9.ijs.si #F9, Jozef Stefan Institue
+ 194.249.156.1 #brenta.ijs.si
+ >p-ng.si #Nova Gorica Polytechnic
+ 193.2.120.2 #solkan.p-ng.si
+ >phy.bris.ac.uk #Bristol University - phyics
+ 137.222.58.9 #afs1.phy.bris.ac.uk
+ >inf.ed.ac.uk #School of Informatics, University of Edinburgh
+ 129.215.64.16 #afsdb0.inf.ed.ac.uk
+ 129.215.64.17 #afsdb1.inf.ed.ac.uk
+ 129.215.64.18 #afsdb2.inf.ed.ac.uk
+ >ic.ac.uk #Imperial College London
+ 155.198.63.148 #icafs2.cc.ic.ac.uk
+ 155.198.63.149 #icafs1.cc.ic.ac.uk
+ >hep.man.ac.uk #Manchester HEP
+ 194.36.2.3 #afs1.hep.man.ac.uk
+ 194.36.2.4 #afs2.hep.man.ac.uk
+ 194.36.2.5 #afs3.hep.man.ac.uk
+ >rl.ac.uk #Rutherford Appleton Lab, England
+ 130.246.183.164 #wallace.cc.rl.ac.uk
Index: openafs/src/afsd/afsd.c
diff -c openafs/src/afsd/afsd.c:1.43.2.18 openafs/src/afsd/afsd.c:1.43.2.22
*** openafs/src/afsd/afsd.c:1.43.2.18 Mon Aug 21 16:39:40 2006
--- openafs/src/afsd/afsd.c Wed Oct 10 12:57:56 2007
***************
*** 58,64 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/afsd/afsd.c,v 1.43.2.18 2006/08/21 20:39:40 shadow Exp $");
#define VFS 1
--- 58,64 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/afsd/afsd.c,v 1.43.2.22 2007/10/10 16:57:56 shadow Exp $");
#define VFS 1
***************
*** 165,170 ****
--- 165,200 ----
kern_return_t DiskArbDiskAppearedWithMountpointPing_auto(char *, unsigned int,
char *);
#define DISK_ARB_NETWORK_DISK_FLAG 8
+
+ #include
+ #include
+ #include
+
+ #include
+
+ #include
+ #include
+
+ #include
+ #include
+
+ #include
+
+ typedef struct DNSSDState
+ {
+ DNSServiceRef service;
+ CFRunLoopSourceRef source;
+ CFSocketRef socket;
+ } DNSSDState;
+
+ static io_connect_t root_port;
+ static IONotificationPortRef notify;
+ static io_object_t iterator;
+ static CFRunLoopSourceRef source;
+ static DNSSDState dnsstate;
+
+ static int event_pid;
+
#endif /* AFS_DARWIN_ENV */
#ifndef MOUNT_AFS
***************
*** 302,309 ****
--- 332,341 ----
* -2: file exists in top-level
* >=0: file exists in Dxxx
*/
+ #ifndef AFS_CACHE_VNODE_PATH
AFSD_INO_T *inode_for_V; /* Array of inodes for desired
* cache files */
+ #endif
int missing_DCacheFile = 1; /*Is the DCACHEFILE missing? */
int missing_VolInfoFile = 1; /*Is the VOLINFOFILE missing? */
int missing_CellInfoFile = 1; /*Is the CELLINFOFILE missing? */
***************
*** 312,317 ****
--- 344,505 ----
static int HandleMTab();
+ #ifdef AFS_DARWIN_ENV
+ static void
+ afsd_sleep_callback(void * refCon, io_service_t service,
+ natural_t messageType, void * messageArgument )
+ {
+ afs_int32 code;
+
+ switch (messageType) {
+ case kIOMessageCanSystemSleep:
+ /* Idle sleep is about to kick in; can
+ prevent sleep by calling IOCancelPowerChange, otherwise
+ if we don't ack in 30s the system sleeps anyway */
+
+ /* allow it */
+ IOAllowPowerChange(root_port, (long)messageArgument);
+ break;
+
+ case kIOMessageSystemWillSleep:
+ /* The system WILL go to sleep. Ack or suffer delay */
+
+ IOAllowPowerChange(root_port, (long)messageArgument);
+ break;
+
+ case kIOMessageSystemWillRestart:
+ /* The system WILL restart. Ack or suffer delay */
+
+ IOAllowPowerChange(root_port, (long)messageArgument);
+ break;
+
+ case kIOMessageSystemWillPowerOn:
+ case kIOMessageSystemHasPoweredOn:
+ /* coming back from sleep */
+
+ IOAllowPowerChange(root_port, (long)messageArgument);
+ break;
+
+ default:
+ IOAllowPowerChange(root_port, (long)messageArgument);
+ break;
+ }
+ }
+
+ static void
+ afsd_update_addresses(CFRunLoopTimerRef timer, void *info)
+ {
+ /* parse multihomed address files */
+ afs_int32 addrbuf[MAXIPADDRS], maskbuf[MAXIPADDRS],
+ mtubuf[MAXIPADDRS];
+ char reason[1024];
+ afs_int32 code;
+
+ code =
+ parseNetFiles(addrbuf, maskbuf, mtubuf, MAXIPADDRS, reason,
+ AFSDIR_CLIENT_NETINFO_FILEPATH,
+ AFSDIR_CLIENT_NETRESTRICT_FILEPATH);
+
+ if (code > 0) {
+ /* Note we're refreshing */
+ code = code | 0x40000000;
+ call_syscall(AFSOP_ADVISEADDR, code, addrbuf, maskbuf, mtubuf);
+ } else
+ printf("ADVISEADDR: Error in specifying interface addresses:%s\n",
+ reason);
+ }
+
+ /* This function is called when the system's ip addresses may have changed. */
+ static void
+ afsd_ipaddr_callback (SCDynamicStoreRef store, CFArrayRef changed_keys, void *info)
+ {
+ CFRunLoopTimerRef timer;
+
+ timer = CFRunLoopTimerCreate (NULL, CFAbsoluteTimeGetCurrent () + 1.0,
+ 0.0, 0, 0, afsd_update_addresses, NULL);
+ CFRunLoopAddTimer (CFRunLoopGetCurrent (), timer,
+ kCFRunLoopDefaultMode);
+ CFRelease (timer);
+ }
+
+ static void
+ afsd_event_cleanup(int signo) {
+ DNSSDState *query = &dnsstate;
+
+ CFRunLoopRemoveSource(CFRunLoopGetCurrent(), source, kCFRunLoopDefaultMode);
+ CFRelease (source);
+ IODeregisterForSystemPower(iterator);
+ IOServiceClose(root_port);
+ IONotificationPortDestroy(notify);
+
+ exit(0);
+ }
+
+ /* Adapted from "Living in a Dynamic TCP/IP Environment" technote. */
+ static Boolean
+ afsd_install_events(void)
+ {
+ SCDynamicStoreContext ctx = {0};
+ SCDynamicStoreRef store;
+
+ root_port = IORegisterForSystemPower(0,¬ify,afsd_sleep_callback,&iterator);
+
+ if (root_port) {
+ CFRunLoopAddSource(CFRunLoopGetCurrent(),
+ IONotificationPortGetRunLoopSource(notify),
+ kCFRunLoopDefaultMode);
+ }
+
+
+ store = SCDynamicStoreCreate (NULL,
+ CFSTR ("AddIPAddressListChangeCallbackSCF"),
+ afsd_ipaddr_callback, &ctx);
+
+ if (store) {
+ const void *keys[1];
+
+ /* Request IPV4 address change notification */
+ keys[0] = (SCDynamicStoreKeyCreateNetworkServiceEntity
+ (NULL, kSCDynamicStoreDomainState,
+ kSCCompAnyRegex, kSCEntNetIPv4));
+
+ #if 0
+ /* This should tell us when the hostname(s) change. do we care? */
+ keys[N] = SCDynamicStoreKeyCreateHostNames (NULL);
+ #endif
+
+ if (keys[0] != NULL) {
+ CFArrayRef pattern_array;
+
+ pattern_array = CFArrayCreate (NULL, keys, 1,
+ &kCFTypeArrayCallBacks);
+
+ if (pattern_array != NULL)
+ {
+ SCDynamicStoreSetNotificationKeys (store, NULL, pattern_array);
+ source = SCDynamicStoreCreateRunLoopSource (NULL, store, 0);
+
+ CFRelease (pattern_array);
+ }
+
+ if (keys[0] != NULL)
+ CFRelease (keys[0]);
+ }
+
+ CFRelease (store);
+ }
+
+ if (source != NULL) {
+ CFRunLoopAddSource (CFRunLoopGetCurrent(),
+ source, kCFRunLoopDefaultMode);
+ }
+
+ signal(SIGTERM, afsd_event_cleanup);
+
+ CFRunLoopRun();
+ }
+ #endif
+
/* ParseArgs is now obsolete, being handled by cmd */
/*------------------------------------------------------------------------------
***************
*** 817,823 ****
--- 1005,1013 ----
* file's inode, directory, and bump the number of files found
* total and in this directory.
*/
+ #ifndef AFS_CACHE_VNODE_PATH
inode_for_V[vFileNum] = currp->d_ino;
+ #endif
dir_for_V[vFileNum] = dirNum; /* remember this directory */
if (!maxDir) {
***************
*** 954,960 ****
--- 1144,1152 ----
vFileNum);
else {
struct stat statb;
+ #ifndef AFS_CACHE_VNODE_PATH
assert(inode_for_V[vFileNum] == (AFSD_INO_T) 0);
+ #endif
sprintf(vFilePtr, "D%d/V%d", thisDir, vFileNum);
if (afsd_verbose)
printf("%s: Creating '%s'\n", rn, fullpn_VFile);
***************
*** 965,971 ****
--- 1157,1165 ----
if (CreateCacheFile(fullpn_VFile, &statb))
printf("%s: Can't create '%s'\n", rn, fullpn_VFile);
else {
+ #ifndef AFS_CACHE_VNODE_PATH
inode_for_V[vFileNum] = statb.st_ino;
+ #endif
dir_for_V[vFileNum] = thisDir;
cache_dir_list[thisDir]++;
(*vFilesFound)++;
***************
*** 1247,1252 ****
--- 1441,1456 ----
kernelMsg[1] = 0;
acellName[0] = '\0';
+ #ifdef AFS_DARWIN_ENV
+ /* Fork the event handler also. */
+ code = fork();
+ if (code == 0) {
+ afsd_install_events();
+ exit(1);
+ } else if (code != -1) {
+ event_pid = code;
+ }
+ #endif
while (1) {
/* On some platforms you only get 4 args to an AFS call */
int sizeArg = ((sizeof acellName) << 16) | (sizeof kernelMsg);
***************
*** 1276,1282 ****
acellName[sizeof(acellName) - 1] = '\0';
}
}
!
exit(1);
}
#endif
--- 1480,1488 ----
acellName[sizeof(acellName) - 1] = '\0';
}
}
! #ifdef AFS_DARWIN_ENV
! kill(event_pid, SIGTERM);
! #endif
exit(1);
}
#endif
***************
*** 1705,1710 ****
--- 1911,1917 ----
cacheStatEntries);
}
+ #ifndef AFS_CACHE_VNODE_PATH
/*
* Create and zero the inode table for the desired cache files.
*/
***************
*** 1719,1724 ****
--- 1926,1932 ----
if (afsd_debug)
printf("%s: %d inode_for_V entries at 0x%x, %d bytes\n", rn,
cacheFiles, inode_for_V, (cacheFiles * sizeof(AFSD_INO_T)));
+ #endif
/*
* Set up all the pathnames we'll need for later.
***************
*** 1737,1746 ****
exit(1);
#endif
}
- #if 0
- fputs(AFS_GOVERNMENT_MESSAGE, stdout);
- fflush(stdout);
- #endif
/*
* Set up all the kernel processes needed for AFS.
--- 1945,1950 ----
***************
*** 1903,1908 ****
--- 2107,2129 ----
rn, vFilesFound, cacheFiles, cacheIteration);
} while ((vFilesFound < cacheFiles)
&& (cacheIteration < MAX_CACHE_LOOPS));
+ #ifdef AFS_CACHE_VNODE_PATH
+ if (afsd_debug)
+ printf
+ ("%s: Calling AFSOP_CACHEBASEDIR with '%s'\n",
+ rn, cacheBaseDir);
+ call_syscall(AFSOP_CACHEBASEDIR, cacheBaseDir);
+ if (afsd_debug)
+ printf
+ ("%s: Calling AFSOP_CACHEDIRS with %d dirs\n",
+ rn, nFilesPerDir);
+ call_syscall(AFSOP_CACHEDIRS, nFilesPerDir);
+ if (afsd_debug)
+ printf
+ ("%s: Calling AFSOP_CACHEFILES with %d files\n",
+ rn, cacheFiles);
+ call_syscall(AFSOP_CACHEFILES, cacheFiles);
+ #endif
} else if (afsd_verbose)
printf("%s: Using memory cache, not swept\n", rn);
***************
*** 2037,2042 ****
--- 2258,2264 ----
if (!(cacheFlags & AFSCALL_INIT_MEMCACHE))
call_syscall(AFSOP_VOLUMEINFO, fullpn_VolInfoFile);
+ #ifndef AFS_CACHE_VNODE_PATH
/*
* Give the kernel the names of the AFS files cached on the workstation's
* disk.
***************
*** 2055,2061 ****
call_syscall(AFSOP_CACHEINODE, inode_for_V[currVFile]);
#endif
}
!
/*end for */
/*
--- 2277,2283 ----
call_syscall(AFSOP_CACHEINODE, inode_for_V[currVFile]);
#endif
}
! #endif
/*end for */
/*
Index: openafs/src/aklog/Makefile.in
diff -c openafs/src/aklog/Makefile.in:1.1.2.8 openafs/src/aklog/Makefile.in:1.1.2.9
*** openafs/src/aklog/Makefile.in:1.1.2.8 Thu Jan 4 22:22:00 2007
--- openafs/src/aklog/Makefile.in Tue Apr 10 14:43:40 2007
***************
*** 11,17 ****
${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/librxkad.a \
${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/liblwp.a \
${TOP_LIBDIR}/libsys.a ${TOP_LIBDIR}/libdes.a \
! ${TOP_LIBDIR}/libafsutil.a
SRCS= aklog.c aklog_main.c krb_util.c linked_list.c
OBJS= aklog.o aklog_main.o krb_util.o linked_list.o
--- 11,17 ----
${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/librxkad.a \
${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/liblwp.a \
${TOP_LIBDIR}/libsys.a ${TOP_LIBDIR}/libdes.a \
! ${TOP_LIBDIR}/libcom_err.a ${TOP_LIBDIR}/libafsutil.a
SRCS= aklog.c aklog_main.c krb_util.c linked_list.c
OBJS= aklog.o aklog_main.o krb_util.o linked_list.o
Index: openafs/src/aklog/aklog.h
diff -c openafs/src/aklog/aklog.h:1.1.2.5 openafs/src/aklog/aklog.h:1.1.2.6
*** openafs/src/aklog/aklog.h:1.1.2.5 Wed Apr 5 11:42:13 2006
--- openafs/src/aklog/aklog.h Wed Jul 11 00:32:27 2007
***************
*** 1,5 ****
/*
! * $Id: aklog.h,v 1.1.2.5 2006/04/05 15:42:13 shadow Exp $
*
* Copyright 1990,1991 by the Massachusetts Institute of Technology
* For distribution and copying rights, see the file "mit-copyright.h"
--- 1,5 ----
/*
! * $Id: aklog.h,v 1.1.2.6 2007/07/11 04:32:27 shadow Exp $
*
* Copyright 1990,1991 by the Massachusetts Institute of Technology
* For distribution and copying rights, see the file "mit-copyright.h"
***************
*** 9,15 ****
#define __AKLOG_H__
#if !defined(lint) && !defined(SABER)
! static char *rcsid_aklog_h = "$Id: aklog.h,v 1.1.2.5 2006/04/05 15:42:13 shadow Exp $";
#endif /* lint || SABER */
#include
--- 9,15 ----
#define __AKLOG_H__
#if !defined(lint) && !defined(SABER)
! static char *rcsid_aklog_h = "$Id: aklog.h,v 1.1.2.6 2007/07/11 04:32:27 shadow Exp $";
#endif /* lint || SABER */
#include
***************
*** 51,56 ****
--- 51,60 ----
#define INST_SZ 40
#endif /* INST_SZ */
+ #ifndef u_int32_t
+ #define u_int32_t uint32_t
+ #endif
+
struct ktext {
unsigned int length;
unsigned char dat[MAX_KTXT_LEN];
Index: openafs/src/aklog/aklog_main.c
diff -c openafs/src/aklog/aklog_main.c:1.1.2.15 openafs/src/aklog/aklog_main.c:1.1.2.20
*** openafs/src/aklog/aklog_main.c:1.1.2.15 Sat Feb 10 08:56:54 2007
--- openafs/src/aklog/aklog_main.c Wed Oct 10 13:47:58 2007
***************
*** 1,13 ****
/*
! * $Id: aklog_main.c,v 1.1.2.15 2007/02/10 13:56:54 jaltman Exp $
*
* Copyright 1990,1991 by the Massachusetts Institute of Technology
* For distribution and copying rights, see the file "mit-copyright.h"
*/
#if !defined(lint) && !defined(SABER)
static char *rcsid =
! "$Id: aklog_main.c,v 1.1.2.15 2007/02/10 13:56:54 jaltman Exp $";
#endif /* lint || SABER */
#include
--- 1,42 ----
/*
! * $Id: aklog_main.c,v 1.1.2.20 2007/10/10 17:47:58 shadow Exp $
*
* Copyright 1990,1991 by the Massachusetts Institute of Technology
* For distribution and copying rights, see the file "mit-copyright.h"
*/
+ /*
+ * Copyright (c) 2005, 2006
+ * The Linux Box Corporation
+ * ALL RIGHTS RESERVED
+ *
+ * Permission is granted to use, copy, create derivative works
+ * and redistribute this software and such derivative works
+ * for any purpose, so long as the name of the Linux Box
+ * Corporation is not used in any advertising or publicity
+ * pertaining to the use or distribution of this software
+ * without specific, written prior authorization. If the
+ * above copyright notice or any other identification of the
+ * Linux Box Corporation is included in any copy of any
+ * portion of this software, then the disclaimer below must
+ * also be included.
+ *
+ * This software is provided as is, without representation
+ * from the Linux Box Corporation as to its fitness for any
+ * purpose, and without warranty by the Linux Box Corporation
+ * of any kind, either express or implied, including
+ * without limitation the implied warranties of
+ * merchantability and fitness for a particular purpose. The
+ * regents of the Linux Box Corporation shall not be liable
+ * for any damages, including special, indirect, incidental, or
+ * consequential damages, with respect to any claim arising
+ * out of or in connection with the use of the software, even
+ * if it has been or is hereafter advised of the possibility of
+ * such damages.
+ */
#if !defined(lint) && !defined(SABER)
static char *rcsid =
! "$Id: aklog_main.c,v 1.1.2.20 2007/10/10 17:47:58 shadow Exp $";
#endif /* lint || SABER */
#include
***************
*** 39,65 ****
#include
#endif /* WINDOWS */
- /* on AIX AFS has an unresolved reference to osi_audit. We will define
- * it here as extern. It also trys to call the ntohl and htonl routines
- * as routines rather then macros. We need a real routine here.
- * We do this before the ntohl and htonl macros are defined in net/in.h
- */
- int osi_audit()
- { return(0);}
-
- #if 0
- #ifdef _AIX
- u_long htonl(u_long x)
- { return(x);}
-
- u_long ntohl(u_long x)
- { return(x);}
- #endif
-
- #include
- /* #include */
- #endif /* 0 */
-
#include
#include
--- 68,73 ----
***************
*** 90,95 ****
--- 98,110 ----
#include "aklog.h"
#include "linked_list.h"
+ #ifdef HAVE_KRB5_CREDS_KEYBLOCK
+ #define USING_MIT 1
+ #endif
+ #ifdef HAVE_KRB5_CREDS_SESSION
+ #define USING_HEIMDAL 1
+ #endif
+
#define AFSKEY "afs"
#define AFSINST ""
***************
*** 184,189 ****
--- 199,239 ----
#error "Must have either krb5_princ_size or krb5_principal_get_comp_string"
#endif
+ #if !defined(HAVE_KRB5_ENCRYPT_TKT_PART) && defined(HAVE_ENCODE_KRB5_ENC_TKT_PART)
+ krb5_error_code
+ krb5_encrypt_tkt_part(krb5_context context,
+ const krb5_keyblock *key,
+ krb5_ticket *ticket)
+ {
+ krb5_data *data = 0;
+ int code;
+ size_t enclen;
+
+ if ((code = encode_krb5_enc_tkt_part(ticket->enc_part2, &data)))
+ goto Done;
+ if ((code = krb5_c_encrypt_length(context, key->enctype,
+ data->length, &enclen)))
+ goto Done;
+ ticket->enc_part.ciphertext.length = enclen;
+ if (!(ticket->enc_part.ciphertext.data = malloc(enclen))) {
+ code = ENOMEM;
+ goto Done;
+ }
+ if ((code = krb5_c_encrypt(context, key, KRB5_KEYUSAGE_KDC_REP_TICKET,
+ 0, data, &ticket->enc_part))) {
+ free(ticket->enc_part.ciphertext.data);
+ ticket->enc_part.ciphertext.data = 0;
+ }
+ Done:
+ if (data) {
+ if (data->data)
+ free(data->data);
+ free(data);
+ }
+ return code;
+ }
+ #endif
+
#if defined(HAVE_KRB5_CREDS_KEYBLOCK)
#define get_cred_keydata(c) c->keyblock.contents
***************
*** 203,211 ****
#if !defined(HAVE_KRB5_524_CONVERT_CREDS) && defined(HAVE_KRB524_CONVERT_CREDS_KDC)
#define krb5_524_convert_creds krb524_convert_creds_kdc
#elif !defined(HAVE_KRB5_524_CONVERT_CREDS) && !defined(HAVE_KRB524_CONVERT_CREDS_KDC)
! #error "You must have one of krb5_524_convert_creds or krb524_convert_creds_kdc available"
#endif
#endif /* WINDOWS */
/*
--- 253,305 ----
#if !defined(HAVE_KRB5_524_CONVERT_CREDS) && defined(HAVE_KRB524_CONVERT_CREDS_KDC)
#define krb5_524_convert_creds krb524_convert_creds_kdc
#elif !defined(HAVE_KRB5_524_CONVERT_CREDS) && !defined(HAVE_KRB524_CONVERT_CREDS_KDC)
! #define HAVE_NO_KRB5_524
#endif
+ #if USING_HEIMDAL
+ #define deref_keyblock_enctype(kb) \
+ ((kb)->keytype)
+
+ #define deref_entry_keyblock(entry) \
+ entry->keyblock
+
+ #define deref_session_key(creds) \
+ creds->session
+
+ #define deref_enc_tkt_addrs(tkt) \
+ tkt->caddr
+
+ #define deref_enc_length(enc) \
+ ((enc)->cipher.length)
+
+ #define deref_enc_data(enc) \
+ ((enc)->cipher.data)
+
+ #define krb5_free_keytab_entry_contents krb5_kt_free_entry
+
+ #else
+ #define deref_keyblock_enctype(kb) \
+ ((kb)->enctype)
+
+ #define deref_entry_keyblock(entry) \
+ entry->key
+
+ #define deref_session_key(creds) \
+ creds->keyblock
+
+ #define deref_enc_tkt_addrs(tkt) \
+ tkt->caddrs
+
+ #define deref_enc_length(enc) \
+ ((enc)->ciphertext.length)
+
+ #define deref_enc_data(enc) \
+ ((enc)->ciphertext.data)
+
+ #endif
+
+ #define deref_entry_enctype(entry) \
+ deref_keyblock_enctype(&deref_entry_keyblock(entry))
#endif /* WINDOWS */
/*
***************
*** 223,232 ****
static int zsubs = FALSE; /* Are we keeping track of zephyr subs? */
static int hosts = FALSE; /* Are we keeping track of hosts? */
static int noprdb = FALSE; /* Skip resolving name to id? */
! static int linked = FALSE; /* try for both AFS nodes */
! static int afssetpag = FALSE; /* setpag for AFS */
static int force = FALSE; /* Bash identical tokens? */
static int do524 = FALSE; /* Should we do 524 instead of rxkad2b? */
static linked_list zsublist; /* List of zephyr subscriptions */
static linked_list hostlist; /* List of host addresses */
static linked_list authedcells; /* List of cells already logged to */
--- 317,328 ----
static int zsubs = FALSE; /* Are we keeping track of zephyr subs? */
static int hosts = FALSE; /* Are we keeping track of hosts? */
static int noprdb = FALSE; /* Skip resolving name to id? */
! static int linked = FALSE; /* try for both AFS nodes */
! static int afssetpag = FALSE; /* setpag for AFS */
static int force = FALSE; /* Bash identical tokens? */
static int do524 = FALSE; /* Should we do 524 instead of rxkad2b? */
+ static char *keytab = NULL; /* keytab for akimpersonate */
+ static char *client = NULL; /* client principal for akimpersonate */
static linked_list zsublist; /* List of zephyr subscriptions */
static linked_list hostlist; /* List of host addresses */
static linked_list authedcells; /* List of cells already logged to */
***************
*** 247,263 ****
}
- static char *copy_string(char *string)
- {
- char *new_string;
-
- if ((new_string = (char *)calloc(strlen(string) + 1, sizeof(char))))
- (void) strcpy(new_string, string);
-
- return (new_string);
- }
-
-
static int get_cellconfig(char *cell, struct afsconf_cell *cellconfig, char *local_cell, char *linkedcell)
{
int status = AKLOG_SUCCESS;
--- 343,348 ----
***************
*** 625,631 ****
}
fprintf(stderr, "%s: Couldn't get %s AFS tickets:\n",
progname, cell_to_use);
! com_err(progname, status, "while getting AFS tickets");
return(AKLOG_KERBEROS);
}
--- 710,716 ----
}
fprintf(stderr, "%s: Couldn't get %s AFS tickets:\n",
progname, cell_to_use);
! afs_com_err(progname, status, "while getting AFS tickets");
return(AKLOG_KERBEROS);
}
***************
*** 669,674 ****
--- 754,760 ----
get_cred_keylen(v5cred));
atoken.ticketLen = v5cred->ticket.length;
memcpy(atoken.ticket, v5cred->ticket.data, atoken.ticketLen);
+ #ifndef HAVE_NO_KRB5_524
} else {
CREDENTIALS cred;
***************
*** 678,684 ****
status = krb5_524_convert_creds(context, v5cred, &cred);
if (status) {
! com_err(progname, status, "while converting tickets "
"to Kerberos V4 format");
return(AKLOG_KERBEROS);
}
--- 764,770 ----
status = krb5_524_convert_creds(context, v5cred, &cred);
if (status) {
! afs_com_err(progname, status, "while converting tickets "
"to Kerberos V4 format");
return(AKLOG_KERBEROS);
}
***************
*** 703,708 ****
--- 789,795 ----
memcpy(&atoken.sessionKey, cred.session, 8);
atoken.ticketLen = cred.ticket_st.length;
memcpy(atoken.ticket, cred.ticket_st.dat, atoken.ticketLen);
+ #endif /* HAVE_NO_KRB5_524 */
}
if (!force &&
***************
*** 735,741 ****
if ((status = get_user_realm(context, realm_of_user))) {
fprintf(stderr, "%s: Couldn't determine realm of user:)",
progname);
! com_err(progname, status, " while getting realm");
return(AKLOG_KERBEROS);
}
if (strcmp(realm_of_user, realm_of_cell)) {
--- 822,828 ----
if ((status = get_user_realm(context, realm_of_user))) {
fprintf(stderr, "%s: Couldn't determine realm of user:)",
progname);
! afs_com_err(progname, status, " while getting realm");
return(AKLOG_KERBEROS);
}
if (strcmp(realm_of_user, realm_of_cell)) {
***************
*** 812,818 ****
if ((status = pr_CreateUser(username, &id))) {
fprintf(stderr, "%s: %s so unable to create remote PTS "
"user %s in cell %s (status: %d).\n", progname,
! error_message(status), username, cell_to_use,
status);
} else {
printf("created cross-cell entry for %s (Id %d) at %s\n",
--- 899,905 ----
if ((status = pr_CreateUser(username, &id))) {
fprintf(stderr, "%s: %s so unable to create remote PTS "
"user %s in cell %s (status: %d).\n", progname,
! afs_error_message(status), username, cell_to_use,
status);
} else {
printf("created cross-cell entry for %s (Id %d) at %s\n",
***************
*** 1225,1231 ****
"[-d] [[-cell | -c] cell [-k krb_realm]] ",
"[[-p | -path] pathname]\n",
" [-zsubs] [-hosts] [-noauth] [-noprdb] [-force] [-setpag] \n"
! " [-linked] [-524]\n");
fprintf(stderr, " -d gives debugging information.\n");
fprintf(stderr, " krb_realm is the kerberos realm of a cell.\n");
fprintf(stderr, " pathname is the name of a directory to which ");
--- 1312,1322 ----
"[-d] [[-cell | -c] cell [-k krb_realm]] ",
"[[-p | -path] pathname]\n",
" [-zsubs] [-hosts] [-noauth] [-noprdb] [-force] [-setpag] \n"
! " [-linked]"
! #ifndef HAVE_NO_KRB5_524
! " [-524]"
! #endif
! "\n");
fprintf(stderr, " -d gives debugging information.\n");
fprintf(stderr, " krb_realm is the kerberos realm of a cell.\n");
fprintf(stderr, " pathname is the name of a directory to which ");
***************
*** 1237,1243 ****
--- 1328,1336 ----
fprintf(stderr, " -force means replace identical tickets. \n");
fprintf(stderr, " -linked means if AFS node is linked, try both. \n");
fprintf(stderr, " -setpag set the AFS process authentication group.\n");
+ #ifndef HAVE_NO_KRB5_524
fprintf(stderr, " -524 means use the 524 converter instead of V5 directly\n");
+ #endif
fprintf(stderr, " No commandline arguments means ");
fprintf(stderr, "authenticate to the local cell.\n");
fprintf(stderr, "\n");
***************
*** 1310,1317 ****
--- 1403,1412 ----
linked++;
else if (strcmp(argv[i], "-force") == 0)
force++;
+ #ifndef HAVE_NO_KRB5_524
else if (strcmp(argv[i], "-524") == 0)
do524++;
+ #endif
else if (strcmp(argv[i], "-setpag") == 0)
afssetpag++;
else if (((strcmp(argv[i], "-cell") == 0) ||
***************
*** 1322,1327 ****
--- 1417,1434 ----
}
else
usage();
+ else if ((strcmp(argv[i], "-keytab") == 0))
+ if (++i < argc) {
+ keytab = argv[i];
+ }
+ else
+ usage();
+ else if ((strcmp(argv[i], "-principal") == 0))
+ if (++i < argc) {
+ client = argv[i];
+ }
+ else
+ usage();
else if (((strcmp(argv[i], "-path") == 0) ||
(strcmp(argv[i], "-p") == 0)) && !cmode)
#ifndef WINDOWS
***************
*** 1394,1401 ****
else if (pmode) {
/* Add this path to list of paths */
if ((cur_node = ll_add_node(&paths, ll_tail))) {
! char *new_path;
! if ((new_path = copy_string(path)))
ll_add_data(cur_node, new_path);
else {
fprintf(stderr, "%s: failure copying path name.\n",
--- 1501,1508 ----
else if (pmode) {
/* Add this path to list of paths */
if ((cur_node = ll_add_node(&paths, ll_tail))) {
! char *new_path;
! if ((new_path = strdup(path)))
ll_add_data(cur_node, new_path);
else {
fprintf(stderr, "%s: failure copying path name.\n",
***************
*** 1558,1580 ****
exit(status);
}
- #ifndef HAVE_ADD_TO_ERROR_TABLE
-
- #define error_table error_table_compat
- #include
- #undef error_table
-
- #ifndef HAVE_ADD_ERROR_TABLE
- void add_error_table (const struct error_table *);
- #endif /* !HAVE_ADD_ERROR_TABLE */
-
- void
- add_to_error_table(struct et_list *new_table)
- {
- add_error_table((struct error_table *) new_table->table);
- }
- #endif /* HAVE_ADD_TO_ERROR_TABLE */
-
static int isdir(char *path, unsigned char *val)
{
struct stat statbuf;
--- 1665,1670 ----
***************
*** 1590,1612 ****
}
}
static krb5_error_code get_credv5(krb5_context context,
! char *name, char *inst, char *realm,
! krb5_creds **creds)
{
krb5_creds increds;
krb5_error_code r;
static krb5_principal client_principal = 0;
!
memset((char *)&increds, 0, sizeof(increds));
/* ANL - instance may be ptr to a null string. Pass null then */
if ((r = krb5_build_principal(context, &increds.server,
! strlen(realm), realm,
! name,
! (inst && strlen(inst)) ? inst : (void *) NULL,
! (void *) NULL))) {
return r;
}
if (!_krb425_ccache) {
r = krb5_cc_default(context, &_krb425_ccache);
--- 1680,2024 ----
}
}
+ static krb5_error_code get_credv5_akimpersonate(krb5_context context,
+ char* keytab,
+ krb5_principal service_principal,
+ krb5_principal client_principal,
+ time_t starttime,
+ time_t endtime,
+ int *allowed_enctypes,
+ int *paddress,
+ krb5_creds** out_creds /* out */ )
+ {
+ #if defined(USING_HEIMDAL) || (defined(HAVE_ENCODE_KRB5_ENC_TKT) && defined(HAVE_ENCODE_KRB5_TICKET))
+ krb5_error_code code;
+ krb5_keytab kt = 0;
+ krb5_kt_cursor cursor[1];
+ krb5_keytab_entry entry[1];
+ krb5_ccache cc = 0;
+ krb5_creds *creds = 0;
+ krb5_enctype enctype;
+ krb5_kvno kvno;
+ krb5_keyblock session_key[1];
+ #if USING_HEIMDAL
+ Ticket ticket_reply[1];
+ EncTicketPart enc_tkt_reply[1];
+ krb5_address address[30];
+ krb5_addresses faddr[1];
+ int temp_vno[1];
+ time_t temp_time[2];
+ #else
+ krb5_ticket ticket_reply[1];
+ krb5_enc_tkt_part enc_tkt_reply[1];
+ krb5_address address[30], *faddr[30];
+ #endif
+ krb5_data * temp;
+ int i;
+ static int any_enctype[] = {0};
+ *out_creds = 0;
+ if (!(creds = malloc(sizeof *creds))) {
+ code = ENOMEM;
+ goto cleanup;
+ }
+ if (!allowed_enctypes)
+ allowed_enctypes = any_enctype;
+
+ cc = 0;
+ enctype = 0; /* AKIMPERSONATE_IGNORE_ENCTYPE */
+ kvno = 0; /* AKIMPERSONATE_IGNORE_VNO */
+ memset((char*)creds, 0, sizeof *creds);
+ memset((char*)entry, 0, sizeof *entry);
+ memset((char*)session_key, 0, sizeof *session_key);
+ memset((char*)ticket_reply, 0, sizeof *ticket_reply);
+ memset((char*)enc_tkt_reply, 0, sizeof *enc_tkt_reply);
+ code = krb5_kt_resolve(context, keytab, &kt);
+ if (code) {
+ if (keytab)
+ com_err(progname, code, "while resolving keytab %s", keytab);
+ else
+ com_err(progname, code, "while resolving default keytab");
+ goto cleanup;
+ }
+
+ if (service_principal) {
+ for (i = 0; (enctype = allowed_enctypes[i]) || !i; ++i) {
+ code = krb5_kt_get_entry(context,
+ kt,
+ service_principal,
+ kvno,
+ enctype,
+ entry);
+ if (!code) {
+ if (allowed_enctypes[i])
+ deref_keyblock_enctype(session_key) = allowed_enctypes[i];
+ break;
+ }
+ }
+ if (code) {
+ com_err(progname, code,"while scanning keytab entries");
+ goto cleanup;
+ }
+ } else {
+ krb5_keytab_entry new[1];
+ int best = -1;
+ memset(new, 0, sizeof *new);
+ if ((code == krb5_kt_start_seq_get(context, kt, cursor))) {
+ com_err(progname, code, "while starting keytab scan");
+ goto cleanup;
+ }
+ while (!(code = krb5_kt_next_entry(context, kt, new, cursor))) {
+ for (i = 0;
+ allowed_enctypes[i] && allowed_enctypes[i]
+ != deref_entry_enctype(new); ++i)
+ ;
+ if ((!i || allowed_enctypes[i]) &&
+ (best < 0 || best > i)) {
+ krb5_free_keytab_entry_contents(context, entry);
+ *entry = *new;
+ memset(new, 0, sizeof *new);
+ } else krb5_free_keytab_entry_contents(context, new);
+ }
+ if ((i = krb5_kt_end_seq_get(context, kt, cursor))) {
+ com_err(progname, i, "while ending keytab scan");
+ code = i;
+ goto cleanup;
+ }
+ if (best < 0) {
+ com_err(progname, code, "while scanning keytab");
+ goto cleanup;
+ }
+ deref_keyblock_enctype(session_key) = deref_entry_enctype(entry);
+ }
+
+ /* Make Ticket */
+
+ #if USING_HEIMDAL
+ if ((code = krb5_generate_random_keyblock(context,
+ deref_keyblock_enctype(session_key), session_key))) {
+ com_err(progname, code, "while making session key");
+ goto cleanup;
+ }
+ enc_tkt_reply->flags.initial = 1;
+ enc_tkt_reply->transited.tr_type = DOMAIN_X500_COMPRESS;
+ enc_tkt_reply->cname = client_principal->name;
+ enc_tkt_reply->crealm = client_principal->realm;
+ enc_tkt_reply->key = *session_key;
+ {
+ static krb5_data empty_string;
+ enc_tkt_reply->transited.contents = empty_string;
+ }
+ enc_tkt_reply->authtime = starttime;
+ enc_tkt_reply->starttime = temp_time;
+ *enc_tkt_reply->starttime = starttime;
+ #if 0
+ enc_tkt_reply->renew_till = temp_time + 1;
+ *enc_tkt_reply->renew_till = endtime;
+ #endif
+ enc_tkt_reply->endtime = endtime;
+ #else
+ if ((code = krb5_c_make_random_key(context,
+ deref_keyblock_enctype(session_key), session_key))) {
+ com_err(progname, code, "while making session key");
+ goto cleanup;
+ }
+ enc_tkt_reply->magic = KV5M_ENC_TKT_PART;
+ #define DATACAST (unsigned char *)
+ enc_tkt_reply->flags |= TKT_FLG_INITIAL;
+ enc_tkt_reply->transited.tr_type = KRB5_DOMAIN_X500_COMPRESS;
+ enc_tkt_reply->session = session_key;
+ enc_tkt_reply->client = client_principal;
+ {
+ static krb5_data empty_string;
+ enc_tkt_reply->transited.tr_contents = empty_string;
+ }
+ enc_tkt_reply->times.authtime = starttime;
+ enc_tkt_reply->times.starttime = starttime; /* krb524init needs this */
+ enc_tkt_reply->times.endtime = endtime;
+ #endif /* USING_HEIMDAL */
+ /* NB: We will discard address for now--ignoring caddr field
+ in any case. MIT branch does what it always did. */
+
+ if (paddress && *paddress) {
+ deref_enc_tkt_addrs(enc_tkt_reply) = faddr;
+ #if USING_HEIMDAL
+ faddr->len = 0;
+ faddr->val = address;
+ #endif
+ for (i = 0; paddress[i]; ++i) {
+ #if USING_HEIMDAL
+ address[i].addr_type = KRB5_ADDRESS_INET;
+ address[i].address.data = (void*)(paddress+i);
+ address[i].address.length = sizeof(paddress[i]);
+ #else
+ #if !USING_SSL
+ address[i].magic = KV5M_ADDRESS;
+ address[i].addrtype = ADDRTYPE_INET;
+ #else
+ address[i].addrtype = AF_INET;
+ #endif
+ address[i].contents = (void*)(paddress+i);
+ address[i].length = sizeof(int);
+ faddr[i] = address+i;
+ #endif
+ }
+ #if USING_HEIMDAL
+ faddr->len = i;
+ #else
+ faddr[i] = 0;
+ #endif
+ }
+
+ #if USING_HEIMDAL
+ ticket_reply->sname = service_principal->name;
+ ticket_reply->realm = service_principal->realm;
+
+ { /* crypto block */
+ krb5_crypto crypto = 0;
+ unsigned char *buf = 0;
+ size_t buf_size, buf_len;
+ char *what;
+
+ ASN1_MALLOC_ENCODE(EncTicketPart, buf, buf_size,
+ enc_tkt_reply, &buf_len, code);
+ if(code) {
+ com_err(progname, code, "while encoding ticket");
+ goto cleanup;
+ }
+
+ if(buf_len != buf_size) {
+ com_err(progname, code,
+ "%d != %d while encoding ticket (internal ASN.1 encoder error",
+ buf_len, buf_size);
+ goto cleanup;
+ }
+ what = "krb5_crypto_init";
+ code = krb5_crypto_init(context,
+ &deref_entry_keyblock(entry),
+ deref_entry_enctype(entry),
+ &crypto);
+ if(!code) {
+ what = "krb5_encrypt";
+ code = krb5_encrypt_EncryptedData(context, crypto, KRB5_KU_TICKET,
+ buf, buf_len, entry->vno, &(ticket_reply->enc_part));
+ }
+ if (buf) free(buf);
+ if (crypto) krb5_crypto_destroy(context, crypto);
+ if(code) {
+ com_err(progname, code, "while %s", what);
+ goto cleanup;
+ }
+ } /* crypto block */
+ ticket_reply->enc_part.etype = deref_entry_enctype(entry);
+ ticket_reply->enc_part.kvno = temp_vno;
+ *ticket_reply->enc_part.kvno = entry->vno;
+ ticket_reply->tkt_vno = 5;
+ #else
+ ticket_reply->server = service_principal;
+ ticket_reply->enc_part2 = enc_tkt_reply;
+ if ((code = krb5_encrypt_tkt_part(context, &deref_entry_keyblock(entry), ticket_reply))) {
+ com_err(progname, code, "while making ticket");
+ goto cleanup;
+ }
+ ticket_reply->enc_part.kvno = entry->vno;
+ #endif
+
+ /* Construct Creds */
+
+ if ((code = krb5_copy_principal(context, service_principal,
+ &creds->server))) {
+ com_err(progname, code, "while copying service principal");
+ goto cleanup;
+ }
+ if ((code = krb5_copy_principal(context, client_principal,
+ &creds->client))) {
+ com_err(progname, code, "while copying client principal");
+ goto cleanup;
+ }
+ if ((code = krb5_copy_keyblock_contents(context, session_key,
+ &deref_session_key(creds)))) {
+ com_err(progname, code, "while copying session key");
+ goto cleanup;
+ }
+
+ #if USING_HEIMDAL
+ creds->times.authtime = enc_tkt_reply->authtime;
+ creds->times.starttime = *(enc_tkt_reply->starttime);
+ creds->times.endtime = enc_tkt_reply->endtime;
+ creds->times.renew_till = 0; /* *(enc_tkt_reply->renew_till) */
+ creds->flags.b = enc_tkt_reply->flags;
+ #else
+ creds->times = enc_tkt_reply->times;
+ creds->ticket_flags = enc_tkt_reply->flags;
+ #endif
+ if (!deref_enc_tkt_addrs(enc_tkt_reply))
+ ;
+ else if ((code = krb5_copy_addresses(context,
+ deref_enc_tkt_addrs(enc_tkt_reply), &creds->addresses))) {
+ com_err(progname, code, "while copying addresses");
+ goto cleanup;
+ }
+
+ #if USING_HEIMDAL
+ {
+ size_t creds_tkt_len;
+ ASN1_MALLOC_ENCODE(Ticket, creds->ticket.data, creds->ticket.length,
+ ticket_reply, &creds_tkt_len, code);
+ if(code) {
+ com_err(progname, code, "while encoding ticket");
+ goto cleanup;
+ }
+ }
+ #else
+ if ((code = encode_krb5_ticket(ticket_reply, &temp))) {
+ com_err(progname, code, "while encoding ticket");
+ goto cleanup;
+ }
+ creds->ticket = *temp;
+ free(temp);
+ #endif
+ /* return creds */
+ *out_creds = creds;
+ creds = 0;
+ cleanup:
+ if (deref_enc_data(&ticket_reply->enc_part))
+ free(deref_enc_data(&ticket_reply->enc_part));
+ krb5_free_keytab_entry_contents(context, entry);
+ if (client_principal)
+ krb5_free_principal(context, client_principal);
+ if (service_principal)
+ krb5_free_principal(context, service_principal);
+ if (cc)
+ krb5_cc_close(context, cc);
+ if (kt)
+ krb5_kt_close(context, kt);
+ if (creds) krb5_free_creds(context, creds);
+ krb5_free_keyblock_contents(context, session_key);
+ out:
+ return code;
+ #else
+ return -1;
+ #endif
+ }
+
+
static krb5_error_code get_credv5(krb5_context context,
! char *name, char *inst, char *realm,
! krb5_creds **creds)
{
krb5_creds increds;
krb5_error_code r;
static krb5_principal client_principal = 0;
!
memset((char *)&increds, 0, sizeof(increds));
/* ANL - instance may be ptr to a null string. Pass null then */
if ((r = krb5_build_principal(context, &increds.server,
! strlen(realm), realm,
! name,
! (inst && strlen(inst)) ? inst : (void *) NULL,
! (void *) NULL))) {
return r;
}
+
if (!_krb425_ccache) {
r = krb5_cc_default(context, &_krb425_ccache);
***************
*** 1614,1631 ****
return r;
}
if (!client_principal) {
! r = krb5_cc_get_principal(context, _krb425_ccache, &client_principal);
if (r)
return r;
}
!
increds.client = client_principal;
increds.times.endtime = 0;
! /* Ask for DES since that is what V4 understands */
get_creds_enctype((&increds)) = ENCTYPE_DES_CBC_CRC;
!
! r = krb5_get_credentials(context, 0, _krb425_ccache, &increds, creds);
!
return r;
}
--- 2026,2061 ----
return r;
}
if (!client_principal) {
! if (client) {
! r = krb5_parse_name(context, client, &client_principal);
! } else {
! r = krb5_cc_get_principal(context, _krb425_ccache, &client_principal);
! }
if (r)
return r;
}
!
increds.client = client_principal;
increds.times.endtime = 0;
! /* Ask for DES since that is what V4 understands */
get_creds_enctype((&increds)) = ENCTYPE_DES_CBC_CRC;
!
! if (keytab) {
! int allowed_enctypes[] = {
! ENCTYPE_DES_CBC_CRC, 0
! };
!
! r = get_credv5_akimpersonate(context,
! keytab,
! increds.server,
! increds.client,
! 300, ((~0U)>>1),
! allowed_enctypes,
! 0 /* paddress */,
! creds /* out */);
! } else {
! r = krb5_get_credentials(context, 0, _krb425_ccache, &increds, creds);
! }
return r;
}
***************
*** 1634,1649 ****
{
static krb5_principal client_principal = 0;
int i;
if (!_krb425_ccache)
krb5_cc_default(context, &_krb425_ccache);
! if (!client_principal)
! krb5_cc_get_principal(context, _krb425_ccache, &client_principal);
i = realm_len(context, client_principal);
if (i > REALM_SZ-1) i = REALM_SZ-1;
strncpy(realm,realm_data(context, client_principal), i);
realm[i] = 0;
! return(0);
}
--- 2064,2087 ----
{
static krb5_principal client_principal = 0;
int i;
+ krb5_error_code r = 0;
if (!_krb425_ccache)
krb5_cc_default(context, &_krb425_ccache);
! if (!client_principal) {
! if (client) {
! r = krb5_parse_name(context, client, &client_principal);
! } else {
! r = krb5_cc_get_principal(context, _krb425_ccache, &client_principal);
! }
! if (r)
! return r;
! }
i = realm_len(context, client_principal);
if (i > REALM_SZ-1) i = REALM_SZ-1;
strncpy(realm,realm_data(context, client_principal), i);
realm[i] = 0;
! return(r);
}
Index: openafs/src/aklog/asetkey.c
diff -c openafs/src/aklog/asetkey.c:1.4.2.6 openafs/src/aklog/asetkey.c:1.4.2.7
*** openafs/src/aklog/asetkey.c:1.4.2.6 Thu Jan 4 22:22:00 2007
--- openafs/src/aklog/asetkey.c Tue Apr 10 14:43:40 2007
***************
*** 1,5 ****
/*
! * $Id: asetkey.c,v 1.4.2.6 2007/01/05 03:22:00 shadow Exp $
*
* asetkey - Manipulates an AFS KeyFile
*
--- 1,5 ----
/*
! * $Id: asetkey.c,v 1.4.2.7 2007/04/10 18:43:40 shadow Exp $
*
* asetkey - Manipulates an AFS KeyFile
*
***************
*** 85,97 ****
kvno = atoi(argv[2]);
retval = krb5_parse_name(context, argv[4], &principal);
if (retval != 0) {
! com_err(argv[0], retval, "while parsing AFS principal");
exit(1);
}
retval = krb5_kt_read_service_key(context, argv[3], principal, kvno,
ENCTYPE_DES_CBC_CRC, &key);
if (retval != 0) {
! com_err(argv[0], retval, "while extracting AFS service key");
exit(1);
}
--- 85,97 ----
kvno = atoi(argv[2]);
retval = krb5_parse_name(context, argv[4], &principal);
if (retval != 0) {
! afs_com_err(argv[0], retval, "while parsing AFS principal");
exit(1);
}
retval = krb5_kt_read_service_key(context, argv[3], principal, kvno,
ENCTYPE_DES_CBC_CRC, &key);
if (retval != 0) {
! afs_com_err(argv[0], retval, "while extracting AFS service key");
exit(1);
}
Index: openafs/src/auth/ktc.c
diff -c openafs/src/auth/ktc.c:1.15.2.6 openafs/src/auth/ktc.c:1.15.2.7
*** openafs/src/auth/ktc.c:1.15.2.6 Fri Oct 6 08:44:40 2006
--- openafs/src/auth/ktc.c Thu Aug 9 10:59:54 2007
***************
*** 17,23 ****
#endif
RCSID
! ("$Header: /cvs/openafs/src/auth/ktc.c,v 1.15.2.6 2006/10/06 12:44:40 shadow Exp $");
#if defined(UKERNEL)
#include "afs/sysincludes.h"
--- 17,23 ----
#endif
RCSID
! ("$Header: /cvs/openafs/src/auth/ktc.c,v 1.15.2.7 2007/08/09 14:59:54 shadow Exp $");
#if defined(UKERNEL)
#include "afs/sysincludes.h"
***************
*** 1163,1168 ****
--- 1163,1169 ----
{
int k_errno;
int kvno, lifetime;
+ long mit_compat; /* MIT Kerberos 5 with Krb4 uses a "long" for issue_date */
if (fd < 0) {
return TKT_FIL_INI;
***************
*** 1199,1208 ****
/* don't try to read a silly amount into ticket->dat */
token->ticketLen > MAXKTCTICKETLEN
|| tf_read((char *)(token->ticket), token->ticketLen) < 1
! || tf_read((char *)&(token->startTime),
! sizeof(token->startTime)) < 1) {
return TKT_FIL_FMT;
}
token->endTime = life_to_time(token->startTime, lifetime);
token->kvno = kvno;
return 0;
--- 1200,1209 ----
/* don't try to read a silly amount into ticket->dat */
token->ticketLen > MAXKTCTICKETLEN
|| tf_read((char *)(token->ticket), token->ticketLen) < 1
! || tf_read((char *)&mit_compat, sizeof(mit_compat)) < 1) {
return TKT_FIL_FMT;
}
+ token->startTime = mit_compat;
token->endTime = life_to_time(token->startTime, lifetime);
token->kvno = kvno;
return 0;
***************
*** 1330,1335 ****
--- 1331,1337 ----
off_t start;
int lifetime, kvno;
int count; /* count for write */
+ long mit_compat; /* MIT Kerberos 5 with Krb4 uses a "long" for issue_date */
if (fd < 0) { /* fd is ticket file as set by afs_tf_init */
return TKT_FIL_INI;
***************
*** 1399,1406 ****
if (write(fd, atoken->ticket, count) != count)
goto bad;
/* Issue date */
! if (write(fd, (char *)&atoken->startTime, sizeof(afs_int32))
! != sizeof(afs_int32))
goto bad;
/* Actually, we should check each write for success */
--- 1401,1409 ----
if (write(fd, atoken->ticket, count) != count)
goto bad;
/* Issue date */
! mit_compat = atoken->startTime;
! if (write(fd, (char *)&mit_compat, sizeof(mit_compat))
! != sizeof(mit_compat))
goto bad;
/* Actually, we should check each write for success */
Index: openafs/src/bozo/bos.c
diff -c openafs/src/bozo/bos.c:1.20.2.2 openafs/src/bozo/bos.c:1.20.2.3
*** openafs/src/bozo/bos.c:1.20.2.2 Mon Oct 18 13:43:53 2004
--- openafs/src/bozo/bos.c Tue Apr 10 14:43:40 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bozo/bos.c,v 1.20.2.2 2004/10/18 17:43:53 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bozo/bos.c,v 1.20.2.3 2007/04/10 18:43:40 shadow Exp $");
#include
#include
***************
*** 93,99 ****
else if (acode == -3)
return "communications timeout (-3)";
else
! return (char *)error_message(acode);
}
/* get partition id from a name */
--- 93,99 ----
else if (acode == -3)
return "communications timeout (-3)";
else
! return (char *)afs_error_message(acode);
}
/* get partition id from a name */
***************
*** 204,210 ****
* local cell */
code = afsconf_GetCellInfo(tdir, tname, NULL, &info);
if (code) {
! com_err("bos", code, "(can't find cell '%s' in cell database)",
(tname ? tname : ""));
exit(1);
} else
--- 204,210 ----
* local cell */
code = afsconf_GetCellInfo(tdir, tname, NULL, &info);
if (code) {
! afs_com_err("bos", code, "(can't find cell '%s' in cell database)",
(tname ? tname : ""));
exit(1);
} else
***************
*** 224,237 ****
if (as->parms[ADDPARMOFFSET + 2].items) { /* -localauth */
code = afsconf_GetLatestKey(tdir, 0, 0);
if (code)
! com_err("bos", code, "(getting key from local KeyFile)");
else {
if (aencrypt)
code = afsconf_ClientAuthSecure(tdir, &sc[2], &scIndex);
else
code = afsconf_ClientAuth(tdir, &sc[2], &scIndex);
if (code)
! com_err("bos", code, "(calling ClientAuth)");
else if (scIndex != 2) /* this shouldn't happen */
sc[scIndex] = sc[2];
}
--- 224,237 ----
if (as->parms[ADDPARMOFFSET + 2].items) { /* -localauth */
code = afsconf_GetLatestKey(tdir, 0, 0);
if (code)
! afs_com_err("bos", code, "(getting key from local KeyFile)");
else {
if (aencrypt)
code = afsconf_ClientAuthSecure(tdir, &sc[2], &scIndex);
else
code = afsconf_ClientAuth(tdir, &sc[2], &scIndex);
if (code)
! afs_com_err("bos", code, "(calling ClientAuth)");
else if (scIndex != 2) /* this shouldn't happen */
sc[scIndex] = sc[2];
}
***************
*** 258,264 ****
ttoken.ticket);
scIndex = 2;
} else
! com_err("bos", code, "(getting tickets)");
}
if ((scIndex == 0) || (sc[scIndex] == 0)) {
fprintf(stderr, "bos: running unauthenticated\n");
--- 258,264 ----
ttoken.ticket);
scIndex = 2;
} else
! afs_com_err("bos", code, "(getting tickets)");
}
if ((scIndex == 0) || (sc[scIndex] == 0)) {
fprintf(stderr, "bos: running unauthenticated\n");
***************
*** 300,306 ****
}
code = BOZO_SetNoAuthFlag(tconn, flag);
if (code)
! com_err("bos", code, "(failed to set authentication flag)");
return 0;
}
--- 300,306 ----
}
code = BOZO_SetNoAuthFlag(tconn, flag);
if (code)
! afs_com_err("bos", code, "(failed to set authentication flag)");
return 0;
}
***************
*** 368,374 ****
flags |= 0xff;
code = BOZO_Prune(tconn, flags);
if (code)
! com_err("bos", code, "(failed to prune server files)");
return code;
}
--- 368,374 ----
flags |= 0xff;
code = BOZO_Prune(tconn, flags);
if (code)
! afs_com_err("bos", code, "(failed to prune server files)");
return code;
}
***************
*** 1467,1473 ****
done:
if (code)
! com_err("bos", code, "(while reading log)");
return code;
}
--- 1467,1473 ----
done:
if (code)
! afs_com_err("bos", code, "(while reading log)");
return code;
}
Index: openafs/src/bozo/bosserver.c
diff -c openafs/src/bozo/bosserver.c:1.23.2.10 openafs/src/bozo/bosserver.c:1.23.2.11
*** openafs/src/bozo/bosserver.c:1.23.2.10 Thu Dec 21 18:15:35 2006
--- openafs/src/bozo/bosserver.c Mon May 14 15:27:49 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bozo/bosserver.c,v 1.23.2.10 2006/12/21 23:15:35 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bozo/bosserver.c,v 1.23.2.11 2007/05/14 19:27:49 shadow Exp $");
#include
#include
***************
*** 1100,1111 ****
fprintf(bozo_logFile, "%s ", tdate);
fprintf(bozo_logFile, a, b, c, d, e, f);
fflush(bozo_logFile);
} else {
printf("%s ", tdate);
printf(a, b, c, d, e, f);
}
-
- /* close so rm BosLog works */
- fclose(bozo_logFile);
}
}
--- 1100,1110 ----
fprintf(bozo_logFile, "%s ", tdate);
fprintf(bozo_logFile, a, b, c, d, e, f);
fflush(bozo_logFile);
+ /* close so rm BosLog works */
+ fclose(bozo_logFile);
} else {
printf("%s ", tdate);
printf(a, b, c, d, e, f);
}
}
}
Index: openafs/src/bucoord/bc_status.c
diff -c openafs/src/bucoord/bc_status.c:1.11.2.1 openafs/src/bucoord/bc_status.c:1.11.2.2
*** openafs/src/bucoord/bc_status.c:1.11.2.1 Thu Jan 4 22:34:08 2007
--- openafs/src/bucoord/bc_status.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/bc_status.c,v 1.11.2.1 2007/01/05 03:34:08 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/bc_status.c,v 1.11.2.2 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 119,125 ****
code = cmd_ParseLine(internalCmdLine, targv, &targc, MAXV);
if (code) {
! printf("Couldn't parse line: '%s'", error_message(code));
return (1);
}
free(internalCmdLine);
--- 119,125 ----
code = cmd_ParseLine(internalCmdLine, targv, &targc, MAXV);
if (code) {
! printf("Couldn't parse line: '%s'", afs_error_message(code));
return (1);
}
free(internalCmdLine);
***************
*** 267,274 ****
if (localTaskFlags & ABORT_REQUEST) {
code = TC_RequestAbort(tconn, taskId);
if (code) {
! com_err("statusWatcher", code, "; Can't post abort request");
! com_err("statusWatcher", 0, "...Deleting job");
if (localTaskFlags & NOREMOVE) {
curPollPtr->flags |= (STARTING | TASK_ERROR);
curPollPtr->scheduledDump = 0;
--- 267,274 ----
if (localTaskFlags & ABORT_REQUEST) {
code = TC_RequestAbort(tconn, taskId);
if (code) {
! afs_com_err("statusWatcher", code, "; Can't post abort request");
! afs_com_err("statusWatcher", 0, "...Deleting job");
if (localTaskFlags & NOREMOVE) {
curPollPtr->flags |= (STARTING | TASK_ERROR);
curPollPtr->scheduledDump = 0;
Index: openafs/src/bucoord/commands.c
diff -c openafs/src/bucoord/commands.c:1.14.2.7 openafs/src/bucoord/commands.c:1.14.2.9
*** openafs/src/bucoord/commands.c:1.14.2.7 Thu Jan 4 22:34:08 2007
--- openafs/src/bucoord/commands.c Sat Jun 23 11:27:22 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/commands.c,v 1.14.2.7 2007/01/05 03:34:08 shadow Exp $");
#include
#if defined(AFS_LINUX24_ENV)
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/commands.c,v 1.14.2.9 2007/06/23 15:27:22 shadow Exp $");
#include
#if defined(AFS_LINUX24_ENV)
***************
*** 119,125 ****
if (!(*ss)) {
*ss = (struct serversort *)malloc(sizeof(struct serversort));
if (!(*ss)) {
! com_err(whoami, BC_NOMEM, "");
*ss = 0;
return (BC_NOMEM);
}
--- 119,125 ----
if (!(*ss)) {
*ss = (struct serversort *)malloc(sizeof(struct serversort));
if (!(*ss)) {
! afs_com_err(whoami, BC_NOMEM, "");
*ss = 0;
return (BC_NOMEM);
}
***************
*** 140,146 ****
if (!(*ps)) {
*ps = (struct partitionsort *)malloc(sizeof(struct partitionsort));
if (!(*ps)) {
! com_err(whoami, BC_NOMEM, "");
free(*ss);
*ps = 0;
*ss = 0;
--- 140,146 ----
if (!(*ps)) {
*ps = (struct partitionsort *)malloc(sizeof(struct partitionsort));
if (!(*ps)) {
! afs_com_err(whoami, BC_NOMEM, "");
free(*ss);
*ps = 0;
*ss = 0;
***************
*** 287,293 ****
entries[e].serverPartition[ei], &servers,
&ss, &ps);
if (tcode) {
! com_err(whoami, tcode, "");
ERROR(tcode);
}
--- 287,293 ----
entries[e].serverPartition[ei], &servers,
&ss, &ps);
if (tcode) {
! afs_com_err(whoami, tcode, "");
ERROR(tcode);
}
***************
*** 319,332 ****
tvd = (struct bc_volumeDump *)
malloc(sizeof(struct bc_volumeDump));
if (!tvd) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(tvd, 0, sizeof(*tvd));
tvd->name = (char *)malloc(strlen(entries[e].name) + 10);
if (!(tvd->name)) {
! com_err(whoami, BC_NOMEM, "");
free(tvd);
ERROR(BC_NOMEM);
}
--- 319,332 ----
tvd = (struct bc_volumeDump *)
malloc(sizeof(struct bc_volumeDump));
if (!tvd) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(tvd, 0, sizeof(*tvd));
tvd->name = (char *)malloc(strlen(entries[e].name) + 10);
if (!(tvd->name)) {
! afs_com_err(whoami, BC_NOMEM, "");
free(tvd);
ERROR(BC_NOMEM);
}
***************
*** 489,495 ****
sprintf(patt, "^%s$", tve->name);
errm = (char *)re_comp(patt);
if (errm) {
! com_err(whoami, 0,
"Can't compile regular expression '%s': %s",
patt, errm);
return (-1);
--- 489,495 ----
sprintf(patt, "^%s$", tve->name);
errm = (char *)re_comp(patt);
if (errm) {
! afs_com_err(whoami, 0,
"Can't compile regular expression '%s': %s",
patt, errm);
return (-1);
***************
*** 543,549 ****
}
if (code < 0)
! com_err(whoami, 0, "Internal error in regex package");
} /*s */
/* If found a match, then create a new volume dump entry */
--- 543,549 ----
}
if (code < 0)
! afs_com_err(whoami, 0, "Internal error in regex package");
} /*s */
/* If found a match, then create a new volume dump entry */
***************
*** 554,560 ****
entry.serverPartition[foundentry], &servers,
&ss, &ps);
if (code) {
! com_err(whoami, code, "");
return (code);
}
--- 554,560 ----
entry.serverPartition[foundentry], &servers,
&ss, &ps);
if (code) {
! afs_com_err(whoami, code, "");
return (code);
}
***************
*** 562,575 ****
tvd = (struct bc_volumeDump *)
malloc(sizeof(struct bc_volumeDump));
if (!tvd) {
! com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(tvd, 0, sizeof(*tvd));
tvd->name = (char *)malloc(strlen(entry.name) + 10);
if (!(tvd->name)) {
! com_err(whoami, BC_NOMEM, "");
free(tvd);
return (BC_NOMEM);
}
--- 562,575 ----
tvd = (struct bc_volumeDump *)
malloc(sizeof(struct bc_volumeDump));
if (!tvd) {
! afs_com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(tvd, 0, sizeof(*tvd));
tvd->name = (char *)malloc(strlen(entry.name) + 10);
if (!(tvd->name)) {
! afs_com_err(whoami, BC_NOMEM, "");
free(tvd);
return (BC_NOMEM);
}
***************
*** 712,718 ****
tlen = strlen(astring);
tp = (char *)malloc(tlen + 1); /* don't forget the terminating null */
if (!tp) {
! com_err(whoami, BC_NOMEM, "");
return (tp);
}
strcpy(tp, astring);
--- 712,718 ----
tlen = strlen(astring);
tp = (char *)malloc(tlen + 1); /* don't forget the terminating null */
if (!tp) {
! afs_com_err(whoami, BC_NOMEM, "");
return (tp);
}
strcpy(tp, astring);
***************
*** 740,752 ****
}
if (length == 0) { /* no string (0 length) */
! com_err(whoami, 0, "Can't have zero length date and time string");
return (NULL);
}
string = (char *)malloc(length); /* allocate the string */
if (!string) {
! com_err(whoami, BC_NOMEM, "");
return (NULL);
}
string[0] = 0;
--- 740,752 ----
}
if (length == 0) { /* no string (0 length) */
! afs_com_err(whoami, 0, "Can't have zero length date and time string");
return (NULL);
}
string = (char *)malloc(length); /* allocate the string */
if (!string) {
! afs_com_err(whoami, BC_NOMEM, "");
return (NULL);
}
string[0] = 0;
***************
*** 809,818 ****
portOffset = bc_SafeATOI(port);
if (portOffset < 0) {
! com_err(whoami, 0, "Can't decode port offset '%s'", port);
return (-1);
} else if (portOffset > BC_MAXPORTOFFSET) {
! com_err(whoami, 0, "%u exceeds max port offset %u", portOffset,
BC_MAXPORTOFFSET);
return (-1);
}
--- 809,818 ----
portOffset = bc_SafeATOI(port);
if (portOffset < 0) {
! afs_com_err(whoami, 0, "Can't decode port offset '%s'", port);
return (-1);
} else if (portOffset > BC_MAXPORTOFFSET) {
! afs_com_err(whoami, 0, "%u exceeds max port offset %u", portOffset,
BC_MAXPORTOFFSET);
return (-1);
}
***************
*** 838,844 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 838,844 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 861,867 ****
if (code) {
if (code == TC_NOTASKS)
break;
! com_err(whoami, code, "; Can't get status from butc");
return (-1);
}
if ((flags & TSK_STAT_NOTFOUND))
--- 861,867 ----
if (code) {
if (code == TC_NOTASKS)
break;
! afs_com_err(whoami, code, "; Can't get status from butc");
return (-1);
}
if ((flags & TSK_STAT_NOTFOUND))
***************
*** 897,903 ****
extern dlqlinkT statusHead;
! com_err(whoami, 0, "waiting for job termination");
while (usefulJobRunning) {
usefulJobRunning = (dlqEmpty(&statusHead) ? 0 : 1);
--- 897,903 ----
extern dlqlinkT statusHead;
! afs_com_err(whoami, 0, "waiting for job termination");
while (usefulJobRunning) {
usefulJobRunning = (dlqEmpty(&statusHead) ? 0 : 1);
***************
*** 1058,1064 ****
if (strchr(tp, '.') == 0) {
slot = bc_SafeATOI(tp);
if (slot == -1) {
! com_err(whoami, 0, "Bad syntax for number '%s'", tp);
return -1;
}
--- 1058,1064 ----
if (strchr(tp, '.') == 0) {
slot = bc_SafeATOI(tp);
if (slot == -1) {
! afs_com_err(whoami, 0, "Bad syntax for number '%s'", tp);
return -1;
}
***************
*** 1091,1097 ****
}
}
if (i >= BC_MAXSIMDUMPS) {
! com_err(whoami, 0, "Can't find job %s", tp);
return -1;
}
--- 1091,1097 ----
}
}
if (i >= BC_MAXSIMDUMPS) {
! afs_com_err(whoami, 0, "Can't find job %s", tp);
return -1;
}
***************
*** 1099,1105 ****
statusPtr = findStatus(td->dumpID);
if (statusPtr == 0) {
! com_err(whoami, 0, "Can't locate status - internal error");
unlock_Status();
return (-1);
}
--- 1099,1105 ----
statusPtr = findStatus(td->dumpID);
if (statusPtr == 0) {
! afs_com_err(whoami, 0, "Can't locate status - internal error");
unlock_Status();
return (-1);
}
***************
*** 1139,1144 ****
--- 1139,1145 ----
afs_int32 code;
int oldFlag;
afs_int32 fromDate;
+ afs_int32 dumpID = 0;
char *newExt, *timeString;
afs_int32 i;
afs_int32 *ports = NULL;
***************
*** 1147,1153 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 1148,1154 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 1155,1161 ****
if (as->parms[0].items) {
tp = as->parms[0].items->data;
if (bc_ParseHost(tp, &destServ)) {
! com_err(whoami, 0, "Failed to locate destination host '%s'", tp);
return -1;
}
}
--- 1156,1162 ----
if (as->parms[0].items) {
tp = as->parms[0].items->data;
if (bc_ParseHost(tp, &destServ)) {
! afs_com_err(whoami, 0, "Failed to locate destination host '%s'", tp);
return -1;
}
}
***************
*** 1164,1170 ****
if (as->parms[1].items) {
tp = as->parms[1].items->data;
if (bc_GetPartitionID(tp, &destPartition)) {
! com_err(whoami, 0, "Can't parse destination partition '%s'", tp);
return -1;
}
}
--- 1165,1171 ----
if (as->parms[1].items) {
tp = as->parms[1].items->data;
if (bc_GetPartitionID(tp, &destPartition)) {
! afs_com_err(whoami, 0, "Can't parse destination partition '%s'", tp);
return -1;
}
}
***************
*** 1173,1186 ****
/* build list of volume items */
tvol = (struct bc_volumeDump *)malloc(sizeof(struct bc_volumeDump));
if (!tvol) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
memset(tvol, 0, sizeof(struct bc_volumeDump));
tvol->name = (char *)malloc(VOLSER_MAXVOLNAME + 1);
if (!tvol->name) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strncpy(tvol->name, ti->data, VOLSER_OLDMAXVOLNAME);
--- 1174,1187 ----
/* build list of volume items */
tvol = (struct bc_volumeDump *)malloc(sizeof(struct bc_volumeDump));
if (!tvol) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
memset(tvol, 0, sizeof(struct bc_volumeDump));
tvol->name = (char *)malloc(VOLSER_MAXVOLNAME + 1);
if (!tvol->name) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strncpy(tvol->name, ti->data, VOLSER_OLDMAXVOLNAME);
***************
*** 1201,1208 ****
code = ktime_DateToLong(timeString, &fromDate);
free(timeString);
if (code) {
! com_err(whoami, 0, "Can't parse restore date and time");
! com_err(whoami, 0, "%s", ktime_GetDateUsage());
return code;
}
} else {
--- 1202,1209 ----
code = ktime_DateToLong(timeString, &fromDate);
free(timeString);
if (code) {
! afs_com_err(whoami, 0, "Can't parse restore date and time");
! afs_com_err(whoami, 0, "%s", ktime_GetDateUsage());
return code;
}
} else {
***************
*** 1220,1226 ****
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
--- 1221,1227 ----
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
***************
*** 1233,1249 ****
dontExecute = (as->parms[6].items ? 1 : 0); /* -n */
/*
* Perform the call to start the restore.
*/
code =
bc_StartDmpRst(bc_globalConfig, "volume", "restore", volsToRestore,
&destServ, destPartition, fromDate, newExt, oldFlag,
! /*parentDump */ 0, /*dumpLevel */ 0,
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! com_err(whoami, code, "; Failed to queue restore");
return (code);
}
--- 1234,1257 ----
dontExecute = (as->parms[6].items ? 1 : 0); /* -n */
+ if (as->parms[7].items)
+ {
+ dumpID = atoi(as->parms[7].items->data);
+ if (dumpID <= 0)
+ dumpID = 0;
+ }
+
/*
* Perform the call to start the restore.
*/
code =
bc_StartDmpRst(bc_globalConfig, "volume", "restore", volsToRestore,
&destServ, destPartition, fromDate, newExt, oldFlag,
! /*parentDump */ dumpID, /*dumpLevel */ 0,
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! afs_com_err(whoami, code, "; Failed to queue restore");
return (code);
}
***************
*** 1289,1300 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 1297,1308 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 1307,1319 ****
tvolumeEntry.partname = as->parms[1].items->data;
if (bc_GetPartitionID(tvolumeEntry.partname, &tvolumeEntry.partition)) {
! com_err(whoami, 0, "Can't parse partition '%s'",
tvolumeEntry.partname);
return -1;
}
if (bc_ParseHost(tvolumeEntry.serverName, &tvolumeEntry.server)) {
! com_err(whoami, 0, "Can't locate host '%s'", tvolumeEntry.serverName);
return -1;
}
--- 1315,1327 ----
tvolumeEntry.partname = as->parms[1].items->data;
if (bc_GetPartitionID(tvolumeEntry.partname, &tvolumeEntry.partition)) {
! afs_com_err(whoami, 0, "Can't parse partition '%s'",
tvolumeEntry.partname);
return -1;
}
if (bc_ParseHost(tvolumeEntry.serverName, &tvolumeEntry.server)) {
! afs_com_err(whoami, 0, "Can't locate host '%s'", tvolumeEntry.serverName);
return -1;
}
***************
*** 1321,1327 ****
if (as->parms[8].items) {
tp = as->parms[8].items->data;
if (bc_ParseHost(tp, &destServ)) {
! com_err(whoami, 0, "Can't locate destination host '%s'", tp);
return -1;
}
} else /* use destination host == original host */
--- 1329,1335 ----
if (as->parms[8].items) {
tp = as->parms[8].items->data;
if (bc_ParseHost(tp, &destServ)) {
! afs_com_err(whoami, 0, "Can't locate destination host '%s'", tp);
return -1;
}
} else /* use destination host == original host */
***************
*** 1331,1337 ****
if (as->parms[9].items) {
tp = as->parms[9].items->data;
if (bc_GetPartitionID(tp, &destPartition)) {
! com_err(whoami, 0, "Can't parse destination partition '%s'", tp);
return -1;
}
} else /* use original partition */
--- 1339,1345 ----
if (as->parms[9].items) {
tp = as->parms[9].items->data;
if (bc_GetPartitionID(tp, &destPartition)) {
! afs_com_err(whoami, 0, "Can't parse destination partition '%s'", tp);
return -1;
}
} else /* use original partition */
***************
*** 1344,1350 ****
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
--- 1352,1358 ----
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
***************
*** 1365,1371 ****
bc_EvalVolumeSet(bc_globalConfig, &tvolumeSet, &volsToRestore,
cstruct);
if (code) {
! com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
--- 1373,1379 ----
bc_EvalVolumeSet(bc_globalConfig, &tvolumeSet, &volsToRestore,
cstruct);
if (code) {
! afs_com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
***************
*** 1406,1412 ****
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! com_err(whoami, code, "; Failed to queue restore");
return (code);
}
--- 1414,1420 ----
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! afs_com_err(whoami, code, "; Failed to queue restore");
return (code);
}
***************
*** 1439,1463 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
if (as->parms[0].items) {
if (as->parms[1].items) {
! com_err(whoami, 0, "Can't have both -name and -file options");
return (-1);
}
volsetName = as->parms[0].items->data;
volsetPtr = bc_FindVolumeSet(bc_globalConfig, volsetName);
if (!volsetPtr) {
! com_err(whoami, 0,
"Can't find volume set '%s' in backup database",
volsetName);
return (-1);
--- 1447,1471 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
if (as->parms[0].items) {
if (as->parms[1].items) {
! afs_com_err(whoami, 0, "Can't have both -name and -file options");
return (-1);
}
volsetName = as->parms[0].items->data;
volsetPtr = bc_FindVolumeSet(bc_globalConfig, volsetName);
if (!volsetPtr) {
! afs_com_err(whoami, 0,
"Can't find volume set '%s' in backup database",
volsetName);
return (-1);
***************
*** 1468,1474 ****
bc_EvalVolumeSet(bc_globalConfig, volsetPtr, &volsToRestore,
cstruct);
if (code) {
! com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
} else if (as->parms[1].items) {
--- 1476,1482 ----
bc_EvalVolumeSet(bc_globalConfig, volsetPtr, &volsToRestore,
cstruct);
if (code) {
! afs_com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
} else if (as->parms[1].items) {
***************
*** 1480,1486 ****
fd = fopen(as->parms[1].items->data, "r");
if (!fd) {
! com_err(whoami, errno, "; Cannot open file '%s'",
as->parms[1].items->data);
return (-1);
}
--- 1488,1494 ----
fd = fopen(as->parms[1].items->data, "r");
if (!fd) {
! afs_com_err(whoami, errno, "; Cannot open file '%s'",
as->parms[1].items->data);
return (-1);
}
***************
*** 1499,1510 ****
}
if (bc_ParseHost(server, &destServer)) {
! com_err(whoami, 0, "Failed to locate host '%s'", server);
continue;
}
if (bc_GetPartitionID(partition, &destPartition)) {
! com_err(whoami, 0,
"Failed to parse destination partition '%s'",
partition);
continue;
--- 1507,1518 ----
}
if (bc_ParseHost(server, &destServer)) {
! afs_com_err(whoami, 0, "Failed to locate host '%s'", server);
continue;
}
if (bc_GetPartitionID(partition, &destPartition)) {
! afs_com_err(whoami, 0,
"Failed to parse destination partition '%s'",
partition);
continue;
***************
*** 1517,1523 ****
tvol->name = (char *)malloc(VOLSER_MAXVOLNAME + 1);
if (!tvol->name) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strncpy(tvol->name, volume, VOLSER_OLDMAXVOLNAME);
--- 1525,1531 ----
tvol->name = (char *)malloc(VOLSER_MAXVOLNAME + 1);
if (!tvol->name) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strncpy(tvol->name, volume, VOLSER_OLDMAXVOLNAME);
***************
*** 1532,1538 ****
}
fclose(fd);
} else {
! com_err(whoami, 0, "-name or -file option required");
return (-1);
}
--- 1540,1546 ----
}
fclose(fd);
} else {
! afs_com_err(whoami, 0, "-name or -file option required");
return (-1);
}
***************
*** 1543,1549 ****
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
--- 1551,1557 ----
portCount++;
ports = (afs_int32 *) malloc(portCount * sizeof(afs_int32));
if (!ports) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
***************
*** 1568,1574 ****
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! com_err(whoami, code, "; Failed to queue restore");
return code;
}
--- 1576,1582 ----
bc_Restorer, ports, portCount,
/*dumpSched */ NULL, /*append */ 0, dontExecute);
if (code)
! afs_com_err(whoami, code, "; Failed to queue restore");
return code;
}
***************
*** 1631,1647 ****
code = bc_UpdateDumpSchedule();
if (code) {
! com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 1639,1655 ----
code = bc_UpdateDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 1654,1666 ****
loadfile = 1;
if (as->parms[0].items || as->parms[1].items || as->parms[2].items
|| as->parms[4].items) {
! com_err(whoami, 0, "Invalid option specified with -file option");
return -1;
}
} else {
loadfile = 0;
if (!as->parms[0].items || !as->parms[1].items) {
! com_err(whoami, 0,
"Must specify volume set name and dump level name");
return -1;
}
--- 1662,1674 ----
loadfile = 1;
if (as->parms[0].items || as->parms[1].items || as->parms[2].items
|| as->parms[4].items) {
! afs_com_err(whoami, 0, "Invalid option specified with -file option");
return -1;
}
} else {
loadfile = 0;
if (!as->parms[0].items || !as->parms[1].items) {
! afs_com_err(whoami, 0,
"Must specify volume set name and dump level name");
return -1;
}
***************
*** 1682,1689 ****
code = ktime_DateToLong(timeString, &atTime);
free(timeString);
if (code) {
! com_err(whoami, 0, "Can't parse dump start date and time");
! com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (1);
}
} else
--- 1690,1697 ----
code = ktime_DateToLong(timeString, &atTime);
free(timeString);
if (code) {
! afs_com_err(whoami, 0, "Can't parse dump start date and time");
! afs_com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (1);
}
} else
***************
*** 1703,1709 ****
portCount = 1;
portp = (afs_int32 *) malloc(sizeof(afs_int32));
if (!portp) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
--- 1711,1717 ----
portCount = 1;
portp = (afs_int32 *) malloc(sizeof(afs_int32));
if (!portp) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
***************
*** 1719,1731 ****
*/
tvs = bc_FindVolumeSet(bc_globalConfig, vsName);
if (!tvs) {
! com_err(whoami, 0,
"Can't find volume set '%s' in backup database", vsName);
return (-1);
}
baseds = bc_FindDumpSchedule(bc_globalConfig, dumpPath);
if (!baseds) {
! com_err(whoami, 0,
"Can't find dump schedule '%s' in backup database",
dumpPath);
return (-1);
--- 1727,1739 ----
*/
tvs = bc_FindVolumeSet(bc_globalConfig, vsName);
if (!tvs) {
! afs_com_err(whoami, 0,
"Can't find volume set '%s' in backup database", vsName);
return (-1);
}
baseds = bc_FindDumpSchedule(bc_globalConfig, dumpPath);
if (!baseds) {
! afs_com_err(whoami, 0,
"Can't find dump schedule '%s' in backup database",
dumpPath);
return (-1);
***************
*** 1745,1751 ****
*/
if (doAt) {
if (atTime < time(0)) {
! com_err(whoami, 0,
"Time of dump is earlier then current time - not added");
} else {
statusPtr = createStatusNode();
--- 1753,1759 ----
*/
if (doAt) {
if (atTime < time(0)) {
! afs_com_err(whoami, 0,
"Time of dump is earlier then current time - not added");
} else {
statusPtr = createStatusNode();
***************
*** 1784,1790 ****
statusPtr->scheduledDump = atTime;
statusPtr->cmdLine = (char *)malloc(length);
if (!statusPtr->cmdLine) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
--- 1792,1798 ----
statusPtr->scheduledDump = atTime;
statusPtr->cmdLine = (char *)malloc(length);
if (!statusPtr->cmdLine) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
***************
*** 1818,1824 ****
printf("Add scheduled dump as job %d\n", statusPtr->jobNumber);
if ((atTime > ttoken.endTime) && (ttoken.endTime != NEVERDATE))
! com_err(whoami, 0,
"Warning: job %d starts after expiration of AFS token",
statusPtr->jobNumber);
--- 1826,1832 ----
printf("Add scheduled dump as job %d\n", statusPtr->jobNumber);
if ((atTime > ttoken.endTime) && (ttoken.endTime != NEVERDATE))
! afs_com_err(whoami, 0,
"Warning: job %d starts after expiration of AFS token",
statusPtr->jobNumber);
***************
*** 1836,1842 ****
if (loadfile) {
loadFile = (char *)malloc(strlen(as->parms[6].items->data) + 1);
if (!loadFile) {
! com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strcpy(loadFile, as->parms[6].items->data);
--- 1844,1850 ----
if (loadfile) {
loadFile = (char *)malloc(strlen(as->parms[6].items->data) + 1);
if (!loadFile) {
! afs_com_err(whoami, BC_NOMEM, "");
return BC_NOMEM;
}
strcpy(loadFile, as->parms[6].items->data);
***************
*** 1898,1904 ****
* dump at the level we requested it be done at.
*/
if (problemFindingDump) {
! com_err(whoami, 0,
"Warning: Doing level %d dump due to missing higher-level dumps",
level);
if (parent) {
--- 1906,1912 ----
* dump at the level we requested it be done at.
*/
if (problemFindingDump) {
! afs_com_err(whoami, 0,
"Warning: Doing level %d dump due to missing higher-level dumps",
level);
if (parent) {
***************
*** 1911,1917 ****
/* Expand out the volume set into its component list of volumes. */
code = bc_EvalVolumeSet(bc_globalConfig, tvs, &volsToDump, cstruct);
if (code) {
! com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
if (!volsToDump) {
--- 1919,1925 ----
/* Expand out the volume set into its component list of volumes. */
code = bc_EvalVolumeSet(bc_globalConfig, tvs, &volsToDump, cstruct);
if (code) {
! afs_com_err(whoami, code, "; Failed to evaluate volume set");
return (-1);
}
if (!volsToDump) {
***************
*** 1941,1947 ****
tve->cloneDate = 0;
if (tve->cloneDate && (tve->cloneDate == tve->date)) {
! com_err(whoami, 0,
"Warning: Timestamp on volume %s unchanged from previous dump",
tve->name);
}
--- 1949,1955 ----
tve->cloneDate = 0;
if (tve->cloneDate && (tve->cloneDate == tve->date)) {
! afs_com_err(whoami, 0,
"Warning: Timestamp on volume %s unchanged from previous dump",
tve->name);
}
***************
*** 1966,1972 ****
parent, level, bc_Dumper, portp, /*portCount */ 1,
baseds, doAppend, dontExecute);
if (code)
! com_err(whoami, code, "; Failed to queue dump");
return (code);
} /*bc_DumpCmd */
--- 1974,1980 ----
parent, level, bc_Dumper, portp, /*portCount */ 1,
baseds, doAppend, dontExecute);
if (code)
! afs_com_err(whoami, code, "; Failed to queue dump");
return (code);
} /*bc_DumpCmd */
***************
*** 1996,2004 ****
statusPtr = (statusP) ptr;
if (!(statusPtr->flags & ABORT_REQUEST)) {
unlock_Status();
! com_err(whoami, 0, "Job %d still running (and not aborted)",
statusPtr->jobNumber);
! com_err(whoami, 0,
"You must at least 'kill' all running jobs before quitting");
return -1;
}
--- 2004,2012 ----
statusPtr = (statusP) ptr;
if (!(statusPtr->flags & ABORT_REQUEST)) {
unlock_Status();
! afs_com_err(whoami, 0, "Job %d still running (and not aborted)",
statusPtr->jobNumber);
! afs_com_err(whoami, 0,
"You must at least 'kill' all running jobs before quitting");
return -1;
}
***************
*** 2010,2017 ****
*/
for (td = bc_dumpTasks, i = 0; i < BC_MAXSIMDUMPS; i++, td++) {
if (td->flags & BC_DI_INUSE) {
! com_err(whoami, 0, "A job is still running");
! com_err(whoami, 0,
"You must at least 'kill' all running jobs before quitting");
return -1;
}
--- 2018,2025 ----
*/
for (td = bc_dumpTasks, i = 0; i < BC_MAXSIMDUMPS; i++, td++) {
if (td->flags & BC_DI_INUSE) {
! afs_com_err(whoami, 0, "A job is still running");
! afs_com_err(whoami, 0,
"You must at least 'kill' all running jobs before quitting");
return -1;
}
***************
*** 2042,2067 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
if (as->parms[0].items) { /* -name */
tapename = as->parms[0].items->data;
if (strlen(tapename) >= TC_MAXTAPELEN) {
! com_err(whoami, 0, "AFS tape name '%s' is too long", tapename);
return -1;
}
}
if (as->parms[3].items) { /* -pname */
if (tapename) {
! com_err(whoami, 0, "Can only specify -name or -pname");
return -1;
}
pname = as->parms[3].items->data;
if (strlen(pname) >= TC_MAXTAPELEN) {
! com_err(whoami, 0, "Permanent tape name '%s' is too long", pname);
return -1;
}
}
--- 2050,2075 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
if (as->parms[0].items) { /* -name */
tapename = as->parms[0].items->data;
if (strlen(tapename) >= TC_MAXTAPELEN) {
! afs_com_err(whoami, 0, "AFS tape name '%s' is too long", tapename);
return -1;
}
}
if (as->parms[3].items) { /* -pname */
if (tapename) {
! afs_com_err(whoami, 0, "Can only specify -name or -pname");
return -1;
}
pname = as->parms[3].items->data;
if (strlen(pname) >= TC_MAXTAPELEN) {
! afs_com_err(whoami, 0, "Permanent tape name '%s' is too long", pname);
return -1;
}
}
***************
*** 2069,2075 ****
if (as->parms[1].items) {
size = bc_FloatATOI(as->parms[1].items->data);
if (size == -1) {
! com_err(whoami, 0, "Bad syntax for tape size '%s'",
as->parms[1].items->data);
return -1;
}
--- 2077,2083 ----
if (as->parms[1].items) {
size = bc_FloatATOI(as->parms[1].items->data);
if (size == -1) {
! afs_com_err(whoami, 0, "Bad syntax for tape size '%s'",
as->parms[1].items->data);
return -1;
}
***************
*** 2103,2109 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 2111,2117 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 2134,2140 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 2142,2148 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 2275,2281 ****
&host);
if (code) {
! com_err(whoami, code, "; Unable to verify database");
return (-1);
}
--- 2283,2289 ----
&host);
if (code) {
! afs_com_err(whoami, code, "; Unable to verify database");
return (-1);
}
***************
*** 2284,2290 ****
if (status == 0)
printf("Database OK\n");
else
! com_err(whoami, status, "; Database is NOT_OK");
if (detail) {
printf("Orphan blocks %d\n", orphans);
--- 2292,2298 ----
if (status == 0)
printf("Database OK\n");
else
! afs_com_err(whoami, status, "; Database is NOT_OK");
if (detail) {
printf("Orphan blocks %d\n", orphans);
***************
*** 2324,2337 ****
if (port >= 0) {
tcode = bc_UpdateHosts();
if (tcode) {
! com_err(whoami, tcode, "; Can't retrieve tape hosts");
ERROR(tcode);
}
/* Find the dump in the backup database */
tcode = bcdb_FindDumpByID(dumpid, &dumpEntry);
if (tcode) {
! com_err(whoami, tcode, "; Unable to locate dumpID %u in database",
dumpid);
ERROR(tcode);
}
--- 2332,2345 ----
if (port >= 0) {
tcode = bc_UpdateHosts();
if (tcode) {
! afs_com_err(whoami, tcode, "; Can't retrieve tape hosts");
ERROR(tcode);
}
/* Find the dump in the backup database */
tcode = bcdb_FindDumpByID(dumpid, &dumpEntry);
if (tcode) {
! afs_com_err(whoami, tcode, "; Unable to locate dumpID %u in database",
dumpid);
ERROR(tcode);
}
***************
*** 2351,2357 ****
if (tcode) {
if (tcode == RXGEN_OPCODE)
tcode = BC_VERSIONFAIL;
! com_err(whoami, tcode,
"; Unable to delete dumpID %u via butc", dumpid);
ERROR(tcode);
}
--- 2359,2365 ----
if (tcode) {
if (tcode == RXGEN_OPCODE)
tcode = BC_VERSIONFAIL;
! afs_com_err(whoami, tcode,
"; Unable to delete dumpID %u via butc", dumpid);
ERROR(tcode);
}
***************
*** 2369,2375 ****
/* Wait for task to finish */
taskflag = waitForTask(taskId);
if (taskflag & (TASK_ERROR | ABORT_DONE)) {
! com_err(whoami, BUTX_DELETEOBJFAIL,
"; Unable to delete dumpID %u via butc", dumpid);
ERROR(BUTX_DELETEOBJFAIL); /* the task failed */
}
--- 2377,2383 ----
/* Wait for task to finish */
taskflag = waitForTask(taskId);
if (taskflag & (TASK_ERROR | ABORT_DONE)) {
! afs_com_err(whoami, BUTX_DELETEOBJFAIL,
"; Unable to delete dumpID %u via butc", dumpid);
ERROR(BUTX_DELETEOBJFAIL); /* the task failed */
}
***************
*** 2389,2395 ****
tcode = bcdb_deleteDump(dumpid, 0, 0, &dumps);
if (tcode) {
! com_err(whoami, tcode,
"; Unable to delete dumpID %u from database", dumpid);
dumps.budb_dumpsList_len = 0;
if (!code)
--- 2397,2403 ----
tcode = bcdb_deleteDump(dumpid, 0, 0, &dumps);
if (tcode) {
! afs_com_err(whoami, tcode,
"; Unable to delete dumpID %u from database", dumpid);
dumps.budb_dumpsList_len = 0;
if (!code)
***************
*** 2431,2443 ****
/* Must specify at least one of -dumpid, -from, or -to */
if (!as->parms[0].items && !as->parms[1].items && !as->parms[2].items
&& !as->parms[4].items) {
! com_err(whoami, 0, "Must specify at least one field");
return (-1);
}
/* Must have -to option with -from option */
if (as->parms[1].items && !as->parms[2].items) {
! com_err(whoami, 0, "Must specify '-to' field with '-from' field");
return (-1);
}
--- 2439,2451 ----
/* Must specify at least one of -dumpid, -from, or -to */
if (!as->parms[0].items && !as->parms[1].items && !as->parms[2].items
&& !as->parms[4].items) {
! afs_com_err(whoami, 0, "Must specify at least one field");
return (-1);
}
/* Must have -to option with -from option */
if (as->parms[1].items && !as->parms[2].items) {
! afs_com_err(whoami, 0, "Must specify '-to' field with '-from' field");
return (-1);
}
***************
*** 2453,2460 ****
code = ktime_DateToLong(timeString, &fromTime);
free(timeString);
if (code) {
! com_err(whoami, 0, "Can't parse 'from' date and time");
! com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
havetime = 1;
--- 2461,2468 ----
code = ktime_DateToLong(timeString, &fromTime);
free(timeString);
if (code) {
! afs_com_err(whoami, 0, "Can't parse 'from' date and time");
! afs_com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
havetime = 1;
***************
*** 2485,2492 ****
code = ktime_DateToLong(timeString, &toTime);
free(timeString);
if (code) {
! com_err(whoami, 0, "Can't parse 'to' date and time");
! com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
toTime += 59;
--- 2493,2500 ----
code = ktime_DateToLong(timeString, &toTime);
free(timeString);
if (code) {
! afs_com_err(whoami, 0, "Can't parse 'to' date and time");
! afs_com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
toTime += 59;
***************
*** 2494,2500 ****
}
if (fromTime > toTime) {
! com_err(whoami, 0,
"'-from' date/time cannot be later than '-to' date/time");
return (-1);
}
--- 2502,2508 ----
}
if (fromTime > toTime) {
! afs_com_err(whoami, 0,
"'-from' date/time cannot be later than '-to' date/time");
return (-1);
}
***************
*** 2528,2534 ****
code =
bcdb_listDumps(sflags, groupId, fromTime, toTime, &dumps, &flags);
if (code) {
! com_err(whoami, code,
"; Error while deleting dumps from %u to %u", fromTime,
toTime);
rcode = -1;
--- 2536,2542 ----
code =
bcdb_listDumps(sflags, groupId, fromTime, toTime, &dumps, &flags);
if (code) {
! afs_com_err(whoami, code,
"; Error while deleting dumps from %u to %u", fromTime,
toTime);
rcode = -1;
***************
*** 2582,2588 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 2590,2596 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 2605,2612 ****
code = ktime_DateToLong(timeString, &toTime);
free(timeString);
if (code) {
! com_err(whoami, 0, "Can't parse '-archive' date and time");
! com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
toTime += 59;
--- 2613,2620 ----
code = ktime_DateToLong(timeString, &toTime);
free(timeString);
if (code) {
! afs_com_err(whoami, 0, "Can't parse '-archive' date and time");
! afs_com_err(whoami, 0, "%s", ktime_GetDateUsage());
return (-1);
}
toTime += 59;
***************
*** 2619,2625 ****
code = TC_SaveDb(tconn, toTime, &taskId);
if (code) {
! com_err(whoami, code, "; Failed to save database");
goto exit;
}
--- 2627,2633 ----
code = TC_SaveDb(tconn, toTime, &taskId);
if (code) {
! afs_com_err(whoami, code, "; Failed to save database");
goto exit;
}
***************
*** 2650,2656 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 2658,2664 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 2666,2672 ****
code = TC_RestoreDb(tconn, &taskId);
if (code) {
! com_err(whoami, code, "; Failed to restore database");
goto exit;
}
--- 2674,2680 ----
code = TC_RestoreDb(tconn, &taskId);
if (code) {
! afs_com_err(whoami, code, "; Failed to restore database");
goto exit;
}
***************
*** 2833,2839 ****
}
if (code)
! com_err(whoami, code, "");
return (code);
}
--- 2841,2847 ----
}
if (code)
! afs_com_err(whoami, code, "");
return (code);
}
***************
*** 2923,2929 ****
for (tapeNumber = dumpEntry.tapes.b; tapeNumber <= dumpEntry.tapes.maxTapes; tapeNumber++) { /*f */
tapeLinkPtr = (struct tapeLink *)malloc(sizeof(struct tapeLink));
if (!tapeLinkPtr) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
--- 2931,2937 ----
for (tapeNumber = dumpEntry.tapes.b; tapeNumber <= dumpEntry.tapes.maxTapes; tapeNumber++) { /*f */
tapeLinkPtr = (struct tapeLink *)malloc(sizeof(struct tapeLink));
if (!tapeLinkPtr) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
***************
*** 2975,2981 ****
volumeLinkPtr =
(struct volumeLink *)malloc(sizeof(struct volumeLink));
if (!volumeLinkPtr) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(volumeLinkPtr, 0, sizeof(*volumeLinkPtr));
--- 2983,2989 ----
volumeLinkPtr =
(struct volumeLink *)malloc(sizeof(struct volumeLink));
if (!volumeLinkPtr) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(volumeLinkPtr, 0, sizeof(*volumeLinkPtr));
***************
*** 3044,3050 ****
error_exit:
if (code)
! com_err("dumpInfo", code, "; Can't get dump information");
/* free all allocated structures */
tapeLinkPtr = head;
--- 3052,3058 ----
error_exit:
if (code)
! afs_com_err("dumpInfo", code, "; Can't get dump information");
/* free all allocated structures */
tapeLinkPtr = head;
***************
*** 3103,3109 ****
if (code) {
if (code == BUDB_ENDOFLIST)
return 0;
! com_err("dumpInfo", code, "; Can't get dump information");
return (code);
}
--- 3111,3117 ----
if (code) {
if (code == BUDB_ENDOFLIST)
return 0;
! afs_com_err("dumpInfo", code, "; Can't get dump information");
return (code);
}
***************
*** 3156,3168 ****
if (as->parms[0].items) {
if (as->parms[1].items) {
! com_err(whoami, 0,
"These options are exclusive - select only one");
return (BC_BADARG);
}
ndumps = atoi(as->parms[0].items->data);
if (ndumps <= 0) {
! com_err(whoami, 0, "Must provide a positive number");
return -1;
}
--- 3164,3176 ----
if (as->parms[0].items) {
if (as->parms[1].items) {
! afs_com_err(whoami, 0,
"These options are exclusive - select only one");
return (BC_BADARG);
}
ndumps = atoi(as->parms[0].items->data);
if (ndumps <= 0) {
! afs_com_err(whoami, 0, "Must provide a positive number");
return -1;
}
Index: openafs/src/bucoord/dump.c
diff -c openafs/src/bucoord/dump.c:1.12.2.2 openafs/src/bucoord/dump.c:1.12.2.3
*** openafs/src/bucoord/dump.c:1.12.2.2 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/dump.c Tue Apr 10 14:43:41 2007
***************
*** 15,21 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/dump.c,v 1.12.2.2 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 15,21 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/dump.c,v 1.12.2.3 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 94,100 ****
volDesc =
(struct tc_dumpDesc *)malloc(count * sizeof(struct tc_dumpDesc));
if (!volDesc) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
--- 94,100 ----
volDesc =
(struct tc_dumpDesc *)malloc(count * sizeof(struct tc_dumpDesc));
if (!volDesc) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
***************
*** 144,154 ****
printf("Starting dump\n");
code = TC_PerformDump(tconn, tcdiPtr, &volArray, &dumpTaskPtr->dumpID);
if (code) {
! com_err(whoami, code, "; Failed to start dump");
ERROR(code);
}
! com_err(whoami, 0, "Task %u: Dump (%s)", dumpTaskPtr->dumpID,
tcdiPtr->dumpName);
/* create status monitor block */
--- 144,154 ----
printf("Starting dump\n");
code = TC_PerformDump(tconn, tcdiPtr, &volArray, &dumpTaskPtr->dumpID);
if (code) {
! afs_com_err(whoami, code, "; Failed to start dump");
ERROR(code);
}
! afs_com_err(whoami, 0, "Task %u: Dump (%s)", dumpTaskPtr->dumpID,
tcdiPtr->dumpName);
/* create status monitor block */
***************
*** 266,272 ****
break;
if (i >= BC_MAXSIMDUMPS) {
! com_err(whoami, BC_NOTLOCKED,
"All of the dump/restore slots are in use, try again later");
return (BC_NOTLOCKED);
}
--- 266,272 ----
break;
if (i >= BC_MAXSIMDUMPS) {
! afs_com_err(whoami, BC_NOTLOCKED,
"All of the dump/restore slots are in use, try again later");
return (BC_NOTLOCKED);
}
***************
*** 305,311 ****
(void *)i, "helper", &junk);
if (code) {
bc_HandleMisc(code);
! com_err(whoami, code, "; Can't start thread");
/* Cleanup allocated data structures */
freeDumpTaskVolumeList(bc_dumpTasks[i].volumes);
--- 305,311 ----
(void *)i, "helper", &junk);
if (code) {
bc_HandleMisc(code);
! afs_com_err(whoami, code, "; Can't start thread");
/* Cleanup allocated data structures */
freeDumpTaskVolumeList(bc_dumpTasks[i].volumes);
***************
*** 384,390 ****
code = TC_LabelTape(tconn, &label, &taskId);
if (code) {
! com_err(whoami, code, "; Failed to start labeltape");
return (code);
}
--- 384,390 ----
code = TC_LabelTape(tconn, &label, &taskId);
if (code) {
! afs_com_err(whoami, code, "; Failed to start labeltape");
return (code);
}
***************
*** 430,436 ****
printf("Tape read was unlabelled\n");
return 0;
}
! com_err(whoami, code, "; Failed to start readlabel");
return (code);
}
--- 430,436 ----
printf("Tape read was unlabelled\n");
return 0;
}
! afs_com_err(whoami, code, "; Failed to start readlabel");
return (code);
}
***************
*** 468,474 ****
code = TC_ScanDumps(tconn, dbAddFlag, &taskId);
if (code) {
! com_err(whoami, code, "; Failed to start scantape");
return (code);
}
--- 468,474 ----
code = TC_ScanDumps(tconn, dbAddFlag, &taskId);
if (code) {
! afs_com_err(whoami, code, "; Failed to start scantape");
return (code);
}
***************
*** 559,565 ****
code = bc_GetConn(config, port, tconn);
if (code) {
! com_err(whoami, code,
"; Can't connect to tape coordinator at port %d", port);
return (code);
}
--- 559,565 ----
code = bc_GetConn(config, port, tconn);
if (code) {
! afs_com_err(whoami, code,
"; Can't connect to tape coordinator at port %d", port);
return (code);
}
***************
*** 569,578 ****
rx_DestroyConnection(*tconn);
if (code == BC_VERSIONFAIL)
! com_err(whoami, code,
"; Backup and butc are not the same version");
else
! com_err(whoami, code,
"; Can't access tape coordinator at port %d", port);
return (code);
--- 569,578 ----
rx_DestroyConnection(*tconn);
if (code == BC_VERSIONFAIL)
! afs_com_err(whoami, code,
"; Backup and butc are not the same version");
else
! afs_com_err(whoami, code,
"; Can't access tape coordinator at port %d", port);
return (code);
Index: openafs/src/bucoord/dump_sched.c
diff -c openafs/src/bucoord/dump_sched.c:1.7.2.4 openafs/src/bucoord/dump_sched.c:1.7.2.5
*** openafs/src/bucoord/dump_sched.c:1.7.2.4 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/dump_sched.c Tue Apr 10 14:43:41 2007
***************
*** 16,22 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/dump_sched.c,v 1.7.2.4 2007/01/05 03:34:09 shadow Exp $");
#ifdef AFS_NT40_ENV
#include
--- 16,22 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/dump_sched.c,v 1.7.2.5 2007/04/10 18:43:41 shadow Exp $");
#ifdef AFS_NT40_ENV
#include
***************
*** 91,97 ****
code = bc_UpdateDumpSchedule();
if (code) {
! com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
--- 91,97 ----
code = bc_UpdateDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
***************
*** 102,110 ****
/* validate the name dump name length */
if (strlen(dname) >= BU_MAX_DUMP_PATH) {
! com_err(whoami, 0, "Dump names must be < %d characters",
BU_MAX_DUMP_PATH);
! com_err(whoami, 0, "Dump %s not added", dname);
code = -1;
continue;
}
--- 102,110 ----
/* validate the name dump name length */
if (strlen(dname) >= BU_MAX_DUMP_PATH) {
! afs_com_err(whoami, 0, "Dump names must be < %d characters",
BU_MAX_DUMP_PATH);
! afs_com_err(whoami, 0, "Dump %s not added", dname);
code = -1;
continue;
}
***************
*** 113,138 ****
bc_CreateDumpSchedule(bc_globalConfig, dname, expDate, expType);
if (code) {
if (code == -1)
! com_err(whoami, 0, "Dump already exists");
else if (code == -2)
! com_err(whoami, 0, "Invalid path name '%s'", dname);
else if (code == -3)
! com_err(whoami, 0, "Name specification error");
else
! com_err(whoami, code, "; Failed to create dump schedule");
continue;
}
/* save the new schedule item */
code = bc_SaveDumpSchedule();
if (code) {
! com_err(whoami, code, "Cannot save dump schedule");
! com_err(whoami, 0,
"Changes are temporary - for this session only");
break;
}
! com_err(whoami, 0, "Created new dump schedule %s", dname);
}
error_exit:
--- 113,138 ----
bc_CreateDumpSchedule(bc_globalConfig, dname, expDate, expType);
if (code) {
if (code == -1)
! afs_com_err(whoami, 0, "Dump already exists");
else if (code == -2)
! afs_com_err(whoami, 0, "Invalid path name '%s'", dname);
else if (code == -3)
! afs_com_err(whoami, 0, "Name specification error");
else
! afs_com_err(whoami, code, "; Failed to create dump schedule");
continue;
}
/* save the new schedule item */
code = bc_SaveDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "Cannot save dump schedule");
! afs_com_err(whoami, 0,
"Changes are temporary - for this session only");
break;
}
! afs_com_err(whoami, 0, "Created new dump schedule %s", dname);
}
error_exit:
***************
*** 167,173 ****
code = bc_UpdateDumpSchedule();
if (code) {
! com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
--- 167,173 ----
code = bc_UpdateDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
***************
*** 176,184 ****
code = bc_DeleteDumpSchedule(bc_globalConfig, dname);
if (code) {
if (code == -1)
! com_err(whoami, 0, "No such dump as %s", dname);
else
! com_err(whoami, code, "; Failed to delete dump schedule");
goto error_exit;
}
--- 176,184 ----
code = bc_DeleteDumpSchedule(bc_globalConfig, dname);
if (code) {
if (code == -1)
! afs_com_err(whoami, 0, "No such dump as %s", dname);
else
! afs_com_err(whoami, code, "; Failed to delete dump schedule");
goto error_exit;
}
***************
*** 186,193 ****
if (code == 0)
printf("backup: deleted dump schedule %s\n", dname);
else {
! com_err(whoami, code, "Cannot save dump schedule file");
! com_err(whoami, 0, "Deletion is temporary - for this session only");
}
error_exit:
--- 186,193 ----
if (code == 0)
printf("backup: deleted dump schedule %s\n", dname);
else {
! afs_com_err(whoami, code, "Cannot save dump schedule file");
! afs_com_err(whoami, 0, "Deletion is temporary - for this session only");
}
error_exit:
***************
*** 275,281 ****
/* first check to see if schedules must be updated */
code = bc_UpdateDumpSchedule();
if (code) {
! com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
--- 275,281 ----
/* first check to see if schedules must be updated */
code = bc_UpdateDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
***************
*** 334,340 ****
code = bc_UpdateDumpSchedule();
if (code) {
! com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
--- 334,340 ----
code = bc_UpdateDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve dump schedule");
return (code);
}
***************
*** 346,360 ****
/* validate the name dump name length */
if (strlen(dname) >= BU_MAX_DUMP_PATH) {
code = -1;
! com_err(whoami, 0, "Dump names must be < %d characters",
BU_MAX_DUMP_PATH);
! com_err(whoami, 0, "Dump %s not added", dname);
continue;
}
code = FindDump(bc_globalConfig, dname, &parent, &node);
if (code) {
! com_err(whoami, 0, "Dump level %s not found", dname);
continue;
}
--- 346,360 ----
/* validate the name dump name length */
if (strlen(dname) >= BU_MAX_DUMP_PATH) {
code = -1;
! afs_com_err(whoami, 0, "Dump names must be < %d characters",
BU_MAX_DUMP_PATH);
! afs_com_err(whoami, 0, "Dump %s not added", dname);
continue;
}
code = FindDump(bc_globalConfig, dname, &parent, &node);
if (code) {
! afs_com_err(whoami, 0, "Dump level %s not found", dname);
continue;
}
***************
*** 364,371 ****
code = bc_SaveDumpSchedule();
if (code) {
! com_err(whoami, code, "Cannot save dump schedule");
! com_err(whoami, 0,
"Expiration changes effective for this session only");
}
--- 364,371 ----
code = bc_SaveDumpSchedule();
if (code) {
! afs_com_err(whoami, code, "Cannot save dump schedule");
! afs_com_err(whoami, 0,
"Expiration changes effective for this session only");
}
***************
*** 423,429 ****
|| (dsversion != BC_SCHEDULE_VERSION)
) {
/* invalid or unexpected header - error */
! com_err(whoami, 0, "Unable to understand dump schedule file");
return (BC_INTERNALERROR);
}
}
--- 423,429 ----
|| (dsversion != BC_SCHEDULE_VERSION)
) {
/* invalid or unexpected header - error */
! afs_com_err(whoami, 0, "Unable to understand dump schedule file");
return (BC_INTERNALERROR);
}
}
***************
*** 437,443 ****
sscanf(tbuffer, "%s %s %d %d", dsname, period, &expDate,
&expType);
if (code != 4) {
! com_err(whoami, 0,
"Syntax error in dump schedule file, line is: %s",
tbuffer);
return (BC_INTERNALERROR);
--- 437,443 ----
sscanf(tbuffer, "%s %s %d %d", dsname, period, &expDate,
&expType);
if (code != 4) {
! afs_com_err(whoami, 0,
"Syntax error in dump schedule file, line is: %s",
tbuffer);
return (BC_INTERNALERROR);
Index: openafs/src/bucoord/main.c
diff -c openafs/src/bucoord/main.c:1.16.2.1 openafs/src/bucoord/main.c:1.16.2.3
*** openafs/src/bucoord/main.c:1.16.2.1 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/main.c Sat Jun 23 11:27:22 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/main.c,v 1.16.2.1 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/main.c,v 1.16.2.3 2007/06/23 15:27:22 shadow Exp $");
#include
#include
***************
*** 251,264 ****
/* don't run more than once */
if (initd) {
! com_err(whoami, 0, "Backup already initialized.");
return 0;
}
initd = 1;
code = bc_InitConfig(DefaultConfDir);
if (code) {
! com_err(whoami, code,
"Can't initialize from config files in directory '%s'",
DefaultConfDir);
return (code);
--- 251,264 ----
/* don't run more than once */
if (initd) {
! afs_com_err(whoami, 0, "Backup already initialized.");
return 0;
}
initd = 1;
code = bc_InitConfig(DefaultConfDir);
if (code) {
! afs_com_err(whoami, code,
"Can't initialize from config files in directory '%s'",
DefaultConfDir);
return (code);
***************
*** 269,281 ****
*/
code = LWP_InitializeProcessSupport(LWP_NORMAL_PRIORITY, &pid);
if (code) {
! com_err(whoami, code, "; Can't initialize LWP");
return (code);
}
code = rx_Init(htons(0));
if (code) {
! com_err(whoami, code, "; Can't initialize Rx");
return (code);
}
--- 269,281 ----
*/
code = LWP_InitializeProcessSupport(LWP_NORMAL_PRIORITY, &pid);
if (code) {
! afs_com_err(whoami, code, "; Can't initialize LWP");
return (code);
}
code = rx_Init(htons(0));
if (code) {
! afs_com_err(whoami, code, "; Can't initialize Rx");
return (code);
}
***************
*** 297,303 ****
LWP_CreateProcess(statusWatcher, 20480, LWP_NORMAL_PRIORITY,
(void *)2, "statusWatcher", &watcherPid);
if (code) {
! com_err(whoami, code, "; Can't create status monitor task");
return (code);
}
--- 297,303 ----
LWP_CreateProcess(statusWatcher, 20480, LWP_NORMAL_PRIORITY,
(void *)2, "statusWatcher", &watcherPid);
if (code) {
! afs_com_err(whoami, code, "; Can't create status monitor task");
return (code);
}
***************
*** 341,354 ****
code = backupInit();
if (code) {
! com_err(whoami, code, "; Can't initialize backup");
exit(1);
}
/* Get initial information from the database */
code = bc_InitTextConfig();
if (code) {
! com_err(whoami, code,
"; Can't obtain configuration text from backup database");
exit(1);
}
--- 341,354 ----
code = backupInit();
if (code) {
! afs_com_err(whoami, code, "; Can't initialize backup");
exit(1);
}
/* Get initial information from the database */
code = bc_InitTextConfig();
if (code) {
! afs_com_err(whoami, code,
"; Can't obtain configuration text from backup database");
exit(1);
}
***************
*** 409,415 ****
if (internalLoadFile) { /* Load a file in */
if (dispatchCount > MAXRECURSION) { /* Beware recursive loops. */
! com_err(whoami, 0, "Potential recursion: will not load file %s",
internalLoadFile);
code = -1;
goto done;
--- 409,415 ----
if (internalLoadFile) { /* Load a file in */
if (dispatchCount > MAXRECURSION) { /* Beware recursive loops. */
! afs_com_err(whoami, 0, "Potential recursion: will not load file %s",
internalLoadFile);
code = -1;
goto done;
***************
*** 417,423 ****
fd = fopen(internalLoadFile, "r"); /* Open the load file */
if (!fd) {
! com_err(whoami, errno, "; Cannot open file %s", internalLoadFile);
code = -1;
goto done;
}
--- 417,423 ----
fd = fopen(internalLoadFile, "r"); /* Open the load file */
if (!fd) {
! afs_com_err(whoami, errno, "; Cannot open file %s", internalLoadFile);
code = -1;
goto done;
}
***************
*** 444,450 ****
(!noExecute)) { /* or no execute */
c = cmd_ParseLine(lineBuffer, sargv, &sargc, MAXV);
if (c) {
! com_err(whoami, c, "; Can't parse line");
} else {
doDispatch(sargc, sargv, dispatchCount + 1); /* Recursive - ignore error */
cmd_FreeArgv(sargv); /* Free up arguments */
--- 444,450 ----
(!noExecute)) { /* or no execute */
c = cmd_ParseLine(lineBuffer, sargv, &sargc, MAXV);
if (c) {
! afs_com_err(whoami, c, "; Can't parse line");
} else {
doDispatch(sargc, sargv, dispatchCount + 1); /* Recursive - ignore error */
cmd_FreeArgv(sargv); /* Free up arguments */
***************
*** 544,549 ****
--- 544,551 ----
"date from which to restore");
cmd_AddParm(ts, "-portoffset", CMD_LIST, CMD_OPTIONAL, "TC port offsets");
cmd_AddParm(ts, "-n", CMD_FLAG, CMD_OPTIONAL, "don't really execute it");
+ cmd_AddParm(ts, "-usedump", CMD_SINGLE, CMD_OPTIONAL,
+ "specify the dumpID to restore from");
if (!interact)
add_std_args(ts);
***************
*** 796,803 ****
if (!LineIsBlank(lineBuffer)) {
code = cmd_ParseLine(lineBuffer, targv, &targc, MAXV);
if (code)
! com_err(whoami, code, "; Can't parse line: '%s'",
! error_message(code));
else {
doDispatch(targc, targv, 1);
cmd_FreeArgv(targv);
--- 798,805 ----
if (!LineIsBlank(lineBuffer)) {
code = cmd_ParseLine(lineBuffer, targv, &targc, MAXV);
if (code)
! afs_com_err(whoami, code, "; Can't parse line: '%s'",
! afs_error_message(code));
else {
doDispatch(targc, targv, 1);
cmd_FreeArgv(targv);
Index: openafs/src/bucoord/restore.c
diff -c openafs/src/bucoord/restore.c:1.8.2.3 openafs/src/bucoord/restore.c:1.8.2.7
*** openafs/src/bucoord/restore.c:1.8.2.3 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/restore.c Tue Jun 26 01:44:57 2007
***************
*** 15,21 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/restore.c,v 1.8.2.3 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 15,21 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/restore.c,v 1.8.2.7 2007/06/26 05:44:57 jaltman Exp $");
#include
#include
***************
*** 40,46 ****
extern struct bc_dumpTask bc_dumpTasks[BC_MAXSIMDUMPS];
extern char *whoami;
- #define BC_MAXLEVELS 20
#define MAXTAPESATONCE 10
#define HOSTADDR(sockaddr) (sockaddr)->sin_addr.s_addr
--- 40,45 ----
***************
*** 182,190 ****
statusP statusPtr, newStatusPtr;
struct dumpinfo *dumpinfolist = NULL;
! struct dumpinfo *pdi, *ndi, *di, dlevels[BC_MAXLEVELS];
struct volinfo *pvi, *nvi, *vi;
afs_int32 lvl, lv;
afs_int32 serverAll; /* The server to which all volumes are to be restore to */
afs_int32 partitionAll; /* Likewise for partition */
--- 181,190 ----
statusP statusPtr, newStatusPtr;
struct dumpinfo *dumpinfolist = NULL;
! struct dumpinfo *pdi, *ndi, *di, *dlevels;
struct volinfo *pvi, *nvi, *vi;
afs_int32 lvl, lv;
+ int num_dlevels = 20;
afs_int32 serverAll; /* The server to which all volumes are to be restore to */
afs_int32 partitionAll; /* Likewise for partition */
***************
*** 196,201 ****
--- 196,203 ----
extern statusP createStatusNode();
extern statusP findStatus();
+ dlevels = (struct dumpinfo *) malloc(num_dlevels * sizeof(*dlevels));
+
dumpTaskPtr = &bc_dumpTasks[aindex];
serverAll = HOSTADDR(&dumpTaskPtr->destServer);
partitionAll = dumpTaskPtr->destPartition;
***************
*** 203,209 ****
volumeEntries = (struct budb_volumeEntry *)
malloc(MAXTAPESATONCE * sizeof(struct budb_volumeEntry));
if (!volumeEntries) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
--- 205,211 ----
volumeEntries = (struct budb_volumeEntry *)
malloc(MAXTAPESATONCE * sizeof(struct budb_volumeEntry));
if (!volumeEntries) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
***************
*** 214,242 ****
for (tvol = dumpTaskPtr->volumes; tvol; tvol = tvol->next) { /*tvol */
strcpy(vname, tvol->name);
dumpDescr = &dumpDescr1;
! code = bcdb_FindDump(vname, dumpTaskPtr->fromDate, dumpDescr);
!
! if (!BackupName(vname)) { /* See if backup volume is there */
! strcat(vname, ".backup");
! dumpDescr = &dumpDescr2;
! tcode = code;
code = bcdb_FindDump(vname, dumpTaskPtr->fromDate, dumpDescr);
! if (code) { /* Can't find backup, go with first results */
strcpy(vname, tvol->name);
dumpDescr = &dumpDescr1;
code = tcode;
! } else if (!tcode) { /* Both found an entry, go with latest result */
if (dumpDescr1.created > dumpDescr2.created) {
! strcpy(vname, tvol->name);
! dumpDescr = &dumpDescr1;
! code = tcode;
}
}
! }
if (code) { /* If FindDump took an error */
! com_err(whoami, code, "; Can't find any dump for volume %s",
tvol->name);
continue;
}
--- 216,270 ----
for (tvol = dumpTaskPtr->volumes; tvol; tvol = tvol->next) { /*tvol */
strcpy(vname, tvol->name);
dumpDescr = &dumpDescr1;
! if (dumpTaskPtr->parentDumpID > 0) /* Told which dump to try */
! {
! /* Right now, this assumes that all volumes listed will be
! * from the given dumpID. FIXME
! */
! code = bcdb_FindDumpByID(dumpTaskPtr->parentDumpID, dumpDescr);
! if (code)
! {
! afs_com_err(whoami, "Couldn't look up info for dump %d\n",
! dumpTaskPtr->parentDumpID);
! continue;
! }
! code = bcdb_FindVolumes(dumpTaskPtr->parentDumpID, vname, volumeEntries,
! last, &next, MAXTAPESATONCE, &vecount);
! if (code)
! {
! if (!BackupName(vname))
! {
! strcat(vname, ".backup");
! code = bcdb_FindVolumes(dumpTaskPtr->parentDumpID, vname, volumeEntries,
! last, &next, MAXTAPESATONCE, &vecount);
! }
! }
! }
! else
! {
code = bcdb_FindDump(vname, dumpTaskPtr->fromDate, dumpDescr);
+ if (!BackupName(vname)) { /* See if backup volume is there */
+ strcat(vname, ".backup");
+ dumpDescr = &dumpDescr2;
+ tcode = code;
+ code = bcdb_FindDump(vname, dumpTaskPtr->fromDate, dumpDescr);
! if (code) { /* Can't find backup, go with first results */
strcpy(vname, tvol->name);
dumpDescr = &dumpDescr1;
code = tcode;
! } else if (!tcode) { /* Both found an entry, go with latest result */
if (dumpDescr1.created > dumpDescr2.created) {
! strcpy(vname, tvol->name);
! dumpDescr = &dumpDescr1;
! code = tcode;
}
+ }
}
! }
if (code) { /* If FindDump took an error */
! afs_com_err(whoami, code, "; Can't find any dump for volume %s",
tvol->name);
continue;
}
***************
*** 255,261 ****
if (!di) {
di = (struct dumpinfo *)malloc(sizeof(struct dumpinfo));
if (!di) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(di, 0, sizeof(struct dumpinfo));
--- 283,289 ----
if (!di) {
di = (struct dumpinfo *)malloc(sizeof(struct dumpinfo));
if (!di) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(di, 0, sizeof(struct dumpinfo));
***************
*** 277,283 ****
/* Create one and thread into list */
vi = (struct volinfo *)malloc(sizeof(struct volinfo));
if (!vi) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(vi, 0, sizeof(struct volinfo));
--- 305,311 ----
/* Create one and thread into list */
vi = (struct volinfo *)malloc(sizeof(struct volinfo));
if (!vi) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(vi, 0, sizeof(struct volinfo));
***************
*** 285,291 ****
vi->volname = (char *)malloc(strlen(vname) + 1);
if (!vi->volname) {
free(vi);
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
--- 313,319 ----
vi->volname = (char *)malloc(strlen(vname) + 1);
if (!vi->volname) {
free(vi);
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
***************
*** 314,323 ****
memcpy(&dlevels[0], di, sizeof(struct dumpinfo));
for (lvl = 1, parent = dlevels[0].parentDumpId; parent;
parent = dlevels[lvl].parentDumpId, lvl++) {
code = bcdb_FindDumpByID(parent, &dumpDescr1);
if (code) {
for (vi = di->volinfolist; vi; vi = vi->next) {
! com_err(whoami, code,
"; Can't find parent DumpID %u for volume %s",
parent, vi->volname);
}
--- 342,359 ----
memcpy(&dlevels[0], di, sizeof(struct dumpinfo));
for (lvl = 1, parent = dlevels[0].parentDumpId; parent;
parent = dlevels[lvl].parentDumpId, lvl++) {
+ if (lvl >= num_dlevels) { /* running out of dump levels */
+ struct dumpinfo *tdl = dlevels;
+
+ num_dlevels += num_dlevels; /* double */
+ dlevels = (struct dumpinfo *) malloc(num_dlevels * sizeof(*dlevels));
+ memcpy(dlevels, tdl, (num_dlevels/2) * sizeof(*dlevels));
+ free(tdl);
+ }
code = bcdb_FindDumpByID(parent, &dumpDescr1);
if (code) {
for (vi = di->volinfolist; vi; vi = vi->next) {
! afs_com_err(whoami, code,
"; Can't find parent DumpID %u for volume %s",
parent, vi->volname);
}
***************
*** 369,375 ****
break;
}
! com_err(whoami, code,
"; Can't find volume %s in DumpID %u",
vi->volname, dlevels[lv].DumpId);
ERROR(code);
--- 405,411 ----
break;
}
! afs_com_err(whoami, code,
"; Can't find volume %s in DumpID %u",
vi->volname, dlevels[lv].DumpId);
ERROR(code);
***************
*** 450,456 ****
tle = (struct bc_tapeList *)
malloc(sizeof(struct bc_tapeList));
if (!tle) {
! com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(tle, 0, sizeof(struct bc_tapeList));
--- 486,492 ----
tle = (struct bc_tapeList *)
malloc(sizeof(struct bc_tapeList));
if (!tle) {
! afs_com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(tle, 0, sizeof(struct bc_tapeList));
***************
*** 460,466 ****
+ 1);
if (!tle->tapeName) {
free(tle);
! com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
--- 496,502 ----
+ 1);
if (!tle->tapeName) {
free(tle);
! afs_com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
***************
*** 505,511 ****
ti = (struct bc_tapeItem *)
malloc(sizeof(struct bc_tapeItem));
if (!ti) {
! com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(ti, 0, sizeof(struct bc_tapeItem));
--- 541,547 ----
ti = (struct bc_tapeItem *)
malloc(sizeof(struct bc_tapeItem));
if (!ti) {
! afs_com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
memset(ti, 0, sizeof(struct bc_tapeItem));
***************
*** 515,521 ****
+ 1);
if (!ti->volumeName) {
free(ti);
! com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
--- 551,557 ----
+ 1);
if (!ti->volumeName) {
free(ti);
! afs_com_err(whoami, BC_NOMEM, "");
return (BC_NOMEM);
}
***************
*** 548,554 ****
} /* di: For each dump */
if (!nentries) {
! com_err(whoami, 0, "No volumes to restore");
ERROR(0);
}
--- 584,590 ----
} /* di: For each dump */
if (!nentries) {
! afs_com_err(whoami, 0, "No volumes to restore");
ERROR(0);
}
***************
*** 605,611 ****
(struct tc_restoreDesc *)malloc(nentries *
sizeof(struct tc_restoreDesc));
if (!tcarray) {
! com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(tcarray, 0, nentries * sizeof(struct tc_restoreDesc));
--- 641,647 ----
(struct tc_restoreDesc *)malloc(nentries *
sizeof(struct tc_restoreDesc));
if (!tcarray) {
! afs_com_err(whoami, BC_NOMEM, "");
ERROR(BC_NOMEM);
}
memset(tcarray, 0, nentries * sizeof(struct tc_restoreDesc));
***************
*** 687,693 ****
TC_PerformRestore(aconn, "DumpSetName", &rpcArray,
&dumpTaskPtr->dumpID);
if (code) {
! com_err(whoami, code, "; Failed to start restore");
break;
}
--- 723,729 ----
TC_PerformRestore(aconn, "DumpSetName", &rpcArray,
&dumpTaskPtr->dumpID);
if (code) {
! afs_com_err(whoami, code, "; Failed to start restore");
break;
}
***************
*** 768,772 ****
--- 804,810 ----
if (volumeEntries)
free(volumeEntries);
+ free(dlevels);
+
return code;
}
Index: openafs/src/bucoord/tape_hosts.c
diff -c openafs/src/bucoord/tape_hosts.c:1.7.2.2 openafs/src/bucoord/tape_hosts.c:1.7.2.3
*** openafs/src/bucoord/tape_hosts.c:1.7.2.2 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/tape_hosts.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/tape_hosts.c,v 1.7.2.2 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/tape_hosts.c,v 1.7.2.3 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 66,72 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 66,72 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 85,98 ****
printf("failed\n");
fflush(stdout);
if (code == EEXIST)
! com_err(whoami, 0, "Port offset already in tape database");
ERROR(code);
}
code = bc_SaveHosts();
if (code) {
! com_err(whoami, code, "Cannot save tape hosts");
! com_err(whoami, 0,
"Changes are temporary - for this session only");
ERROR(code);
}
--- 85,98 ----
printf("failed\n");
fflush(stdout);
if (code == EEXIST)
! afs_com_err(whoami, 0, "Port offset already in tape database");
ERROR(code);
}
code = bc_SaveHosts();
if (code) {
! afs_com_err(whoami, code, "Cannot save tape hosts");
! afs_com_err(whoami, 0,
"Changes are temporary - for this session only");
ERROR(code);
}
***************
*** 124,130 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 124,130 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 150,157 ****
code = bc_SaveHosts();
if (code) {
! com_err(whoami, code, "Cannot save tape hosts");
! com_err(whoami, 0,
"Changes are temporary - for this session only");
ERROR(code);
}
--- 150,157 ----
code = bc_SaveHosts();
if (code) {
! afs_com_err(whoami, code, "Cannot save tape hosts");
! afs_com_err(whoami, 0,
"Changes are temporary - for this session only");
ERROR(code);
}
***************
*** 184,190 ****
code = bc_UpdateHosts();
if (code) {
! com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
--- 184,190 ----
code = bc_UpdateHosts();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve tape hosts");
return (code);
}
***************
*** 264,270 ****
sscanf(tbuffer, "%s %u", hostName, &port);
th = gethostbyname(hostName);
if (th == 0) {
! com_err(whoami, 0,
"can't get host info for %s from nameserver or /etc/hosts.",
hostName);
}
--- 264,270 ----
sscanf(tbuffer, "%s %u", hostName, &port);
th = gethostbyname(hostName);
if (th == 0) {
! afs_com_err(whoami, 0,
"can't get host info for %s from nameserver or /etc/hosts.",
hostName);
}
***************
*** 378,384 ****
}
if (ctPtr->textVersion != -1) {
! com_err(whoami, 0, "obsolete tapehosts - updating");
bc_ClearHosts();
}
--- 378,384 ----
}
if (ctPtr->textVersion != -1) {
! afs_com_err(whoami, 0, "obsolete tapehosts - updating");
bc_ClearHosts();
}
Index: openafs/src/bucoord/ubik_db_if.c
diff -c openafs/src/bucoord/ubik_db_if.c:1.10.2.1 openafs/src/bucoord/ubik_db_if.c:1.10.2.2
*** openafs/src/bucoord/ubik_db_if.c:1.10.2.1 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/ubik_db_if.c Tue Apr 10 14:43:41 2007
***************
*** 13,19 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/ubik_db_if.c,v 1.10.2.1 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 13,19 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/ubik_db_if.c,v 1.10.2.2 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 32,37 ****
--- 32,38 ----
#include
#include
#include
+ #include
#include
#include "bc.h"
***************
*** 727,733 ****
/* Mention something every 30 seconds */
if (++j >= 30) {
! com_err(whoami, code,
"; Waiting for db configuration text unlock");
j = 0;
}
--- 728,734 ----
/* Mention something every 30 seconds */
if (++j >= 30) {
! afs_com_err(whoami, code,
"; Waiting for db configuration text unlock");
j = 0;
}
***************
*** 823,829 ****
afsconf_Open((localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
if (!acdir) {
! com_err(whoami, 0, "Can't open configuration directory '%s'",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
ERROR(BC_NOCELLCONFIG);
--- 824,830 ----
afsconf_Open((localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
if (!acdir) {
! afs_com_err(whoami, 0, "Can't open configuration directory '%s'",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
ERROR(BC_NOCELLCONFIG);
***************
*** 834,840 ****
code = afsconf_GetLocalCell(acdir, cname, sizeof(cname));
if (code) {
! com_err(whoami, code,
"; Can't get the local cell name - check %s/%s",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_THISCELL_FILE);
--- 835,841 ----
code = afsconf_GetLocalCell(acdir, cname, sizeof(cname));
if (code) {
! afs_com_err(whoami, code,
"; Can't get the local cell name - check %s/%s",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_THISCELL_FILE);
***************
*** 845,851 ****
code = afsconf_GetCellInfo(acdir, cellName, AFSCONF_VLDBSERVICE, &info);
if (code) {
! com_err(whoami, code, "; Can't find cell %s's hosts in %s/%s",
cellName,
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_CELLSERVDB_FILE);
--- 846,852 ----
code = afsconf_GetCellInfo(acdir, cellName, AFSCONF_VLDBSERVICE, &info);
if (code) {
! afs_com_err(whoami, code, "; Can't find cell %s's hosts in %s/%s",
cellName,
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_CELLSERVDB_FILE);
***************
*** 859,870 ****
if (localauth) {
code = afsconf_GetLatestKey(acdir, 0, 0);
if (code) {
! com_err(whoami, code, "; Can't get key from local key file");
ERROR(code);
} else {
code = afsconf_ClientAuth(acdir, &sc, &scIndex);
if (code) {
! com_err(whoami, code, "; Calling ClientAuth");
ERROR(code);
}
--- 860,871 ----
if (localauth) {
code = afsconf_GetLatestKey(acdir, 0, 0);
if (code) {
! afs_com_err(whoami, code, "; Can't get key from local key file");
ERROR(code);
} else {
code = afsconf_ClientAuth(acdir, &sc, &scIndex);
if (code) {
! afs_com_err(whoami, code, "; Calling ClientAuth");
ERROR(code);
}
***************
*** 879,889 ****
code =
ktc_GetToken(&sname, ttoken, sizeof(struct ktc_token), NULL);
if (code) {
! com_err(whoami, code, 0,
"; Can't get AFS tokens - running unauthenticated");
} else {
if ((ttoken->kvno < 0) || (ttoken->kvno > 255))
! com_err(whoami, 0,
"Funny kvno (%d) in ticket, proceeding",
ttoken->kvno);
--- 880,890 ----
code =
ktc_GetToken(&sname, ttoken, sizeof(struct ktc_token), NULL);
if (code) {
! afs_com_err(whoami, code, 0,
"; Can't get AFS tokens - running unauthenticated");
} else {
if ((ttoken->kvno < 0) || (ttoken->kvno > 255))
! afs_com_err(whoami, 0,
"Funny kvno (%d) in ticket, proceeding",
ttoken->kvno);
***************
*** 903,916 ****
ttoken->ticket);
break;
default:
! com_err(whoami, 0, "Unsupported authentication type %d", scIndex);
ERROR(-1);
break;
}
}
if (!sc) {
! com_err(whoami, 0,
"Can't create a security object with security index %d",
scIndex);
ERROR(-1);
--- 904,917 ----
ttoken->ticket);
break;
default:
! afs_com_err(whoami, 0, "Unsupported authentication type %d", scIndex);
ERROR(-1);
break;
}
}
if (!sc) {
! afs_com_err(whoami, 0,
"Can't create a security object with security index %d",
scIndex);
ERROR(-1);
***************
*** 920,926 ****
UV_SetSecurity(sc, scIndex);
if (info.numServers > VLDB_MAXSERVERS) {
! com_err(whoami, 0,
"Warning: %d VLDB servers exist for cell '%s', can only remember the first %d",
info.numServers, cellName, VLDB_MAXSERVERS);
info.numServers = VLDB_MAXSERVERS;
--- 921,927 ----
UV_SetSecurity(sc, scIndex);
if (info.numServers > VLDB_MAXSERVERS) {
! afs_com_err(whoami, 0,
"Warning: %d VLDB servers exist for cell '%s', can only remember the first %d",
info.numServers, cellName, VLDB_MAXSERVERS);
info.numServers = VLDB_MAXSERVERS;
***************
*** 936,942 ****
*cstruct = 0;
code = ubik_ClientInit(serverconns, cstruct);
if (code) {
! com_err(whoami, code, "; Can't initialize ubik connection to vldb");
ERROR(code);
}
--- 937,943 ----
*cstruct = 0;
code = ubik_ClientInit(serverconns, cstruct);
if (code) {
! afs_com_err(whoami, code, "; Can't initialize ubik connection to vldb");
ERROR(code);
}
***************
*** 967,973 ****
afsconf_Open((localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
if (!acdir) {
! com_err(whoami, 0, "Can't open configuration directory '%s'",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
ERROR(BC_NOCELLCONFIG);
--- 968,974 ----
afsconf_Open((localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
if (!acdir) {
! afs_com_err(whoami, 0, "Can't open configuration directory '%s'",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH));
ERROR(BC_NOCELLCONFIG);
***************
*** 978,984 ****
code = afsconf_GetLocalCell(acdir, cname, sizeof(cname));
if (code) {
! com_err(whoami, code,
"; Can't get the local cell name - check %s/%s",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_THISCELL_FILE);
--- 979,985 ----
code = afsconf_GetLocalCell(acdir, cname, sizeof(cname));
if (code) {
! afs_com_err(whoami, code,
"; Can't get the local cell name - check %s/%s",
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_THISCELL_FILE);
***************
*** 989,995 ****
code = afsconf_GetCellInfo(acdir, cellName, 0, &info);
if (code) {
! com_err(whoami, code, "; Can't find cell %s's hosts in %s/%s",
cellName,
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_CELLSERVDB_FILE);
--- 990,996 ----
code = afsconf_GetCellInfo(acdir, cellName, 0, &info);
if (code) {
! afs_com_err(whoami, code, "; Can't find cell %s's hosts in %s/%s",
cellName,
(localauth ? AFSDIR_SERVER_ETC_DIRPATH :
AFSDIR_CLIENT_ETC_DIRPATH), AFSDIR_CELLSERVDB_FILE);
***************
*** 1001,1014 ****
if (localauth) {
code = afsconf_GetLatestKey(acdir, 0, 0);
if (code) {
! com_err(whoami, code, "; Can't get key from local key file");
ERROR(-1);
} else {
code =
afsconf_ClientAuth(acdir, &udbHandle.uh_secobj,
&udbHandle.uh_scIndex);
if (code) {
! com_err(whoami, code, "; Calling ClientAuth");
ERROR(-1);
}
}
--- 1002,1015 ----
if (localauth) {
code = afsconf_GetLatestKey(acdir, 0, 0);
if (code) {
! afs_com_err(whoami, code, "; Can't get key from local key file");
ERROR(-1);
} else {
code =
afsconf_ClientAuth(acdir, &udbHandle.uh_secobj,
&udbHandle.uh_scIndex);
if (code) {
! afs_com_err(whoami, code, "; Calling ClientAuth");
ERROR(-1);
}
}
***************
*** 1022,1032 ****
/* get token */
code = ktc_GetToken(&principal, &token, sizeof(token), NULL);
if (code) {
! com_err(whoami, code,
"; Can't get tokens - running unauthenticated");
} else {
if ((token.kvno < 0) || (token.kvno > 255))
! com_err(whoami, 0,
"Unexpected kvno (%d) in ticket - proceeding",
token.kvno);
udbHandle.uh_scIndex = RX_SCINDEX_KAD; /* Kerberos */
--- 1023,1033 ----
/* get token */
code = ktc_GetToken(&principal, &token, sizeof(token), NULL);
if (code) {
! afs_com_err(whoami, code,
"; Can't get tokens - running unauthenticated");
} else {
if ((token.kvno < 0) || (token.kvno > 255))
! afs_com_err(whoami, 0,
"Unexpected kvno (%d) in ticket - proceeding",
token.kvno);
udbHandle.uh_scIndex = RX_SCINDEX_KAD; /* Kerberos */
***************
*** 1046,1052 ****
break;
default:
! com_err(whoami, 0, "Unsupported authentication type %d",
udbHandle.uh_scIndex);
ERROR(-1);
break;
--- 1047,1053 ----
break;
default:
! afs_com_err(whoami, 0, "Unsupported authentication type %d",
udbHandle.uh_scIndex);
ERROR(-1);
break;
***************
*** 1054,1067 ****
}
if (!udbHandle.uh_secobj) {
! com_err(whoami, 0,
"Can't create a security object with security index %d",
udbHandle.uh_secobj);
ERROR(-1);
}
if (info.numServers > MAXSERVERS) {
! com_err(whoami, 0,
"Warning: %d BDB servers exist for cell '%s', can only remember the first %d",
info.numServers, cellName, MAXSERVERS);
info.numServers = MAXSERVERS;
--- 1055,1068 ----
}
if (!udbHandle.uh_secobj) {
! afs_com_err(whoami, 0,
"Can't create a security object with security index %d",
udbHandle.uh_secobj);
ERROR(-1);
}
if (info.numServers > MAXSERVERS) {
! afs_com_err(whoami, 0,
"Warning: %d BDB servers exist for cell '%s', can only remember the first %d",
info.numServers, cellName, MAXSERVERS);
info.numServers = MAXSERVERS;
***************
*** 1078,1084 ****
code = ubik_ClientInit(udbHandle.uh_serverConn, &udbHandle.uh_client);
if (code) {
! com_err(whoami, code,
"; Can't initialize ubik connection to backup database");
ERROR(code);
}
--- 1079,1085 ----
code = ubik_ClientInit(udbHandle.uh_serverConn, &udbHandle.uh_client);
if (code) {
! afs_com_err(whoami, code,
"; Can't initialize ubik connection to backup database");
ERROR(code);
}
***************
*** 1100,1106 ****
ubik_Call(BUDB_GetInstanceId, udbHandle.uh_client, 0,
&udbHandle.uh_instanceId);
if (code) {
! com_err(whoami, code, "; Can't access backup database");
ERROR(code);
}
--- 1101,1107 ----
ubik_Call(BUDB_GetInstanceId, udbHandle.uh_client, 0,
&udbHandle.uh_instanceId);
if (code) {
! afs_com_err(whoami, code, "; Can't access backup database");
ERROR(code);
}
***************
*** 1313,1319 ****
code = ubik_ParseClientList(3, args, serverList);
if (code) {
! com_err(whoami, code, "; udbLocalInit: parsing ubik server list");
return (-1);
}
--- 1314,1320 ----
code = ubik_ParseClientList(3, args, serverList);
if (code) {
! afs_com_err(whoami, code, "; udbLocalInit: parsing ubik server list");
return (-1);
}
***************
*** 1327,1340 ****
BUDB_SERVICE, udbHandle.uh_secobj,
udbHandle.uh_scIndex);
if (udbHandle.uh_serverConn[i] == 0) {
! com_err(whoami, 0, "connection %d failed", i);
continue;
}
}
udbHandle.uh_serverConn[i] = 0;
code = ubik_ClientInit(udbHandle.uh_serverConn, &udbHandle.uh_client);
if (code) {
! com_err(whoami, code, "; in ubik_ClientInit");
return (code);
}
--- 1328,1341 ----
BUDB_SERVICE, udbHandle.uh_secobj,
udbHandle.uh_scIndex);
if (udbHandle.uh_serverConn[i] == 0) {
! afs_com_err(whoami, 0, "connection %d failed", i);
continue;
}
}
udbHandle.uh_serverConn[i] = 0;
code = ubik_ClientInit(udbHandle.uh_serverConn, &udbHandle.uh_client);
if (code) {
! afs_com_err(whoami, code, "; in ubik_ClientInit");
return (code);
}
***************
*** 1342,1348 ****
ubik_Call(BUDB_GetInstanceId, udbHandle.uh_client, 0,
&udbHandle.uh_instanceId);
if (code) {
! com_err(whoami, code, "; Can't estblish instance Id");
return (code);
}
--- 1343,1349 ----
ubik_Call(BUDB_GetInstanceId, udbHandle.uh_client, 0,
&udbHandle.uh_instanceId);
if (code) {
! afs_com_err(whoami, code, "; Can't estblish instance Id");
return (code);
}
Index: openafs/src/bucoord/vol_sets.c
diff -c openafs/src/bucoord/vol_sets.c:1.10.2.3 openafs/src/bucoord/vol_sets.c:1.10.2.4
*** openafs/src/bucoord/vol_sets.c:1.10.2.3 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/vol_sets.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/vol_sets.c,v 1.10.2.3 2007/01/05 03:34:09 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/vol_sets.c,v 1.10.2.4 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 73,79 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 73,79 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 81,87 ****
tset = bc_FindVolumeSet(bc_globalConfig, volSetName);
if (!tset) {
! com_err(whoami, code, "; Volume entry not added");
ERROR(code);
}
--- 81,87 ----
tset = bc_FindVolumeSet(bc_globalConfig, volSetName);
if (!tset) {
! afs_com_err(whoami, code, "; Volume entry not added");
ERROR(code);
}
***************
*** 93,99 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 93,99 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 101,115 ****
bc_AddVolumeItem(bc_globalConfig, volSetName, serverName,
partitionName, volRegExp);
if (code) {
! com_err(whoami, code, "; Volume entry not added");
ERROR(code);
}
if (!(tset->flags & VSFLAG_TEMPORARY)) {
code = bc_SaveVolumeSet();
if (code) {
! com_err(whoami, code, "Cannot save volume set file");
! com_err(whoami, 0,
"Changes are temporary - for this session only");
}
}
--- 101,115 ----
bc_AddVolumeItem(bc_globalConfig, volSetName, serverName,
partitionName, volRegExp);
if (code) {
! afs_com_err(whoami, code, "; Volume entry not added");
ERROR(code);
}
if (!(tset->flags & VSFLAG_TEMPORARY)) {
code = bc_SaveVolumeSet();
if (code) {
! afs_com_err(whoami, code, "Cannot save volume set file");
! afs_com_err(whoami, 0,
"Changes are temporary - for this session only");
}
}
***************
*** 154,160 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 154,160 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 164,177 ****
flags);
if (code) {
if (code == -1)
! com_err(whoami, 0, "Volume set '%s' already exists", ti->data);
else
! com_err(whoami, 0, "Unknown problem");
} else if (!(flags & VSFLAG_TEMPORARY)) {
code = bc_SaveVolumeSet();
if (code) {
! com_err(whoami, code, "Cannot save new volume set file");
! com_err(whoami, 0,
"Changes are temporary - for this session only");
}
}
--- 164,177 ----
flags);
if (code) {
if (code == -1)
! afs_com_err(whoami, 0, "Volume set '%s' already exists", ti->data);
else
! afs_com_err(whoami, 0, "Unknown problem");
} else if (!(flags & VSFLAG_TEMPORARY)) {
code = bc_SaveVolumeSet();
if (code) {
! afs_com_err(whoami, code, "Cannot save new volume set file");
! afs_com_err(whoami, 0,
"Changes are temporary - for this session only");
}
}
***************
*** 205,211 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 205,211 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 214,220 ****
tset = bc_FindVolumeSet(bc_globalConfig, vsname);
if (!tset) {
! com_err(whoami, 0, "No such volume set as '%s'", vsname);
ERROR(code);
}
--- 214,220 ----
tset = bc_FindVolumeSet(bc_globalConfig, vsname);
if (!tset) {
! afs_com_err(whoami, 0, "No such volume set as '%s'", vsname);
ERROR(code);
}
***************
*** 226,238 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
entry = bc_SafeATOI(as->parms[1].items->data);
if (entry < 0) {
! com_err(whoami, 0, "Can't parse entry number '%s' as decimal integer",
as->parms[1].items->data);
ERROR(BC_BADARG);
}
--- 226,238 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
entry = bc_SafeATOI(as->parms[1].items->data);
if (entry < 0) {
! afs_com_err(whoami, 0, "Can't parse entry number '%s' as decimal integer",
as->parms[1].items->data);
ERROR(BC_BADARG);
}
***************
*** 240,251 ****
code = bc_DeleteVolumeItem(bc_globalConfig, vsname, entry);
if (code) {
if (code == -1) {
! com_err(whoami, 0, "No such volume set as '%s'", vsname);
} else if (code == -2) {
! com_err(whoami, 0,
"There aren't %d volume items for this volume set",
entry);
! com_err(whoami, 0,
"Use the 'listvolsets' command to examine the volume set");
}
ERROR(code);
--- 240,251 ----
code = bc_DeleteVolumeItem(bc_globalConfig, vsname, entry);
if (code) {
if (code == -1) {
! afs_com_err(whoami, 0, "No such volume set as '%s'", vsname);
} else if (code == -2) {
! afs_com_err(whoami, 0,
"There aren't %d volume items for this volume set",
entry);
! afs_com_err(whoami, 0,
"Use the 'listvolsets' command to examine the volume set");
}
ERROR(code);
***************
*** 257,264 ****
printf("backup: deleted volume entry %d from volume set %s\n",
entry, vsname);
} else {
! com_err(whoami, code, "Cannot save volume set file");
! com_err(whoami, 0,
"Deletion is temporary - for this session only");
}
}
--- 257,264 ----
printf("backup: deleted volume entry %d from volume set %s\n",
entry, vsname);
} else {
! afs_com_err(whoami, code, "Cannot save volume set file");
! afs_com_err(whoami, 0,
"Deletion is temporary - for this session only");
}
}
***************
*** 300,306 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 300,306 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 308,316 ****
code = bc_DeleteVolumeSet(bc_globalConfig, ti->data, &flags);
if (code) {
if (code == -1)
! com_err(whoami, 0, "Can't find volume set '%s'", ti->data);
else
! com_err(whoami, code,
"; Unknown problem deleting volume set '%s'",
ti->data);
} else {
--- 308,316 ----
code = bc_DeleteVolumeSet(bc_globalConfig, ti->data, &flags);
if (code) {
if (code == -1)
! afs_com_err(whoami, 0, "Can't find volume set '%s'", ti->data);
else
! afs_com_err(whoami, code,
"; Unknown problem deleting volume set '%s'",
ti->data);
} else {
***************
*** 326,333 ****
if (c) {
if (!code)
code = c;
! com_err(whoami, c, "Cannot save updated volume set file");
! com_err(whoami, 0, "Deletion effective for this session only");
}
}
--- 326,333 ----
if (c) {
if (!code)
code = c;
! afs_com_err(whoami, c, "Cannot save updated volume set file");
! afs_com_err(whoami, 0, "Deletion effective for this session only");
}
}
***************
*** 374,380 ****
code = bc_UpdateVolumeSet();
if (code) {
! com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
--- 374,380 ----
code = bc_UpdateVolumeSet();
if (code) {
! afs_com_err(whoami, code, "; Can't retrieve volume sets");
return (code);
}
***************
*** 387,393 ****
ListVolSet(tset);
printf("\n");
} else {
! com_err(whoami, 0, "Can't find volume set '%s'", ti->data);
code = 1;
}
}
--- 387,393 ----
ListVolSet(tset);
printf("\n");
} else {
! afs_com_err(whoami, 0, "Can't find volume set '%s'", ti->data);
code = 1;
}
}
***************
*** 495,501 ****
if ((code != 2)
|| (strcmp(serverName, "volumeset") != 0)
) {
! com_err(whoami, 0, "Bad volume header line: '%s'", tbuffer);
return (-1);
}
--- 495,501 ----
if ((code != 2)
|| (strcmp(serverName, "volumeset") != 0)
) {
! afs_com_err(whoami, 0, "Bad volume header line: '%s'", tbuffer);
return (-1);
}
***************
*** 534,546 ****
tve = (struct bc_volumeEntry *)
malloc(sizeof(struct bc_volumeEntry));
if (!tve) {
! com_err(whoami, 0,
"Can't malloc() a new volume spec record!");
return (-1);
}
memset(tve, 0, sizeof(*tve));
if (bc_ParseHost(serverName, &(tve->server)))
! com_err(whoami, 0, "Can't get required info on host '%s'",
serverName);
/* The above code has filled in the server sockaddr, now fill in
--- 534,546 ----
tve = (struct bc_volumeEntry *)
malloc(sizeof(struct bc_volumeEntry));
if (!tve) {
! afs_com_err(whoami, 0,
"Can't malloc() a new volume spec record!");
return (-1);
}
memset(tve, 0, sizeof(*tve));
if (bc_ParseHost(serverName, &(tve->server)))
! afs_com_err(whoami, 0, "Can't get required info on host '%s'",
serverName);
/* The above code has filled in the server sockaddr, now fill in
***************
*** 548,573 ****
*/
tve->serverName = (char *)malloc(strlen(serverName) + 1);
if (!tve->serverName) {
! com_err(whoami, 0,
"Can't malloc() a new volume spec server name field!");
return (-1);
}
strcpy(tve->serverName, serverName);
tve->partname = (char *)malloc(strlen(partName) + 1);
if (!tve->partname) {
! com_err(whoami, 0,
"Can't malloc() a new volume spec partition pattern field!");
return (-1);
}
strcpy(tve->partname, partName);
code = bc_GetPartitionID(partName, &tve->partition);
if (code) {
! com_err(whoami, 0, "Can't parse partition '%s'", partName);
return -1;
}
tp = (char *)malloc(strlen(vsname) + 1);
if (!tp) {
! com_err(whoami, 0,
"Can't malloc() a new volume spec volume pattern field!");
return (-1);
}
--- 548,573 ----
*/
tve->serverName = (char *)malloc(strlen(serverName) + 1);
if (!tve->serverName) {
! afs_com_err(whoami, 0,
"Can't malloc() a new volume spec server name field!");
return (-1);
}
strcpy(tve->serverName, serverName);
tve->partname = (char *)malloc(strlen(partName) + 1);
if (!tve->partname) {
! afs_com_err(whoami, 0,
"Can't malloc() a new volume spec partition pattern field!");
return (-1);
}
strcpy(tve->partname, partName);
code = bc_GetPartitionID(partName, &tve->partition);
if (code) {
! afs_com_err(whoami, 0, "Can't parse partition '%s'", partName);
return -1;
}
tp = (char *)malloc(strlen(vsname) + 1);
if (!tp) {
! afs_com_err(whoami, 0,
"Can't malloc() a new volume spec volume pattern field!");
return (-1);
}
Index: openafs/src/bucoord/volstub.c
diff -c openafs/src/bucoord/volstub.c:1.6.2.2 openafs/src/bucoord/volstub.c:1.6.2.3
*** openafs/src/bucoord/volstub.c:1.6.2.2 Thu Jan 4 22:34:09 2007
--- openafs/src/bucoord/volstub.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/volstub.c,v 1.6.2.2 2007/01/05 03:34:09 shadow Exp $");
#include
#ifdef AFS_NT40_ENV
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/bucoord/volstub.c,v 1.6.2.3 2007/04/10 18:43:41 shadow Exp $");
#include
#ifdef AFS_NT40_ENV
***************
*** 27,32 ****
--- 27,33 ----
#include "volser.h"
#include "bc.h"
#include
+ #include
extern char *whoami;
***************
*** 76,82 ****
code = UV_ListOneVolume(htonl(serv), part, volid, &viptr);
if (code) {
! com_err(whoami, code,
"Warning: Can't get clone time of volume %u - using 0",
volid);
*clDatePtr = 0;
--- 77,83 ----
code = UV_ListOneVolume(htonl(serv), part, volid, &viptr);
if (code) {
! afs_com_err(whoami, code,
"Warning: Can't get clone time of volume %u - using 0",
volid);
*clDatePtr = 0;
***************
*** 98,104 ****
break;
default:
! com_err(whoami, 0,
"Can't get clone time of volume %u - unknown volume type",
volid);
return (-1);
--- 99,105 ----
break;
default:
! afs_com_err(whoami, 0,
"Can't get clone time of volume %u - unknown volume type",
volid);
return (-1);
Index: openafs/src/budb/database.c
diff -c openafs/src/budb/database.c:1.7 openafs/src/budb/database.c:1.7.2.1
*** openafs/src/budb/database.c:1.7 Tue Jul 15 19:14:48 2003
--- openafs/src/budb/database.c Fri Jul 6 07:34:00 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/database.c,v 1.7 2003/07/15 23:14:48 shadow Exp $");
#ifdef AFS_NT40_ENV
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/database.c,v 1.7.2.1 2007/07/06 11:34:00 jaltman Exp $");
#ifdef AFS_NT40_ENV
#include
***************
*** 75,85 ****
*/
afs_int32
! dbwrite(ut, pos, buff, len)
! struct ubik_trans *ut;
! afs_int32 pos;
! char *buff;
! afs_int32 len;
{
afs_int32 code = 0;
--- 75,81 ----
*/
afs_int32
! dbwrite(struct ubik_trans *ut, afs_int32 pos, void *buff, afs_int32 len)
{
afs_int32 code = 0;
***************
*** 111,121 ****
/* same thing for read */
afs_int32
! dbread(ut, pos, buff, len)
! struct ubik_trans *ut;
! afs_int32 pos;
! char *buff;
! afs_int32 len;
{
afs_int32 code = 0;
--- 107,113 ----
/* same thing for read */
afs_int32
! dbread(struct ubik_trans *ut, afs_int32 pos, void *buff, afs_int32 len)
{
afs_int32 code = 0;
***************
*** 146,157 ****
/* Same as dbread excepts it does checking */
afs_int32
! cdbread(ut, type, pos, buff, len)
! struct ubik_trans *ut;
! int type;
! afs_int32 pos;
! char *buff;
! afs_int32 len;
{
afs_int32 code = 0;
--- 138,144 ----
/* Same as dbread excepts it does checking */
afs_int32
! cdbread(struct ubik_trans *ut, int type, afs_int32 pos, void *buff, afs_int32 len)
{
afs_int32 code = 0;
Index: openafs/src/budb/database.h
diff -c openafs/src/budb/database.h:1.4 openafs/src/budb/database.h:1.4.2.1
*** openafs/src/budb/database.h:1.4 Sun Dec 7 17:49:19 2003
--- openafs/src/budb/database.h Fri Jul 6 07:34:00 2007
***************
*** 315,320 ****
extern afs_uint32 ht_HashEntry();
extern dbadr ht_LookupBucket();
! extern afs_int32 dbwrite(struct ubik_trans *ut, afs_int32 pos, char *buff, afs_int32 len);
extern void db_panic(char *reason);
extern void ht_Reset(struct memoryHashTable *mht);
--- 315,322 ----
extern afs_uint32 ht_HashEntry();
extern dbadr ht_LookupBucket();
! extern afs_int32 dbwrite(struct ubik_trans *ut, afs_int32 pos, void *buff, afs_int32 len);
! extern afs_int32 dbread(struct ubik_trans *ut, afs_int32 pos, void *buff, afs_int32 len);
! extern afs_int32 cdbread(struct ubik_trans *ut, int type, afs_int32 pos, void *buff, afs_int32 len);
extern void db_panic(char *reason);
extern void ht_Reset(struct memoryHashTable *mht);
Index: openafs/src/budb/ol_verify.c
diff -c openafs/src/budb/ol_verify.c:1.13 openafs/src/budb/ol_verify.c:1.13.2.1
*** openafs/src/budb/ol_verify.c:1.13 Sat Nov 29 17:08:09 2003
--- openafs/src/budb/ol_verify.c Fri Jul 6 07:38:31 2007
***************
*** 13,19 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/ol_verify.c,v 1.13 2003/11/29 22:08:09 jaltman Exp $");
#include
#ifdef AFS_NT40_ENV
--- 13,19 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/ol_verify.c,v 1.13.2.1 2007/07/06 11:38:31 jaltman Exp $");
#include
#ifdef AFS_NT40_ENV
***************
*** 303,311 ****
return (typeName[index]);
}
! getDumpID(ut, tapePtr, dumpID)
! struct tape *tapePtr;
! afs_int32 *dumpID;
{
struct dump d;
afs_int32 code;
--- 303,312 ----
return (typeName[index]);
}
! int
! getDumpID(struct ubik_trans *ut,
! struct tape *tapePtr,
! afs_int32 *dumpID)
{
struct dump d;
afs_int32 code;
***************
*** 314,319 ****
--- 315,321 ----
code = dbread(ut, ntohl(tapePtr->dump), &d, sizeof(d));
if (!code)
*dumpID = ntohl(d.id);
+ return code;
}
/* ------------------------------------
Index: openafs/src/budb/server.c
diff -c openafs/src/budb/server.c:1.14.2.4 openafs/src/budb/server.c:1.14.2.5
*** openafs/src/budb/server.c:1.14.2.4 Tue Jun 20 16:35:00 2006
--- openafs/src/budb/server.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/server.c,v 1.14.2.4 2006/06/20 20:35:00 jaltman Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/budb/server.c,v 1.14.2.5 2007/04/10 18:43:41 shadow Exp $");
#include
#include
***************
*** 410,416 ****
#ifdef AFS_NT40_ENV
ReportErrorEventAlt(AFSEVT_SVR_NO_INSTALL_DIR, 0, argv[0], 0);
#endif
! com_err(whoami, errno, "; Unable to obtain AFS server directory.");
exit(2);
}
--- 410,416 ----
#ifdef AFS_NT40_ENV
ReportErrorEventAlt(AFSEVT_SVR_NO_INSTALL_DIR, 0, argv[0], 0);
#endif
! afs_com_err(whoami, errno, "; Unable to obtain AFS server directory.");
exit(2);
}
***************
*** 468,474 ****
BU_conf = afsconf_Open(globalConfPtr->cellConfigdir);
if (BU_conf == 0) {
LogError(code, "Failed getting cell info\n");
! com_err(whoami, code, "Failed getting cell info");
ERROR(BUDB_NOCELLS);
}
--- 468,474 ----
BU_conf = afsconf_Open(globalConfPtr->cellConfigdir);
if (BU_conf == 0) {
LogError(code, "Failed getting cell info\n");
! afs_com_err(whoami, code, "Failed getting cell info");
ERROR(BUDB_NOCELLS);
}
***************
*** 551,557 ****
if (code) {
LogError(code, "Ubik init failed\n");
! com_err(whoami, code, "Ubik init failed");
ERROR(code);
}
--- 551,557 ----
if (code) {
LogError(code, "Ubik init failed\n");
! afs_com_err(whoami, code, "Ubik init failed");
ERROR(code);
}
***************
*** 678,685 ****
fprintf(globalConfPtr->log, "%s ", TimeStamp(now));
if (code)
! fprintf(globalConfPtr->log, "%s: %s\n", error_table_name(code),
! error_message(code));
fprintf(globalConfPtr->log, a, b, c, d, e, f, g, h, i);
fflush(globalConfPtr->log);
fclose(globalConfPtr->log);
--- 678,685 ----
fprintf(globalConfPtr->log, "%s ", TimeStamp(now));
if (code)
! fprintf(globalConfPtr->log, "%s: %s\n", afs_error_table_name(code),
! afs_error_message(code));
fprintf(globalConfPtr->log, a, b, c, d, e, f, g, h, i);
fflush(globalConfPtr->log);
fclose(globalConfPtr->log);
Index: openafs/src/butc/butc_xbsa.c
diff -c openafs/src/butc/butc_xbsa.c:1.8 openafs/src/butc/butc_xbsa.c:1.8.2.1
*** openafs/src/butc/butc_xbsa.c:1.8 Wed Jul 14 00:46:48 2004
--- openafs/src/butc/butc_xbsa.c Mon Jul 16 16:43:31 2007
***************
*** 13,19 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/butc/butc_xbsa.c,v 1.8 2004/07/14 04:46:48 shadow Exp $");
#include
#include
--- 13,19 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/butc/butc_xbsa.c,v 1.8.2.1 2007/07/16 20:43:31 shadow Exp $");
#include
#include
***************
*** 132,138 ****
RTLD_NOW | RTLD_LOCAL | RTLD_MEMBER);
}
#elif defined(AFS_SUN5_ENV)
! dynlib = dlopen("/usr/lib/libXApi.so", RTLD_NOW | RTLD_LOCAL);
#else
dynlib = NULL;
#endif
--- 132,139 ----
RTLD_NOW | RTLD_LOCAL | RTLD_MEMBER);
}
#elif defined(AFS_SUN5_ENV)
! dlopen ("/usr/lib/libCstd.so.1", RTLD_NOW | RTLD_GLOBAL);
! dynlib = dlopen("/usr/lib/libXApi.so", RTLD_NOW | RTLD_GLOBAL);
#else
dynlib = NULL;
#endif
Index: openafs/src/butc/lwps.c
diff -c openafs/src/butc/lwps.c:1.12.2.2 openafs/src/butc/lwps.c:1.12.2.3
*** openafs/src/butc/lwps.c:1.12.2.2 Mon Jul 11 15:29:36 2005
--- openafs/src/butc/lwps.c Tue Apr 10 14:43:41 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/butc/lwps.c,v 1.12.2.2 2005/07/11 19:29:36 shadow Exp $");
#include
#ifdef AFS_NT40_ENV
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/butc/lwps.c,v 1.12.2.3 2007/04/10 18:43:41 shadow Exp $");
#include
#ifdef AFS_NT40_ENV
***************
*** 175,182 ****
err1 = "Volume has moved to another server";
break;
default:
! err1 = (char *)error_message(error1);
! err2 = (char *)error_table_name(error1);
break;
}
if (error1 == -1)
--- 175,182 ----
err1 = "Volume has moved to another server";
break;
default:
! err1 = (char *)afs_error_message(error1);
! err2 = (char *)afs_error_table_name(error1);
break;
}
if (error1 == -1)
***************
*** 184,190 ****
else
fprintf(log, " %s: %s", err2, err1);
if (error2)
! fprintf(log, ": %s", error_message(error2));
fprintf(log, "\n");
}
fflush(log);
--- 184,190 ----
else
fprintf(log, " %s: %s", err2, err1);
if (error2)
! fprintf(log, ": %s", afs_error_message(error2));
fprintf(log, "\n");
}
fflush(log);
***************
*** 573,579 ****
}
if (rcpid == -1 && errno != EINTR) {
tapemounted = 0;
! com_err(whoami, errno,
"Error waiting for callout script to terminate.");
break;
}
--- 573,579 ----
}
if (rcpid == -1 && errno != EINTR) {
tapemounted = 0;
! afs_com_err(whoami, errno,
"Error waiting for callout script to terminate.");
break;
}
***************
*** 737,743 ****
}
/* if waitpid experienced an error, we prompt */
if (rcpid == -1 && errno != EINTR) {
! com_err(whoami, errno,
"Error waiting for callout script to terminate.");
TLog(taskId,
"Can't get exit status from callout script. will prompt\n");
--- 737,743 ----
}
/* if waitpid experienced an error, we prompt */
if (rcpid == -1 && errno != EINTR) {
! afs_com_err(whoami, errno,
"Error waiting for callout script to terminate.");
TLog(taskId,
"Can't get exit status from callout script. will prompt\n");
Index: openafs/src/butm/butm_test.c
diff -c openafs/src/butm/butm_test.c:1.8 openafs/src/butm/butm_test.c:1.8.2.1
*** openafs/src/butm/butm_test.c:1.8 Tue Jul 15 19:14:49 2003
--- openafs/src/butm/butm_test.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/butm_test.c,v 1.8 2003/07/15 23:14:49 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/butm_test.c,v 1.8.2.1 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 34,40 ****
if (code != err) \
{ \
printf("FAILURE: expected %u; got %u\n", err, code); \
! if (code) com_err(whoami, code, ""); \
} \
else printf("PASSED; got %u\n", err); \
printf("\n");
--- 34,40 ----
if (code != err) \
{ \
printf("FAILURE: expected %u; got %u\n", err, code); \
! if (code) afs_com_err(whoami, code, ""); \
} \
else printf("PASSED; got %u\n", err); \
printf("\n");
***************
*** 43,49 ****
{ \
printf("TEST: %s\n", str); \
printf("FAILURE: expected %u; got %u\n", err, code); \
! if (code) com_err(whoami, code, ""); \
printf("\n"); \
}
#define NOREWIND 0
--- 43,49 ----
{ \
printf("TEST: %s\n", str); \
printf("FAILURE: expected %u; got %u\n", err, code); \
! if (code) afs_com_err(whoami, code, ""); \
printf("\n"); \
}
#define NOREWIND 0
Index: openafs/src/butm/file_tm.c
diff -c openafs/src/butm/file_tm.c:1.11.2.1 openafs/src/butm/file_tm.c:1.11.2.2
*** openafs/src/butm/file_tm.c:1.11.2.1 Sun Apr 3 14:15:47 2005
--- openafs/src/butm/file_tm.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/file_tm.c,v 1.11.2.1 2005/04/03 18:15:47 shadow Exp $");
#ifdef AFS_NT40_ENV
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/file_tm.c,v 1.11.2.2 2007/04/10 18:43:42 shadow Exp $");
#ifdef AFS_NT40_ENV
#include
***************
*** 1752,1758 ****
struct tapeConfig *file;
{
if (!file) {
! com_err(whoami, BUTM_BADCONFIG, "device not specified");
return BUTM_BADCONFIG;
}
--- 1752,1758 ----
struct tapeConfig *file;
{
if (!file) {
! afs_com_err(whoami, BUTM_BADCONFIG, "device not specified");
return BUTM_BADCONFIG;
}
***************
*** 1763,1775 ****
/* Tape must be large enough to at least fit a label */
if (config.tapeSize <= 0) {
! com_err(whoami, BUTM_BADCONFIG, "Tape size bogus: %d Kbytes",
config.tapeSize);
return BUTM_BADCONFIG;
}
if (strlen(config.tapedir) == 0) {
! com_err(whoami, BUTM_BADCONFIG, "no tape device specified");
return BUTM_BADCONFIG;
}
--- 1763,1775 ----
/* Tape must be large enough to at least fit a label */
if (config.tapeSize <= 0) {
! afs_com_err(whoami, BUTM_BADCONFIG, "Tape size bogus: %d Kbytes",
config.tapeSize);
return BUTM_BADCONFIG;
}
if (strlen(config.tapedir) == 0) {
! afs_com_err(whoami, BUTM_BADCONFIG, "no tape device specified");
return BUTM_BADCONFIG;
}
Index: openafs/src/butm/test_ftm.c
diff -c openafs/src/butm/test_ftm.c:1.10.2.1 openafs/src/butm/test_ftm.c:1.10.2.2
*** openafs/src/butm/test_ftm.c:1.10.2.1 Mon Oct 18 03:11:52 2004
--- openafs/src/butm/test_ftm.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/test_ftm.c,v 1.10.2.1 2004/10/18 07:11:52 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/butm/test_ftm.c,v 1.10.2.2 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 131,144 ****
else if (strncmp(argv[i], "-tapename", strlen(argv[i])) == 0)
tape = argv[++i];
else {
! com_err(whoami, 0, "unexpected command argument: '%s'",
argv[i]);
goto usage;
}
} else {
struct stat buf;
if (stat(argv[i], &buf)) {
! com_err(whoami, errno, "can't stat filename parameter %s\n",
argv[i]);
} else {
if ((buf.st_mode & S_IFREG) && (buf.st_mode & 0444))
--- 131,144 ----
else if (strncmp(argv[i], "-tapename", strlen(argv[i])) == 0)
tape = argv[++i];
else {
! afs_com_err(whoami, 0, "unexpected command argument: '%s'",
argv[i]);
goto usage;
}
} else {
struct stat buf;
if (stat(argv[i], &buf)) {
! afs_com_err(whoami, errno, "can't stat filename parameter %s\n",
argv[i]);
} else {
if ((buf.st_mode & S_IFREG) && (buf.st_mode & 0444))
***************
*** 152,163 ****
goto usage;
if ((strlen(tape) == 0) || (strlen(tape) >= BU_MAXTAPELEN)) {
! com_err(whoami, 0, "bogus tape name");
goto usage;
}
code = GetDeviceInfo(config, &confInfo);
if (code) {
! com_err(whoami, 0, "cant find tape config info");
goto usage;
}
--- 152,163 ----
goto usage;
if ((strlen(tape) == 0) || (strlen(tape) >= BU_MAXTAPELEN)) {
! afs_com_err(whoami, 0, "bogus tape name");
goto usage;
}
code = GetDeviceInfo(config, &confInfo);
if (code) {
! afs_com_err(whoami, 0, "cant find tape config info");
goto usage;
}
***************
*** 169,180 ****
printf("%s: Beginning Dump Tests\n", whoami);
code = LWP_InitializeProcessSupport(1, &parent_pid);
if (code) {
! com_err(whoami, code, "Can't init LWP lib");
exit(1);
}
code = IOMGR_Initialize();
if (code) {
! com_err(whoami, code, "Can't init LWP IOMGR lib");
exit(1);
}
/* Perform normal test */
--- 169,180 ----
printf("%s: Beginning Dump Tests\n", whoami);
code = LWP_InitializeProcessSupport(1, &parent_pid);
if (code) {
! afs_com_err(whoami, code, "Can't init LWP lib");
exit(1);
}
code = IOMGR_Initialize();
if (code) {
! afs_com_err(whoami, code, "Can't init LWP IOMGR lib");
exit(1);
}
/* Perform normal test */
***************
*** 182,188 ****
LWP_CreateProcess(PerformDumpTest, 100000, 0, (void *)&ti,
"BUTM Tester", &pid);
if (code) {
! com_err(whoami, code, "libbutm.a: Normal Tests failed!. :-( ");
exit(code);
}
LWP_WaitProcess(&ti.dumpDone);
--- 182,188 ----
LWP_CreateProcess(PerformDumpTest, 100000, 0, (void *)&ti,
"BUTM Tester", &pid);
if (code) {
! afs_com_err(whoami, code, "libbutm.a: Normal Tests failed!. :-( ");
exit(code);
}
LWP_WaitProcess(&ti.dumpDone);
***************
*** 195,201 ****
LWP_CreateProcess(PerformDumpTest, 100000, 0, (void *)&ti,
"BUTM Tester", &pid);
if (code) {
! com_err(whoami, code, "libbutm.a: Appended Tests failed!. :-( ");
exit(code);
}
--- 195,201 ----
LWP_CreateProcess(PerformDumpTest, 100000, 0, (void *)&ti,
"BUTM Tester", &pid);
if (code) {
! afs_com_err(whoami, code, "libbutm.a: Appended Tests failed!. :-( ");
exit(code);
}
***************
*** 228,234 ****
info.structVersion = BUTM_MAJORVERSION;
if (code = butm_file_Instantiate(&info, tip->tc_Infop)) {
! com_err(whoami, code, "instantiating file tape");
ERROR_EXIT(2);
}
--- 228,234 ----
info.structVersion = BUTM_MAJORVERSION;
if (code = butm_file_Instantiate(&info, tip->tc_Infop)) {
! afs_com_err(whoami, code, "instantiating file tape");
ERROR_EXIT(2);
}
***************
*** 251,269 ****
strcpy(label.comment, T_COMMENT);
if (code = butm_Mount(&info, tip->tapeName)) {
! com_err(whoami, code, "setting up tape");
ERROR_EXIT(2);
}
if (tip->appended) { /* This is to be an appended dump */
code = butm_SeekEODump(&info, tip->nFiles + 1);
if (code) {
! com_err(whoami, code,
"Can't append: Can't position to end of dump on tape\n");
ERROR_EXIT(code);
}
}
if ((code = butm_Create(&info, &label, !tip->appended /*Rewind */ ))) {
! com_err(whoami, code, "Writing tape label");
ERROR_EXIT(2);
}
--- 251,269 ----
strcpy(label.comment, T_COMMENT);
if (code = butm_Mount(&info, tip->tapeName)) {
! afs_com_err(whoami, code, "setting up tape");
ERROR_EXIT(2);
}
if (tip->appended) { /* This is to be an appended dump */
code = butm_SeekEODump(&info, tip->nFiles + 1);
if (code) {
! afs_com_err(whoami, code,
"Can't append: Can't position to end of dump on tape\n");
ERROR_EXIT(code);
}
}
if ((code = butm_Create(&info, &label, !tip->appended /*Rewind */ ))) {
! afs_com_err(whoami, code, "Writing tape label");
ERROR_EXIT(2);
}
***************
*** 272,305 ****
int len;
int fid = open(tip->files[i], O_RDONLY, 0);
if (fid < 0) {
! com_err(whoami, errno, "opening file to write on tape");
ERROR_EXIT(3);
}
if (code = butm_WriteFileBegin(&info)) {
! com_err(whoami, code, "beginning butm write file");
ERROR_EXIT(3);
}
while ((len = read(fid, bufferBlock->data, BUTM_BLKSIZE)) > 0) {
if (code = butm_WriteFileData(&info, bufferBlock->data, 1, len)) {
! com_err(whoami, code, "butm writing file data");
ERROR_EXIT(3);
}
}
if (len < 0) {
! com_err(whoami, errno, "reading file data");
ERROR_EXIT(3);
}
if (code = butm_WriteFileEnd(&info)) {
! com_err(whoami, code, "ending butm write file");
ERROR_EXIT(3);
}
if (close(fid) < 0) {
! com_err(whoami, errno, "closing file");
ERROR_EXIT(3);
}
}
if ((code = butm_WriteEOT(&info)) || (code = butm_Dismount(&info))) {
! com_err(whoami, code, "finishing up tape");
ERROR_EXIT(4);
}
--- 272,305 ----
int len;
int fid = open(tip->files[i], O_RDONLY, 0);
if (fid < 0) {
! afs_com_err(whoami, errno, "opening file to write on tape");
ERROR_EXIT(3);
}
if (code = butm_WriteFileBegin(&info)) {
! afs_com_err(whoami, code, "beginning butm write file");
ERROR_EXIT(3);
}
while ((len = read(fid, bufferBlock->data, BUTM_BLKSIZE)) > 0) {
if (code = butm_WriteFileData(&info, bufferBlock->data, 1, len)) {
! afs_com_err(whoami, code, "butm writing file data");
ERROR_EXIT(3);
}
}
if (len < 0) {
! afs_com_err(whoami, errno, "reading file data");
ERROR_EXIT(3);
}
if (code = butm_WriteFileEnd(&info)) {
! afs_com_err(whoami, code, "ending butm write file");
ERROR_EXIT(3);
}
if (close(fid) < 0) {
! afs_com_err(whoami, errno, "closing file");
ERROR_EXIT(3);
}
}
if ((code = butm_WriteEOT(&info)) || (code = butm_Dismount(&info))) {
! afs_com_err(whoami, code, "finishing up tape");
ERROR_EXIT(4);
}
***************
*** 307,325 ****
label.structVersion = BUTM_MAJORVERSION;
if (code = butm_Mount(&info, tip->tapeName)) {
! com_err(whoami, code, "setting up tape");
ERROR_EXIT(5);
}
if (tip->appended) { /* This is to be an appended dump */
code = butm_SeekEODump(&info, tip->nFiles + 1);
if (code) {
! com_err(whoami, code,
"Can't append: Can't position to end of dump on tape\n");
ERROR_EXIT(code);
}
}
if (code = butm_ReadLabel(&info, &label, !tip->appended /*rewind */ )) {
! com_err(whoami, code, "reading tape label");
ERROR_EXIT(5);
}
past = time(0) - label.creationTime;
--- 307,325 ----
label.structVersion = BUTM_MAJORVERSION;
if (code = butm_Mount(&info, tip->tapeName)) {
! afs_com_err(whoami, code, "setting up tape");
ERROR_EXIT(5);
}
if (tip->appended) { /* This is to be an appended dump */
code = butm_SeekEODump(&info, tip->nFiles + 1);
if (code) {
! afs_com_err(whoami, code,
"Can't append: Can't position to end of dump on tape\n");
ERROR_EXIT(code);
}
}
if (code = butm_ReadLabel(&info, &label, !tip->appended /*rewind */ )) {
! afs_com_err(whoami, code, "reading tape label");
ERROR_EXIT(5);
}
past = time(0) - label.creationTime;
***************
*** 359,370 ****
fid = open(tip->files[i], O_RDONLY, 0);
if (fid < 0) {
! com_err(whoami, errno, "Opening %dth file to compare with tape",
i + 1);
ERROR_EXIT(6);
}
if (code = butm_ReadFileBegin(&info)) {
! com_err(whoami, code, "Beginning butm %dth read file", i + 1);
ERROR_EXIT(6);
}
--- 359,370 ----
fid = open(tip->files[i], O_RDONLY, 0);
if (fid < 0) {
! afs_com_err(whoami, errno, "Opening %dth file to compare with tape",
i + 1);
ERROR_EXIT(6);
}
if (code = butm_ReadFileBegin(&info)) {
! afs_com_err(whoami, code, "Beginning butm %dth read file", i + 1);
ERROR_EXIT(6);
}
***************
*** 374,386 ****
code = butm_ReadFileData(&info, tbuffer, BUTM_BLKSIZE, &tlen);
if (code && code != BUTM_STATUS_EOF) {
! com_err(whoami, code, "Reading %dth tape data", i + 1);
ERROR_EXIT(6);
}
memset(fbuffer, 0, BUTM_BLKSIZE);
flen = read(fid, fbuffer, sizeof(fbuffer));
if (flen < 0) {
! com_err(whoami, errno, "Reading %dth file data", i + 1);
ERROR_EXIT(6);
}
if (code == BUTM_STATUS_EOF)
--- 374,386 ----
code = butm_ReadFileData(&info, tbuffer, BUTM_BLKSIZE, &tlen);
if (code && code != BUTM_STATUS_EOF) {
! afs_com_err(whoami, code, "Reading %dth tape data", i + 1);
ERROR_EXIT(6);
}
memset(fbuffer, 0, BUTM_BLKSIZE);
flen = read(fid, fbuffer, sizeof(fbuffer));
if (flen < 0) {
! afs_com_err(whoami, errno, "Reading %dth file data", i + 1);
ERROR_EXIT(6);
}
if (code == BUTM_STATUS_EOF)
***************
*** 402,412 ****
}
if (code = butm_ReadFileEnd(&info)) {
! com_err(whoami, code, "Ending butm %dth read file", i + 1);
ERROR_EXIT(7);
}
if (close(fid) < 0) {
! com_err(whoami, errno, "Closing %dth file", i + 1);
ERROR_EXIT(7);
}
}
--- 402,412 ----
}
if (code = butm_ReadFileEnd(&info)) {
! afs_com_err(whoami, code, "Ending butm %dth read file", i + 1);
ERROR_EXIT(7);
}
if (close(fid) < 0) {
! afs_com_err(whoami, errno, "Closing %dth file", i + 1);
ERROR_EXIT(7);
}
}
***************
*** 414,425 ****
if ((info.status & BUTM_STATUS_EOD) == 0) {
code = butm_ReadFileBegin(&info);
if (code && (code != BUTM_EOD)) {
! com_err(whoami, code, "Should have encountered an 'End Of Tape'");
ERROR_EXIT(8);
}
}
if (code = butm_Dismount(&info)) {
! com_err(whoami, code, "Finishing up tape");
ERROR_EXIT(8);
}
--- 414,425 ----
if ((info.status & BUTM_STATUS_EOD) == 0) {
code = butm_ReadFileBegin(&info);
if (code && (code != BUTM_EOD)) {
! afs_com_err(whoami, code, "Should have encountered an 'End Of Tape'");
ERROR_EXIT(8);
}
}
if (code = butm_Dismount(&info)) {
! afs_com_err(whoami, code, "Finishing up tape");
ERROR_EXIT(8);
}
Index: openafs/src/cf/kerberos.m4
diff -c openafs/src/cf/kerberos.m4:1.1.2.10 openafs/src/cf/kerberos.m4:1.1.2.11
*** openafs/src/cf/kerberos.m4:1.1.2.10 Thu Jan 4 22:22:01 2007
--- openafs/src/cf/kerberos.m4 Wed Oct 10 13:47:59 2007
***************
*** 1,5 ****
dnl
! dnl $Id: kerberos.m4,v 1.1.2.10 2007/01/05 03:22:01 shadow Exp $
dnl
dnl Kerberos autoconf glue
dnl
--- 1,5 ----
dnl
! dnl $Id: kerberos.m4,v 1.1.2.11 2007/10/10 17:47:59 shadow Exp $
dnl
dnl Kerberos autoconf glue
dnl
***************
*** 58,64 ****
CPPFLAGS="$CPPFLAGS $KRB5CFLAGS"
save_LIBS="$LIBS"
LIBS="$LIBS $KRB5LIBS"
! AC_CHECK_FUNCS([add_to_error_table add_error_table krb5_princ_size krb5_principal_get_comp_string])
AC_CHECK_FUNCS([krb5_524_convert_creds], ,
[AC_CHECK_FUNCS([krb524_convert_creds_kdc], ,
[AC_CHECK_LIB([krb524], [krb524_convert_creds_kdc],
--- 58,64 ----
CPPFLAGS="$CPPFLAGS $KRB5CFLAGS"
save_LIBS="$LIBS"
LIBS="$LIBS $KRB5LIBS"
! AC_CHECK_FUNCS([add_to_error_table add_error_table krb5_princ_size krb5_principal_get_comp_string encode_krb5_enc_tkt_part encode_krb5_ticket])
AC_CHECK_FUNCS([krb5_524_convert_creds], ,
[AC_CHECK_FUNCS([krb524_convert_creds_kdc], ,
[AC_CHECK_LIB([krb524], [krb524_convert_creds_kdc],
Index: openafs/src/cf/linux-test2.m4
diff -c openafs/src/cf/linux-test2.m4:1.9.2.4 openafs/src/cf/linux-test2.m4:1.9.2.5
*** openafs/src/cf/linux-test2.m4:1.9.2.4 Mon Aug 14 18:04:41 2006
--- openafs/src/cf/linux-test2.m4 Tue Jun 12 14:41:09 2007
***************
*** 10,13 ****
--- 10,14 ----
cp $tmpldir/osi_vfs.hin $outputdir/osi_vfs.h
# chmod +x $configdir/make_vnode.pl
# $configdir/make_vnode.pl -i $LINUX_KERNEL_PATH -t ${tmpldir} -o $outputdir
+ AC_MSG_RESULT(yes)
])
Index: openafs/src/cf/linux-test4.m4
diff -c openafs/src/cf/linux-test4.m4:1.20.2.29 openafs/src/cf/linux-test4.m4:1.20.2.33
*** openafs/src/cf/linux-test4.m4:1.20.2.29 Mon Feb 26 12:53:33 2007
--- openafs/src/cf/linux-test4.m4 Tue Jun 12 14:35:49 2007
***************
*** 444,449 ****
--- 444,461 ----
AC_MSG_RESULT($ac_cv_linux_sched_struct_task_struct_has_exit_state)])
+ AC_DEFUN([LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_THREAD_INFO], [
+ AC_MSG_CHECKING([for thread_info in struct task_struct])
+ AC_CACHE_VAL([ac_cv_linux_sched_struct_task_struct_has_thread_info], [
+ AC_TRY_KBUILD(
+ [#include ],
+ [struct task_struct _tsk;
+ printk("%d\n", _tsk.thread_info);],
+ ac_cv_linux_sched_struct_task_struct_has_thread_info=yes,
+ ac_cv_linux_sched_struct_task_struct_has_thread_info=no)])
+ AC_MSG_RESULT($ac_cv_linux_sched_struct_task_struct_has_thread_info)])
+
+
AC_DEFUN([LINUX_FS_STRUCT_SUPER_HAS_ALLOC_INODE], [
AC_MSG_CHECKING([for alloc_inode in struct super_operations])
AC_CACHE_VAL([ac_cv_linux_fs_struct_super_has_alloc_inode], [
***************
*** 456,461 ****
--- 468,484 ----
AC_MSG_RESULT($ac_cv_linux_fs_struct_super_has_alloc_inode)])
+ AC_DEFUN([LINUX_KERNEL_POSIX_LOCK_FILE_WAIT_ARG], [
+ AC_MSG_CHECKING([for 3rd argument in posix_lock_file found in new kernels])
+ AC_CACHE_VAL([ac_cv_linux_kernel_posix_lock_file_wait_arg], [
+ AC_TRY_KBUILD(
+ [#include ],
+ [posix_lock_file(0,0,0);],
+ ac_cv_linux_kernel_posix_lock_file_wait_arg=yes,
+ ac_cv_linux_kernel_posix_lock_file_wait_arg=no)])
+ AC_MSG_RESULT($ac_cv_linux_kernel_posix_lock_file_wait_arg)])
+
+
AC_DEFUN([LINUX_KERNEL_SOCK_CREATE], [
AC_MSG_CHECKING([for 5th argument in sock_create found in some SELinux kernels])
AC_CACHE_VAL([ac_cv_linux_kernel_sock_create_v], [
***************
*** 644,649 ****
--- 667,688 ----
AC_MSG_RESULT($ac_cv_linux_func_i_permission_takes_nameidata)])
+ AC_DEFUN([LINUX_IOP_I_PUT_LINK_TAKES_COOKIE], [
+ AC_MSG_CHECKING([whether inode_operations.put_link takes an opaque cookie])
+ AC_CACHE_VAL([ac_cv_linux_func_i_put_link_takes_cookie], [
+ AC_TRY_KBUILD(
+ [#include
+ #include ],
+ [struct inode _inode;
+ struct dentry _dentry;
+ struct nameidata _nameidata;
+ void *cookie;
+ (void)_inode.i_op->put_link(&_dentry, &_nameidata, cookie);],
+ ac_cv_linux_func_i_put_link_takes_cookie=yes,
+ ac_cv_linux_func_i_put_link_takes_cookie=no)])
+ AC_MSG_RESULT($ac_cv_linux_func_i_put_link_takes_cookie)])
+
+
AC_DEFUN([LINUX_DOP_D_REVALIDATE_TAKES_NAMEIDATA], [
AC_MSG_CHECKING([whether dentry_operations.d_revalidate takes a nameidata])
AC_CACHE_VAL([ac_cv_linux_func_d_revalidate_takes_nameidata], [
***************
*** 811,813 ****
--- 850,865 ----
ac_cv_linux_register_sysctl_table_noflag=no)])
AC_MSG_RESULT($ac_cv_linux_register_sysctl_table_noflag)])
+ AC_DEFUN([LINUX_FOP_F_FLUSH_TAKES_FL_OWNER_T], [
+ AC_MSG_CHECKING([whether file_operations.flush takes a fl_owner_t])
+ AC_CACHE_VAL([ac_cv_linux_func_f_flush_takes_fl_owner_t], [
+ AC_TRY_KBUILD(
+ [#include ],
+ [struct inode _inode;
+ struct file _file;
+ fl_owner_t id;
+ (void)_inode.i_fop->flush(&_file, &id);],
+ ac_cv_linux_func_f_flush_takes_fl_owner_t=yes,
+ ac_cv_linux_func_f_flush_takes_fl_owner_t=no)])
+ AC_MSG_RESULT($ac_cv_linux_func_f_flush_takes_fl_owner_t)])
+
Index: openafs/src/cf/osconf.m4
diff -c openafs/src/cf/osconf.m4:1.51.2.28 openafs/src/cf/osconf.m4:1.51.2.30
*** openafs/src/cf/osconf.m4:1.51.2.28 Thu Dec 28 16:59:45 2006
--- openafs/src/cf/osconf.m4 Wed Oct 10 13:47:59 2007
***************
*** 448,454 ****
;;
*_darwin_80)
! AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration"
LEX="lex -l"
MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
KROOT=
--- 448,454 ----
;;
*_darwin_80)
! AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
LEX="lex -l"
MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
KROOT=
***************
*** 461,470 ****
EXTRA_VLIBOBJS="fstab.o"
SHLIB_LINKER="${MT_CC} -dynamiclib"
SHLIB_SUFFIX="dylib"
;;
*_darwin_90)
! AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration"
LEX="lex -l"
MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
KROOT=
--- 461,471 ----
EXTRA_VLIBOBJS="fstab.o"
SHLIB_LINKER="${MT_CC} -dynamiclib"
SHLIB_SUFFIX="dylib"
+ RANLIB="ranlib -c"
;;
*_darwin_90)
! AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
LEX="lex -l"
MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
KROOT=
***************
*** 478,483 ****
--- 479,485 ----
EXTRA_VLIBOBJS="fstab.o"
SHLIB_LINKER="${MT_CC} -dynamiclib"
SHLIB_SUFFIX="dylib"
+ RANLIB="ranlib -c"
;;
ppc_linux*)
Index: openafs/src/cmd/test/itest.c
diff -c openafs/src/cmd/test/itest.c:1.7 openafs/src/cmd/test/itest.c:1.7.2.1
*** openafs/src/cmd/test/itest.c:1.7 Tue Jul 15 19:14:52 2003
--- openafs/src/cmd/test/itest.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/cmd/test/itest.c,v 1.7 2003/07/15 23:14:52 shadow Exp $");
#include "cmd.h"
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/cmd/test/itest.c,v 1.7.2.1 2007/04/10 18:43:42 shadow Exp $");
#include "cmd.h"
#include
***************
*** 84,96 ****
break;
code = cmd_ParseLine(tline, tv, &tc, 100);
if (code) {
! printf("itest: parsing failure: %s\n", error_message(code));
exit(1);
}
code = cmd_Dispatch(tc, tv);
cmd_FreeArgv(tv);
if (code) {
! printf("itest: execution failed: %s\n", error_message(code));
}
}
return 0;
--- 84,96 ----
break;
code = cmd_ParseLine(tline, tv, &tc, 100);
if (code) {
! printf("itest: parsing failure: %s\n", afs_error_message(code));
exit(1);
}
code = cmd_Dispatch(tc, tv);
cmd_FreeArgv(tv);
if (code) {
! printf("itest: execution failed: %s\n", afs_error_message(code));
}
}
return 0;
Index: openafs/src/comerr/com_err.c
diff -c openafs/src/comerr/com_err.c:1.5 openafs/src/comerr/com_err.c:1.5.2.1
*** openafs/src/comerr/com_err.c:1.5 Tue Jul 15 19:14:53 2003
--- openafs/src/comerr/com_err.c Tue Apr 10 14:43:42 2007
***************
*** 8,14 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/com_err.c,v 1.5 2003/07/15 23:14:53 shadow Exp $");
#include "internal.h"
#include
--- 8,14 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/com_err.c,v 1.5.2.1 2007/04/10 18:43:42 shadow Exp $");
#include "internal.h"
#include
***************
*** 25,31 ****
fputs(": ", stderr);
}
if (code) {
! fputs(error_message(code), stderr);
fputs(" ", stderr);
}
if (fmt) {
--- 25,31 ----
fputs(": ", stderr);
}
if (code) {
! fputs(afs_error_message(code), stderr);
fputs(" ", stderr);
}
if (fmt) {
***************
*** 42,66 ****
static errf com_err_hook = default_com_err_proc;
void
! com_err_va(const char *whoami, afs_int32 code, const char *fmt, va_list args)
{
(*com_err_hook) (whoami, code, fmt, args);
}
void
! com_err(const char *whoami, afs_int32 code, const char *fmt, ...)
{
va_list pvar;
if (!com_err_hook)
com_err_hook = default_com_err_proc;
va_start(pvar, fmt);
! com_err_va(whoami, code, fmt, pvar);
va_end(pvar);
}
errf
! set_com_err_hook(errf new_proc)
{
errf x = com_err_hook;
if (new_proc)
--- 42,66 ----
static errf com_err_hook = default_com_err_proc;
void
! afs_com_err_va(const char *whoami, afs_int32 code, const char *fmt, va_list args)
{
(*com_err_hook) (whoami, code, fmt, args);
}
void
! afs_com_err(const char *whoami, afs_int32 code, const char *fmt, ...)
{
va_list pvar;
if (!com_err_hook)
com_err_hook = default_com_err_proc;
va_start(pvar, fmt);
! afs_com_err_va(whoami, code, fmt, pvar);
va_end(pvar);
}
errf
! afs_set_com_err_hook(errf new_proc)
{
errf x = com_err_hook;
if (new_proc)
***************
*** 71,77 ****
}
errf
! reset_com_err_hook(void)
{
errf x = com_err_hook;
com_err_hook = default_com_err_proc;
--- 71,77 ----
}
errf
! afs_reset_com_err_hook(void)
{
errf x = com_err_hook;
com_err_hook = default_com_err_proc;
Index: openafs/src/comerr/com_err.h
diff -c openafs/src/comerr/com_err.h:1.3 openafs/src/comerr/com_err.h:1.3.2.1
*** openafs/src/comerr/com_err.h:1.3 Tue Jul 15 19:14:53 2003
--- openafs/src/comerr/com_err.h Tue Apr 10 14:43:42 2007
***************
*** 8,28 ****
* with this package.
*/
! #ifndef __COM_ERR_H
#include
! extern void com_err(const char *, afs_int32, const char *, ...);
! extern void com_err_va(const char *whoami, afs_int32 code, const char *fmt,
va_list args);
! extern const char *error_table_name(afs_int32);
! extern const char *error_message(afs_int32);
extern
! void (*set_com_err_hook
(void (*)(const char *, afs_int32, const char *, va_list)))
(const char *, afs_int32, const char *, va_list);
! extern void (*reset_com_err_hook(void)) (const char *, afs_int32,
const char *, va_list);
! #define __COM_ERR_H
! #endif /* ! defined(__COM_ERR_H) */
--- 8,36 ----
* with this package.
*/
! #ifndef __AFS_COM_ERR_H
#include
! extern void afs_com_err(const char *, afs_int32, const char *, ...);
! extern void afs_com_err_va(const char *whoami, afs_int32 code, const char *fmt,
va_list args);
! extern const char *afs_error_table_name(afs_int32);
! extern const char *afs_error_message(afs_int32);
extern
! void (*afs_set_com_err_hook
(void (*)(const char *, afs_int32, const char *, va_list)))
(const char *, afs_int32, const char *, va_list);
! extern void (*afs_reset_com_err_hook(void)) (const char *, afs_int32,
const char *, va_list);
! #define __AFS_COM_ERR_H
! #ifdef AFS_OLD_COM_ERR
! #define com_err afs_com_err
! #define com_err_va afs_com_err_va
! #define error_table_name afs_error_table_name
! #define error_message afs_error_message
! #define set_com_err_hook afs_set_com_err_hook
! #define reset_com_err_hook afs_reset_com_err_hook
! #endif /* AFS_OLD_COM_ERR */
! #endif /* ! defined(__AFS_COM_ERR_H) */
Index: openafs/src/comerr/compile_et.c
diff -c openafs/src/comerr/compile_et.c:1.14 openafs/src/comerr/compile_et.c:1.14.2.1
*** openafs/src/comerr/compile_et.c:1.14 Sat Nov 29 17:08:10 2003
--- openafs/src/comerr/compile_et.c Tue Apr 10 14:43:42 2007
***************
*** 13,19 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/compile_et.c,v 1.14 2003/11/29 22:08:10 jaltman Exp $");
#include
#include
--- 13,19 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/compile_et.c,v 1.14.2.1 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 375,381 ****
fputs("static struct et_list etlink = { 0, &et};\n\n", cfile);
fprintf(cfile, "void initialize_%s_error_table(void) {\n",
table_name);
! fputs(" add_to_error_table(&etlink);\n", cfile);
fputs("}\n", cfile);
fclose(cfile);
--- 375,381 ----
fputs("static struct et_list etlink = { 0, &et};\n\n", cfile);
fprintf(cfile, "void initialize_%s_error_table(void) {\n",
table_name);
! fputs(" afs_add_to_error_table(&etlink);\n", cfile);
fputs("}\n", cfile);
fclose(cfile);
Index: openafs/src/comerr/error_msg.c
diff -c openafs/src/comerr/error_msg.c:1.5.2.1 openafs/src/comerr/error_msg.c:1.5.2.2
*** openafs/src/comerr/error_msg.c:1.5.2.1 Wed Aug 25 03:09:36 2004
--- openafs/src/comerr/error_msg.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/error_msg.c,v 1.5.2.1 2004/08/25 07:09:36 shadow Exp $");
#include "internal.h"
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/error_msg.c,v 1.5.2.2 2007/04/10 18:43:42 shadow Exp $");
#include "internal.h"
#include
***************
*** 45,51 ****
* Function to initialize the et_list_mutex
*/
! void
et_mutex_once(void)
{
assert(!pthread_mutex_init
--- 45,51 ----
* Function to initialize the et_list_mutex
*/
! static void
et_mutex_once(void)
{
assert(!pthread_mutex_init
***************
*** 110,116 ****
}
const char *
! error_message(afs_int32 code)
{
int offset;
struct et_list *et;
--- 110,116 ----
}
const char *
! afs_error_message(afs_int32 code)
{
int offset;
struct et_list *et;
***************
*** 147,153 ****
UNLOCK_ET_LIST;
strcpy(buffer, "Unknown code ");
if (table_num) {
! strcat(buffer, error_table_name(table_num));
strcat(buffer, " ");
}
for (cp = buffer; *cp; cp++);
--- 147,153 ----
UNLOCK_ET_LIST;
strcpy(buffer, "Unknown code ");
if (table_num) {
! strcat(buffer, afs_error_table_name(table_num));
strcat(buffer, " ");
}
for (cp = buffer; *cp; cp++);
***************
*** 169,175 ****
}
void
! add_to_error_table(struct et_list *new_table)
{
struct et_list *et;
--- 169,175 ----
}
void
! afs_add_to_error_table(struct et_list *new_table)
{
struct et_list *et;
Index: openafs/src/comerr/error_table.h
diff -c openafs/src/comerr/error_table.h:1.3 openafs/src/comerr/error_table.h:1.3.2.1
*** openafs/src/comerr/error_table.h:1.3 Tue Jul 15 19:14:53 2003
--- openafs/src/comerr/error_table.h Tue Apr 10 14:43:42 2007
***************
*** 9,15 ****
#include
! #ifndef _ET_H
struct error_table {
char const *const *msgs;
--- 9,15 ----
#include
! #ifndef _AFS_ET_H
struct error_table {
char const *const *msgs;
***************
*** 25,31 ****
#define ERRCODE_RANGE 8 /* # of bits to shift table number */
#define BITS_PER_CHAR 6 /* # bits to shift per character in name */
! extern char const *error_table_name(afs_int32 num);
! extern void add_to_error_table(struct et_list *new_table);
! #define _ET_H
#endif
--- 25,35 ----
#define ERRCODE_RANGE 8 /* # of bits to shift table number */
#define BITS_PER_CHAR 6 /* # bits to shift per character in name */
! extern char const *afs_error_table_name(afs_int32 num);
! extern void afs_add_to_error_table(struct et_list *new_table);
! #ifdef AFS_OLD_COM_ERR
! #define error_table_name afs_error_table_name
! #define add_to_error_table(X) afs_add_to_error_table(X)
! #endif /* AFS_OLD_COM_ERR */
! #define _AFS_ET_H
#endif
Index: openafs/src/comerr/et_name.c
diff -c openafs/src/comerr/et_name.c:1.5 openafs/src/comerr/et_name.c:1.5.2.1
*** openafs/src/comerr/et_name.c:1.5 Tue Jul 15 19:14:53 2003
--- openafs/src/comerr/et_name.c Tue Apr 10 14:43:42 2007
***************
*** 9,15 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/et_name.c,v 1.5 2003/07/15 23:14:53 shadow Exp $");
#include "error_table.h"
#include "mit-sipb-cr.h"
--- 9,15 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/et_name.c,v 1.5.2.1 2007/04/10 18:43:42 shadow Exp $");
#include "error_table.h"
#include "mit-sipb-cr.h"
***************
*** 26,32 ****
static char buf[6];
const char *
! error_table_name(afs_int32 num)
{
int ch;
int i;
--- 26,32 ----
static char buf[6];
const char *
! afs_error_table_name(afs_int32 num)
{
int ch;
int i;
Index: openafs/src/comerr/test/test.c
diff -c openafs/src/comerr/test/test.c:1.6 openafs/src/comerr/test/test.c:1.6.2.1
*** openafs/src/comerr/test/test.c:1.6 Tue Jul 15 19:14:54 2003
--- openafs/src/comerr/test/test.c Tue Apr 10 14:43:42 2007
***************
*** 2,8 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/test/test.c,v 1.6 2003/07/15 23:14:54 shadow Exp $");
#include
#include
--- 2,8 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/comerr/test/test.c,v 1.6.2.1 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 18,55 ****
main()
{
printf("Before initiating error table:\n\n");
! printf("Table name '%s'\n", error_table_name(KRB_MK_AP_TGTEXP));
! printf("UNIX name '%s'\n", error_table_name(EPERM));
! printf("Msg TGT-expired is '%s'\n", error_message(KRB_MK_AP_TGTEXP));
! printf("Msg EPERM is '%s'\n", error_message(EPERM));
! printf("Msg FOO_ERR is '%s'\n", error_message(FOO_ERR));
! printf("Msg {sys_nerr-1} is '%s'\n", error_message(sys_nerr - 1));
! printf("Msg {sys_nerr} is '%s'\n", error_message(sys_nerr));
! printf("With 0: tgt-expired -> %s\n", error_message(KRB_MK_AP_TGTEXP));
initialize_KRB_error_table();
initialize_KRB_error_table();
printf("KRB error table initialized: base %d (%s), name %s\n",
! ERROR_TABLE_BASE_KRB, error_message(ERROR_TABLE_BASE_KRB),
! error_table_name(ERROR_TABLE_BASE_KRB));
! printf("With krb: tgt-expired -> %s\n", error_message(KRB_MK_AP_TGTEXP));
initialize_QUUX_error_table();
printf("QUUX error table initialized: base %d (%s), name %s\n",
! ERROR_TABLE_BASE_QUUX, error_message(ERROR_TABLE_BASE_QUUX),
! error_table_name(ERROR_TABLE_BASE_QUUX));
! printf("Msg for TGT-expired is '%s'\n", error_message(KRB_MK_AP_TGTEXP));
! printf("Msg {sys_nerr-1} is '%s'\n", error_message(sys_nerr - 1));
! printf("Msg FOO_ERR is '%s'\n", error_message(FOO_ERR));
! printf("Msg KRB_SKDC_CANT is '%s'\n", error_message(KRB_SKDC_CANT));
! printf("Msg 1e6 (8B 64) is '%s'\n", error_message(1000000));
printf("\n\nCOM_ERR tests:\n");
! com_err("whoami", FOO_ERR, (char *)NULL);
! com_err("whoami", FOO_ERR, " -- message goes %s", "here");
! com_err("whoami", 0, NULL);
! com_err("whoami", 0, "error number %d\n", 0);
return 0;
}
--- 18,55 ----
main()
{
printf("Before initiating error table:\n\n");
! printf("Table name '%s'\n", afs_error_table_name(KRB_MK_AP_TGTEXP));
! printf("UNIX name '%s'\n", afs_error_table_name(EPERM));
! printf("Msg TGT-expired is '%s'\n", afs_error_message(KRB_MK_AP_TGTEXP));
! printf("Msg EPERM is '%s'\n", afs_error_message(EPERM));
! printf("Msg FOO_ERR is '%s'\n", afs_error_message(FOO_ERR));
! printf("Msg {sys_nerr-1} is '%s'\n", afs_error_message(sys_nerr - 1));
! printf("Msg {sys_nerr} is '%s'\n", afs_error_message(sys_nerr));
! printf("With 0: tgt-expired -> %s\n", afs_error_message(KRB_MK_AP_TGTEXP));
initialize_KRB_error_table();
initialize_KRB_error_table();
printf("KRB error table initialized: base %d (%s), name %s\n",
! ERROR_TABLE_BASE_KRB, afs_error_message(ERROR_TABLE_BASE_KRB),
! afs_error_table_name(ERROR_TABLE_BASE_KRB));
! printf("With krb: tgt-expired -> %s\n", afs_error_message(KRB_MK_AP_TGTEXP));
initialize_QUUX_error_table();
printf("QUUX error table initialized: base %d (%s), name %s\n",
! ERROR_TABLE_BASE_QUUX, afs_error_message(ERROR_TABLE_BASE_QUUX),
! afs_error_table_name(ERROR_TABLE_BASE_QUUX));
! printf("Msg for TGT-expired is '%s'\n", afs_error_message(KRB_MK_AP_TGTEXP));
! printf("Msg {sys_nerr-1} is '%s'\n", afs_error_message(sys_nerr - 1));
! printf("Msg FOO_ERR is '%s'\n", afs_error_message(FOO_ERR));
! printf("Msg KRB_SKDC_CANT is '%s'\n", afs_error_message(KRB_SKDC_CANT));
! printf("Msg 1e6 (8B 64) is '%s'\n", afs_error_message(1000000));
printf("\n\nCOM_ERR tests:\n");
! afs_com_err("whoami", FOO_ERR, (char *)NULL);
! afs_com_err("whoami", FOO_ERR, " -- message goes %s", "here");
! afs_com_err("whoami", 0, NULL);
! afs_com_err("whoami", 0, "error number %d\n", 0);
return 0;
}
Index: openafs/src/config/afs_args.h
diff -c openafs/src/config/afs_args.h:1.13.2.7 openafs/src/config/afs_args.h:1.13.2.8
*** openafs/src/config/afs_args.h:1.13.2.7 Wed Oct 5 01:58:34 2005
--- openafs/src/config/afs_args.h Wed Oct 10 12:57:57 2007
***************
*** 86,91 ****
--- 86,99 ----
/* For SGI, this can't interfere with any of the 64 bit inode calls. */
#define AFSOP_RXLISTENER_DAEMON 48 /* starts kernel RX listener */
+ /* skip 64 bit calls */
+ #define AFSOP_CACHEBASEDIR 50 /* cache base dir */
+ #define AFSOP_CACHEDIRS 51 /* number of files per dir */
+ #define AFSOP_CACHEFILES 52 /* number of files */
+
+ #define AFSOP_SETINT 60 /* we should just set key/value pairs
+ for things which are just ints */
+
/* these are for initialization flags */
#define AFSCALL_INIT_MEMCACHE 0x1
***************
*** 220,223 ****
--- 228,237 ----
#define SYSCALL_DEV_FNAME "/dev/openafs_ioctl"
#endif
+ #ifdef AFS_CACHE_VNODE_PATH
+ #define AFS_CACHE_CELLS_INODE -2
+ #define AFS_CACHE_ITEMS_INODE -3
+ #define AFS_CACHE_VOLUME_INODE -4
+ #endif
+
#endif /* _AFS_ARGS_H_ */
Index: openafs/src/config/param.ia64_linux24.h
diff -c openafs/src/config/param.ia64_linux24.h:1.9.2.4 openafs/src/config/param.ia64_linux24.h:1.9.2.5
*** openafs/src/config/param.ia64_linux24.h:1.9.2.4 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ia64_linux24.h Tue Apr 3 15:31:27 2007
***************
*** 87,92 ****
--- 87,93 ----
#endif
#endif /* KERNEL */
+ #define USE_UCONTEXT /* should be in afsconfig.h */
#endif /* _PARAM_IA64_LINUX20_H_ */
***************
*** 157,162 ****
--- 158,164 ----
#define CMSERVERPREF
#endif
+ #define USE_UCONTEXT /* should be in afsconfig.h */
#endif /* AFS_PARAM_H */
Index: openafs/src/config/param.ia64_linux26.h
diff -c openafs/src/config/param.ia64_linux26.h:1.1.2.6 openafs/src/config/param.ia64_linux26.h:1.1.2.7
*** openafs/src/config/param.ia64_linux26.h:1.1.2.6 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ia64_linux26.h Tue Apr 3 15:31:27 2007
***************
*** 96,101 ****
--- 96,102 ----
#endif
#endif /* KERNEL */
+ #define USE_UCONTEXT /* should be in afsconfig.h */
#endif /* _PARAM_IA64_LINUX20_H_ */
***************
*** 167,172 ****
--- 168,174 ----
#define CMSERVERPREF
#endif
+ #define USE_UCONTEXT /* should be in afsconfig.h */
#endif /* AFS_PARAM_H */
Index: openafs/src/config/param.ppc64_linux24.h
diff -c openafs/src/config/param.ppc64_linux24.h:1.2.2.4 openafs/src/config/param.ppc64_linux24.h:1.2.2.5
*** openafs/src/config/param.ppc64_linux24.h:1.2.2.4 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ppc64_linux24.h Wed Jun 6 13:33:50 2007
***************
*** 75,80 ****
--- 75,86 ----
#endif
#endif /* KERNEL */
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* _PARAM_PPC64_LINUX20_H_ */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.ppc64_linux26.h
diff -c openafs/src/config/param.ppc64_linux26.h:1.1.2.5 openafs/src/config/param.ppc64_linux26.h:1.1.2.6
*** openafs/src/config/param.ppc64_linux26.h:1.1.2.5 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ppc64_linux26.h Wed Jun 6 13:33:50 2007
***************
*** 76,81 ****
--- 76,87 ----
#endif
#endif /* KERNEL */
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* _PARAM_PPC64_LINUX20_H_ */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.ppc_darwin_90.h
diff -c openafs/src/config/param.ppc_darwin_90.h:1.1.2.2 openafs/src/config/param.ppc_darwin_90.h:1.1.2.3
*** openafs/src/config/param.ppc_darwin_90.h:1.1.2.2 Thu Mar 9 01:41:42 2006
--- openafs/src/config/param.ppc_darwin_90.h Wed Oct 10 12:57:57 2007
***************
*** 30,35 ****
--- 30,36 ----
#define AFS_SYSCALL 230
#define AFS_NAMEI_ENV 1
#define DARWIN_REFBASE 3
+ #define AFS_CACHE_VNODE_PATH
/* File system entry (used if mount.h doesn't define MOUNT_AFS */
#define AFS_MOUNT_AFS "afs"
Index: openafs/src/config/param.ppc_linux24.h
diff -c openafs/src/config/param.ppc_linux24.h:1.10.2.4 openafs/src/config/param.ppc_linux24.h:1.10.2.5
*** openafs/src/config/param.ppc_linux24.h:1.10.2.4 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ppc_linux24.h Wed Jun 6 13:33:50 2007
***************
*** 72,77 ****
--- 72,83 ----
#endif
#endif /* KERNEL */
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* AFS_PARAM_H */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.ppc_linux26.h
diff -c openafs/src/config/param.ppc_linux26.h:1.1.2.5 openafs/src/config/param.ppc_linux26.h:1.1.2.6
*** openafs/src/config/param.ppc_linux26.h:1.1.2.5 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.ppc_linux26.h Wed Jun 6 13:33:50 2007
***************
*** 74,79 ****
--- 74,85 ----
#endif
#endif /* KERNEL */
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* AFS_PARAM_H */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.sparc64_linux24.h
diff -c openafs/src/config/param.sparc64_linux24.h:1.7.2.4 openafs/src/config/param.sparc64_linux24.h:1.7.2.5
*** openafs/src/config/param.sparc64_linux24.h:1.7.2.4 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.sparc64_linux24.h Wed Jun 6 13:33:50 2007
***************
*** 94,99 ****
--- 94,105 ----
#endif
#endif
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* _PARAM_SPARC64_LINUX24_H_ */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.sparc64_linux26.h
diff -c openafs/src/config/param.sparc64_linux26.h:1.1.4.5 openafs/src/config/param.sparc64_linux26.h:1.1.4.6
*** openafs/src/config/param.sparc64_linux26.h:1.1.4.5 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.sparc64_linux26.h Wed Jun 6 13:33:50 2007
***************
*** 95,100 ****
--- 95,106 ----
#endif
#endif
+ #ifdef __GLIBC__
+ #if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 3)
+ #define USE_UCONTEXT
+ #endif
+ #endif
+
#endif /* _PARAM_SPARC64_LINUX26_H_ */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.sparc_linux24.h
diff -c openafs/src/config/param.sparc_linux24.h:1.8.2.4 openafs/src/config/param.sparc_linux24.h:1.8.2.6
*** openafs/src/config/param.sparc_linux24.h:1.8.2.4 Thu Nov 9 18:18:31 2006
--- openafs/src/config/param.sparc_linux24.h Tue Jul 17 00:06:41 2007
***************
*** 98,103 ****
--- 98,106 ----
#endif
#endif
+ /* Don't define USE_UCONTEXT on this platform. It requires getcontext and
+ setcontext from glibc, which aren't implemented for 32-bit SPARC. */
+
#endif /* AFS_PARAM_H */
#else /* !defined(UKERNEL) */
Index: openafs/src/config/param.x86_darwin_90.h
diff -c openafs/src/config/param.x86_darwin_90.h:1.1.2.2 openafs/src/config/param.x86_darwin_90.h:1.1.2.3
*** openafs/src/config/param.x86_darwin_90.h:1.1.2.2 Thu Mar 9 01:41:42 2006
--- openafs/src/config/param.x86_darwin_90.h Wed Oct 10 12:57:57 2007
***************
*** 30,35 ****
--- 30,36 ----
#define AFS_SYSCALL 230
#define AFS_NAMEI_ENV 1
#define DARWIN_REFBASE 3
+ #define AFS_CACHE_VNODE_PATH
/* File system entry (used if mount.h doesn't define MOUNT_AFS */
#define AFS_MOUNT_AFS "afs"
Index: openafs/src/config/venus.h
diff -c openafs/src/config/venus.h:1.10.2.1 openafs/src/config/venus.h:1.10.2.2
*** openafs/src/config/venus.h:1.10.2.1 Sun May 8 02:18:12 2005
--- openafs/src/config/venus.h Tue Jun 12 15:20:13 2007
***************
*** 181,185 ****
--- 181,186 ----
#define VIOC_NEWALIAS _CVICEIOCTL(1) /* create new cell alias */
#define VIOC_GETALIAS _CVICEIOCTL(2) /* get alias info */
#define VIOC_CBADDR _CVICEIOCTL(3) /* push callback addr */
+ #define VIOC_NEWUUID _CVICEIOCTL(9) /* new uuid */
#endif /* AFS_VENUS_H */
Index: openafs/src/dauth/dlog.c
diff -c openafs/src/dauth/dlog.c:1.9.2.1 openafs/src/dauth/dlog.c:1.9.2.2
*** openafs/src/dauth/dlog.c:1.9.2.1 Mon Jul 31 13:07:50 2006
--- openafs/src/dauth/dlog.c Tue Apr 10 14:43:42 2007
***************
*** 72,78 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/dauth/Attic/dlog.c,v 1.9.2.1 2006/07/31 17:07:50 shadow Exp $");
#include
#include
--- 72,78 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/dauth/Attic/dlog.c,v 1.9.2.2 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 548,554 ****
ap[1] = "-servers";
code = ubik_ParseClientList(i, ap, serverList);
if (code) {
! com_err(rn, code, "-- could not parse server list");
exit(1);
}
} else {
--- 548,554 ----
ap[1] = "-servers";
code = ubik_ParseClientList(i, ap, serverList);
if (code) {
! afs_com_err(rn, code, "-- could not parse server list");
exit(1);
}
} else {
***************
*** 560,566 ****
*/
code = afsconf_GetCellInfo(cdir, realm, 0, &cellinfo);
if (code) {
! com_err(rn, code, "-- unable to get cell info");
exit(1);
}
strncpy(realm, cellinfo.name, sizeof(realm) - 1);
--- 560,566 ----
*/
code = afsconf_GetCellInfo(cdir, realm, 0, &cellinfo);
if (code) {
! afs_com_err(rn, code, "-- unable to get cell info");
exit(1);
}
strncpy(realm, cellinfo.name, sizeof(realm) - 1);
***************
*** 688,694 ****
* Check for simple communication failures.
*/
if (code) {
! com_err(rn, code, "-- failed to contact authentication service");
exit(1);
}
--- 688,694 ----
* Check for simple communication failures.
*/
if (code) {
! afs_com_err(rn, code, "-- failed to contact authentication service");
exit(1);
}
***************
*** 719,725 ****
} else {
code = des_read_pw_string(passwd, sizeof(passwd), "Password:", 0);
if (code) {
! com_err(rn, code, "-- couldn't read password");
exit(1);
}
}
--- 719,725 ----
} else {
code = des_read_pw_string(passwd, sizeof(passwd), "Password:", 0);
if (code) {
! afs_com_err(rn, code, "-- couldn't read password");
exit(1);
}
}
***************
*** 751,757 ****
passwd_key, DECRYPT);
}
if (code) {
! com_err(rn, code, "-- unable to decrypt reply from the DCE KDC");
exit(1);
}
--- 751,757 ----
passwd_key, DECRYPT);
}
if (code) {
! afs_com_err(rn, code, "-- unable to decrypt reply from the DCE KDC");
exit(1);
}
***************
*** 799,805 ****
kdcrep.endtime, dosetpag);
if (code) {
! com_err("dlog", code, "-- failed to store tickets");
exit(1);
}
--- 799,805 ----
kdcrep.endtime, dosetpag);
if (code) {
! afs_com_err("dlog", code, "-- failed to store tickets");
exit(1);
}
Index: openafs/src/des/des.c
diff -c openafs/src/des/des.c:1.11.2.5 openafs/src/des/des.c:1.11.2.6
*** openafs/src/des/des.c:1.11.2.5 Thu Aug 18 00:56:14 2005
--- openafs/src/des/des.c Tue Jul 3 00:24:45 2007
***************
*** 37,43 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/des/des.c,v 1.11.2.5 2005/08/18 04:56:14 shadow Exp $");
#ifndef KERNEL
#include
--- 37,43 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/des/des.c,v 1.11.2.6 2007/07/03 04:24:45 shadow Exp $");
#ifndef KERNEL
#include
***************
*** 90,96 ****
#error dunno how to do this machine type, you lose;
#endif
#endif
! afs_uint32 P_temp;
volatile unsigned char *P_temp_p = (unsigned char *)&P_temp;
#ifdef BITS16
sbox_out S_out;
--- 90,96 ----
#error dunno how to do this machine type, you lose;
#endif
#endif
! volatile afs_uint32 P_temp;
volatile unsigned char *P_temp_p = (unsigned char *)&P_temp;
#ifdef BITS16
sbox_out S_out;
Index: openafs/src/des/des.h
diff -c openafs/src/des/des.h:1.3 openafs/src/des/des.h:1.3.2.1
*** openafs/src/des/des.h:1.3 Tue Jul 15 19:14:59 2003
--- openafs/src/des/des.h Mon Jul 9 15:16:48 2007
***************
*** 20,26 ****
--- 20,29 ----
typedef unsigned char des_cblock[8]; /* crypto-block size */
/* Key schedule */
typedef struct des_ks_struct {
+ union {
+ afs_uint32 i[2];
des_cblock _;
+ } _;
} des_key_schedule[16];
#define DES_KEY_SZ (sizeof(des_cblock))
Index: openafs/src/des/pcbc_encrypt.c
diff -c openafs/src/des/pcbc_encrypt.c:1.9.2.1 openafs/src/des/pcbc_encrypt.c:1.9.2.2
*** openafs/src/des/pcbc_encrypt.c:1.9.2.1 Mon Oct 18 03:11:56 2004
--- openafs/src/des/pcbc_encrypt.c Mon Jul 9 15:16:48 2007
***************
*** 24,36 ****
#ifndef KERNEL
#include
#endif
- #include
#include
#include
#include "des_prototypes.h"
RCSID
! ("$Header: /cvs/openafs/src/des/pcbc_encrypt.c,v 1.9.2.1 2004/10/18 07:11:56 shadow Exp $");
#include "des_internal.h"
--- 24,36 ----
#ifndef KERNEL
#include
#endif
#include
#include
+ #include
#include "des_prototypes.h"
RCSID
! ("$Header: /cvs/openafs/src/des/pcbc_encrypt.c,v 1.9.2.2 2007/07/09 19:16:48 shadow Exp $");
#include "des_internal.h"
Index: openafs/src/dir/dir.c
diff -c openafs/src/dir/dir.c:1.21.2.3 openafs/src/dir/dir.c:1.21.2.6
*** openafs/src/dir/dir.c:1.21.2.3 Wed Oct 5 01:58:37 2005
--- openafs/src/dir/dir.c Thu Oct 11 13:48:35 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/dir/dir.c,v 1.21.2.3 2005/10/05 05:58:37 shadow Exp $");
#ifdef KERNEL
#if !defined(UKERNEL)
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/dir/dir.c,v 1.21.2.6 2007/10/11 17:48:35 shadow Exp $");
#ifdef KERNEL
#if !defined(UKERNEL)
***************
*** 478,484 ****
{
/* Hash a string to a number between 0 and NHASHENT. */
register unsigned char tc;
! register int hval;
register int tval;
hval = 0;
while ((tc = (*string++))) {
--- 478,484 ----
{
/* Hash a string to a number between 0 and NHASHENT. */
register unsigned char tc;
! unsigned int hval;
register int tval;
hval = 0;
while ((tc = (*string++))) {
***************
*** 488,494 ****
tval = hval & (NHASHENT - 1);
if (tval == 0)
return tval;
! else if (hval < 0)
tval = NHASHENT - tval;
return tval;
}
--- 488,494 ----
tval = hval & (NHASHENT - 1);
if (tval == 0)
return tval;
! else if (hval >= 1<<31)
tval = NHASHENT - tval;
return tval;
}
Index: openafs/src/finale/translate_et.c
diff -c openafs/src/finale/translate_et.c:1.8 openafs/src/finale/translate_et.c:1.8.2.1
*** openafs/src/finale/translate_et.c:1.8 Tue Jul 15 19:15:06 2003
--- openafs/src/finale/translate_et.c Tue Apr 10 14:43:42 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/finale/translate_et.c,v 1.8 2003/07/15 23:15:06 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/finale/translate_et.c,v 1.8.2.1 2007/04/10 18:43:42 shadow Exp $");
#include
#include
***************
*** 74,81 ****
code = atoi(argv[i]);
offset = code & ((1 << ERRCODE_RANGE) - 1);
! printf("%d (%s).%d = %s\n", (int)code, error_table_name(code),
! (int)offset, error_message(code));
}
return 0;
}
--- 74,81 ----
code = atoi(argv[i]);
offset = code & ((1 << ERRCODE_RANGE) - 1);
! printf("%d (%s).%d = %s\n", (int)code, afs_error_table_name(code),
! (int)offset, afs_error_message(code));
}
return 0;
}
Index: openafs/src/kauth/Makefile.in
diff -c openafs/src/kauth/Makefile.in:1.11.2.2 openafs/src/kauth/Makefile.in:1.11.2.3
*** openafs/src/kauth/Makefile.in:1.11.2.2 Mon Jul 31 13:07:50 2006
--- openafs/src/kauth/Makefile.in Sun Aug 19 18:17:44 2007
***************
*** 52,58 ****
KOBJS=kauth.xdr.o kauth.cs.o kaaux.o client.o authclient.o token.o kautils.o kalocalcell.o kaerrors.o user.krb.o krb_tf.o
! all: kaserver kas kpwvalid klog klog.krb knfs kpasswd rebuild kdb \
${TOP_LIBDIR}/libkauth.a \
${TOP_LIBDIR}/libkauth.krb.a \
depinstall
--- 52,58 ----
KOBJS=kauth.xdr.o kauth.cs.o kaaux.o client.o authclient.o token.o kautils.o kalocalcell.o kaerrors.o user.krb.o krb_tf.o
! all: kaserver kas kpwvalid klog klog.krb knfs kpasswd rebuild kdb ka-forwarder \
${TOP_LIBDIR}/libkauth.a \
${TOP_LIBDIR}/libkauth.krb.a \
depinstall
***************
*** 200,205 ****
--- 200,208 ----
krb_udp: krb_udp.o libkauth.a $(KLIBS)
${CC} ${LDFLAGS} -o krb_udp krb_udp.o libkauth.a $(KLIBS)
+ ka-forwarder: ka-forwarder.o
+ ${CC} -o $@ ${CFLAGS} ka-forwarder.o ${LIBS} ${XLIBS}
+
rebuild.o: rebuild.c $(INCLS) AFS_component_version_number.o
rebuild: rebuild.o kautils.o $(LIBS)
***************
*** 240,245 ****
--- 243,249 ----
${DESTDIR}${libdir}/afs/libkauth.krb.a \
${DESTDIR}${afssrvsbindir}/kadb_check \
${DESTDIR}${afssrvsbindir}/kdb \
+ ${DESTDIR}${afssrvsbindir}/ka-forwarder \
${DESTDIR}${includedir}/afs/kautils.h \
${DESTDIR}${includedir}/afs/kauth.h \
${DESTDIR}${includedir}/afs/kaport.h
***************
*** 292,297 ****
--- 296,304 ----
${DESTDIR}${afssrvsbindir}/kdb: kdb
${INSTALL} -s $? $@
+ ${DESTDIR}${afssrvsbindir}/ka-forwarder: ka-forwarder
+ ${INSTALL} $? $@
+
${DESTDIR}${includedir}/afs/kautils.h: kautils.h
${INSTALL} $? $@
***************
*** 318,323 ****
--- 325,331 ----
${DEST}/lib/afs/libkauth.krb.a \
${DEST}/etc/kdb \
${DEST}/etc/kadb_check \
+ ${DEST}/root.server/usr/afs/bin/ka-forwarder \
${DEST}/include/afs/kautils.h \
${DEST}/include/afs/kauth.h \
${DEST}/include/afs/kaport.h
***************
*** 355,360 ****
--- 363,371 ----
${DEST}/etc/kdb: kdb
${INSTALL} -s $? $@
+ ${DEST}/root.server/usr/afs/bin/ka-forwarder: ka-forwarder
+ ${INSTALL} $? $@
+
${DEST}/include/afs/kautils.h: kautils.h
${INSTALL} $? $@
Index: openafs/src/kauth/admin_tools.c
diff -c openafs/src/kauth/admin_tools.c:1.16.2.3 openafs/src/kauth/admin_tools.c:1.16.2.4
*** openafs/src/kauth/admin_tools.c:1.16.2.3 Mon Dec 13 14:38:51 2004
--- openafs/src/kauth/admin_tools.c Tue Apr 10 14:43:43 2007
***************
*** 16,22 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/admin_tools.c,v 1.16.2.3 2004/12/13 19:38:51 shadow Exp $");
#include
#include
--- 16,22 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/admin_tools.c,v 1.16.2.4 2007/04/10 18:43:43 shadow Exp $");
#include
#include
***************
*** 68,74 ****
return 0;
code = ka_ExpandCell(0, cell, 0 /*local */ );
if (code) {
! com_err(whoami, code, "Can't expand cell name");
}
return code;
}
--- 68,74 ----
return 0;
code = ka_ExpandCell(0, cell, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code, "Can't expand cell name");
}
return code;
}
***************
*** 88,94 ****
code = ka_ParseLoginName(user, name, instance, 0);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'", user);
return KABADCMD;
}
--- 88,94 ----
code = ka_ParseLoginName(user, name, instance, 0);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'", user);
return KABADCMD;
}
***************
*** 97,103 ****
code =
ubik_Call(KAM_GetEntry, conn, 0, name, inst, KAMAJORVERSION, &tentry);
if (code) {
! com_err(whoami, code, "getting information for %s.%s", name, inst);
return code;
}
if (tentry.minor_version != KAMINORVERSION)
--- 97,103 ----
code =
ubik_Call(KAM_GetEntry, conn, 0, name, inst, KAMAJORVERSION, &tentry);
if (code) {
! afs_com_err(whoami, code, "getting information for %s.%s", name, inst);
return code;
}
if (tentry.minor_version != KAMINORVERSION)
***************
*** 254,260 ****
ubik_Call(KAM_ListEntry, conn, 0, index, &next_index, &count,
&name);
if (code) {
! com_err(whoami, code, "calling KAM_ListEntry");
break;
}
if (!next_index)
--- 254,260 ----
ubik_Call(KAM_ListEntry, conn, 0, index, &next_index, &count,
&name);
if (code) {
! afs_com_err(whoami, code, "calling KAM_ListEntry");
break;
}
if (!next_index)
***************
*** 300,306 ****
}
}
! printf(" : [%s] %s", error_table_name(code), error_message(code));
switch (code) {
case UNOQUORUM:
printf(", wait one second\n");
--- 300,306 ----
}
}
! printf(" : [%s] %s", afs_error_table_name(code), afs_error_message(code));
switch (code) {
case UNOQUORUM:
printf(", wait one second\n");
***************
*** 331,337 ****
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 331,337 ----
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 359,365 ****
OKlist[0].code = 0;
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 359,365 ----
OKlist[0].code = 0;
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 431,437 ****
ubik_Call(KAM_GetEntry, conn, 0, name, inst, KAMAJORVERSION,
&tentry);
if (code) {
! com_err(whoami, code,
"could get current flag value for %s.%s", name, inst);
return -1;
}
--- 431,437 ----
ubik_Call(KAM_GetEntry, conn, 0, name, inst, KAMAJORVERSION,
&tentry);
if (code) {
! afs_com_err(whoami, code,
"could get current flag value for %s.%s", name, inst);
return -1;
}
***************
*** 517,523 ****
0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
if (code) {
if (seriouserror(code))
! com_err(whoami, code, "");
} else if (tempwhen) { /* user is locked */
if (!*when || tempwhen < *when) {
*when = tempwhen;
--- 517,523 ----
0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
if (code) {
if (seriouserror(code))
! afs_com_err(whoami, code, "");
} else if (tempwhen) { /* user is locked */
if (!*when || tempwhen < *when) {
*when = tempwhen;
***************
*** 542,548 ****
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 542,548 ----
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 557,563 ****
&& conn->conns[count - 1]->peer) {
server = conn->conns[count - 1]->peer->host;
}
! com_err(whoami, code,
"so %s.%s may still be locked (on server %d.%d.%d.%d)",
name, instance, ((server >> 24) & 0xFF),
((server >> 16) & 0xFF), ((server >> 8) & 0xFF),
--- 557,563 ----
&& conn->conns[count - 1]->peer) {
server = conn->conns[count - 1]->peer->host;
}
! afs_com_err(whoami, code,
"so %s.%s may still be locked (on server %d.%d.%d.%d)",
name, instance, ((server >> 24) & 0xFF),
((server >> 16) & 0xFF), ((server >> 8) & 0xFF),
***************
*** 589,595 ****
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 589,595 ----
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, 0);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 729,735 ****
return KABADCMD;
}
if (code)
! com_err(whoami, code, "calling KAM_SetFields for %s.%s", name,
instance);
return code;
}
--- 729,735 ----
return KABADCMD;
}
if (code)
! afs_com_err(whoami, code, "calling KAM_SetFields for %s.%s", name,
instance);
return code;
}
***************
*** 744,750 ****
if (as->parms[1].items) {
code = ka_ExpandCell(as->parms[1].items->data, realm, 0 /*local */ );
if (code) {
! com_err(whoami, code,
"expanding %s as cell name, attempting to continue",
as->parms[1].items->data);
}
--- 744,750 ----
if (as->parms[1].items) {
code = ka_ExpandCell(as->parms[1].items->data, realm, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code,
"expanding %s as cell name, attempting to continue",
as->parms[1].items->data);
}
***************
*** 783,789 ****
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, realm);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 783,789 ----
code = ka_ParseLoginName(as->parms[0].items->data, name, instance, realm);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 824,830 ****
code = ubik_Call(KAM_SetPassword, conn, 0, name, instance, kvno, key);
#endif
if (code)
! com_err(whoami, code, "so can't set password for %s.%s", name,
instance);
return code;
}
--- 824,830 ----
code = ubik_Call(KAM_SetPassword, conn, 0, name, instance, kvno, key);
#endif
if (code)
! afs_com_err(whoami, code, "so can't set password for %s.%s", name,
instance);
return code;
}
***************
*** 849,855 ****
if (left) {
bad_name:
code = KABADNAME;
! com_err(whoami, code, "PrintName: principal name was '%s'.'%s'@'%s'",
name, inst, acell);
return code;
}
--- 849,855 ----
if (left) {
bad_name:
code = KABADNAME;
! afs_com_err(whoami, code, "PrintName: principal name was '%s'.'%s'@'%s'",
name, inst, acell);
return code;
}
***************
*** 919,925 ****
/* get the ticket info itself */
code = ktc_GetToken(server, &token, sizeof(token), &client);
if (code) {
! com_err(whoami, code, "failed to get token info for server %s",
PrintedPrincipal(server));
return code;
}
--- 919,925 ----
/* get the ticket info itself */
code = ktc_GetToken(server, &token, sizeof(token), &client);
if (code) {
! afs_com_err(whoami, code, "failed to get token info for server %s",
PrintedPrincipal(server));
return code;
}
***************
*** 980,986 ****
ka_ParseLoginName(as->parms[0].items->data, server.name,
server.instance, server.cell);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
--- 980,986 ----
ka_ParseLoginName(as->parms[0].items->data, server.name,
server.instance, server.cell);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[0].items->data);
return KABADCMD;
}
***************
*** 991,997 ****
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! com_err(whoami, code, "Can't expand cell name");
return code;
}
}
--- 991,997 ----
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code, "Can't expand cell name");
return code;
}
}
***************
*** 1001,1007 ****
ka_GetServerToken(server.name, server.instance, server.cell, life,
&token, /*new */ 1, /*dosetpag */ 0);
if (code)
! com_err(whoami, code, "getting ticket for %s",
PrintedPrincipal(&server));
else {
code = ListTicket(&server, /*verbose */ 1);
--- 1001,1007 ----
ka_GetServerToken(server.name, server.instance, server.cell, life,
&token, /*new */ 1, /*dosetpag */ 0);
if (code)
! afs_com_err(whoami, code, "getting ticket for %s",
PrintedPrincipal(&server));
else {
code = ListTicket(&server, /*verbose */ 1);
***************
*** 1021,1027 ****
code = ka_ParseLoginName(as->parms[0].items->data, name, 0, 0);
if (code) {
abort:
! com_err(whoami, code,
"getting %s's password via loopback connection to GetPassword",
name);
/* if we got a timeout, print a clarification, too */
--- 1021,1027 ----
code = ka_ParseLoginName(as->parms[0].items->data, name, 0, 0);
if (code) {
abort:
! afs_com_err(whoami, code,
"getting %s's password via loopback connection to GetPassword",
name);
/* if we got a timeout, print a clarification, too */
***************
*** 1069,1075 ****
code = ubik_Call(KAM_GetRandomKey, conn, 0, &key);
if (code)
! com_err(whoami, code, "so can't get random key");
else {
int i;
printf("Key: ");
--- 1069,1075 ----
code = ubik_Call(KAM_GetRandomKey, conn, 0, &key);
if (code)
! afs_com_err(whoami, code, "so can't get random key");
else {
int i;
printf("Key: ");
***************
*** 1159,1169 ****
if (code) {
struct afsconf_cell cellinfo;
! com_err(whoami, code, "couldn't find host %s in cell %s",
as->parms[0].items->data, cell);
code = ka_GetServers(cell, &cellinfo);
if (code)
! com_err(whoami, code, "getting servers in cell %s", cell);
else {
printf("Servers in cell %s, are:\n", cell);
for (i = 0; i < cellinfo.numServers; i++)
--- 1159,1169 ----
if (code) {
struct afsconf_cell cellinfo;
! afs_com_err(whoami, code, "couldn't find host %s in cell %s",
as->parms[0].items->data, cell);
code = ka_GetServers(cell, &cellinfo);
if (code)
! afs_com_err(whoami, code, "getting servers in cell %s", cell);
else {
printf("Servers in cell %s, are:\n", cell);
for (i = 0; i < cellinfo.numServers; i++)
***************
*** 1177,1183 ****
code = ubik_Call(KAM_Debug, conn, 0, KAMAJORVERSION, 0, &info);
if (code) {
! com_err(whoami, code, "call to Debug failed");
return code;
}
now = time(0);
--- 1177,1183 ----
code = ubik_Call(KAM_Debug, conn, 0, KAMAJORVERSION, 0, &info);
if (code) {
! afs_com_err(whoami, code, "call to Debug failed");
return code;
}
now = time(0);
***************
*** 1332,1338 ****
ka_ParseLoginName(as->parms[12].items->data, name, instance,
newCell);
if (code) {
! com_err(whoami, code, "parsing user's name '%s'",
as->parms[12].items->data);
return code;
}
--- 1332,1338 ----
ka_ParseLoginName(as->parms[12].items->data, name, instance,
newCell);
if (code) {
! afs_com_err(whoami, code, "parsing user's name '%s'",
as->parms[12].items->data);
return code;
}
***************
*** 1363,1369 ****
}
code = ka_ExpandCell(newCell, newCell, 0 /*local */ );
if (code) {
! com_err(whoami, code, "Can't expand cell name");
return code;
}
strcpy(cell, newCell);
--- 1363,1369 ----
}
code = ka_ExpandCell(newCell, newCell, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code, "Can't expand cell name");
return code;
}
strcpy(cell, newCell);
***************
*** 1378,1384 ****
ap[i] = ip->data;
code = ubik_ParseClientList(i, ap, serverList);
if (code) {
! com_err(whoami, code, "could not parse server list");
return code;
}
ka_ExplicitCell(cell, serverList);
--- 1378,1384 ----
ap[i] = ip->data;
code = ubik_ParseClientList(i, ap, serverList);
if (code) {
! afs_com_err(whoami, code, "could not parse server list");
return code;
}
ka_ExplicitCell(cell, serverList);
***************
*** 1412,1418 ****
else if (strlen(passwd) == 0)
code = KANULLPASSWORD;
if (code) {
! com_err(whoami, code, "reading password");
return code;
}
}
--- 1412,1418 ----
else if (strlen(passwd) == 0)
code = KANULLPASSWORD;
if (code) {
! afs_com_err(whoami, code, "reading password");
return code;
}
}
***************
*** 1453,1459 ****
reason = "Authentication Server was unavailable";
break;
default:
! reason = (char *)error_message(code);
}
fprintf(stderr,
"%s: Auth. as %s to AuthServer failed: %s\nProceeding w/o authentication\n",
--- 1453,1459 ----
reason = "Authentication Server was unavailable";
break;
default:
! reason = (char *)afs_error_message(code);
}
fprintf(stderr,
"%s: Auth. as %s to AuthServer failed: %s\nProceeding w/o authentication\n",
***************
*** 1474,1480 ****
/*Don't need pwd expiration info here */
);
if (acode && (acode != code)) /* codes are usually the same */
! com_err(whoami, code,
"getting Authentication token for %s",
PrintedName(name, instance, cell));
}
--- 1474,1480 ----
/*Don't need pwd expiration info here */
);
if (acode && (acode != code)) /* codes are usually the same */
! afs_com_err(whoami, code,
"getting Authentication token for %s",
PrintedName(name, instance, cell));
}
***************
*** 1485,1499 ****
pToken = ((token.ticketLen == 0) ? 0 : &token);
code = ka_AuthServerConn(cell, KA_MAINTENANCE_SERVICE, pToken, &conn);
if (code && pToken) {
! com_err(whoami, code,
"connecting to AuthServer: now trying w/o authentication");
code = ka_AuthServerConn(cell, KA_MAINTENANCE_SERVICE, 0, &conn);
if (code)
! com_err(whoami, code,
"making unauthenticated connection to AuthServer");
}
if (code) {
! com_err(whoami, code,
"Couldn't establish connection to Authentication Server");
return code;
}
--- 1485,1499 ----
pToken = ((token.ticketLen == 0) ? 0 : &token);
code = ka_AuthServerConn(cell, KA_MAINTENANCE_SERVICE, pToken, &conn);
if (code && pToken) {
! afs_com_err(whoami, code,
"connecting to AuthServer: now trying w/o authentication");
code = ka_AuthServerConn(cell, KA_MAINTENANCE_SERVICE, 0, &conn);
if (code)
! afs_com_err(whoami, code,
"making unauthenticated connection to AuthServer");
}
if (code) {
! afs_com_err(whoami, code,
"Couldn't establish connection to Authentication Server");
return code;
}
***************
*** 1518,1524 ****
else if (strlen(password) == 0)
code = KANULLPASSWORD;
if (code) {
! com_err(whoami, code, "prompting for %s", p + 1);
return code;
}
ip = (struct cmd_item *)malloc(sizeof(struct cmd_item));
--- 1518,1524 ----
else if (strlen(password) == 0)
code = KANULLPASSWORD;
if (code) {
! afs_com_err(whoami, code, "prompting for %s", p + 1);
return code;
}
ip = (struct cmd_item *)malloc(sizeof(struct cmd_item));
***************
*** 1552,1558 ****
ka_ParseLoginName(name, server.name, server.instance,
server.cell);
if (code) {
! com_err(whoami, code, "couldn't interpret name '%s'", name);
return code;
}
if (server.cell[0] == 0) {
--- 1552,1558 ----
ka_ParseLoginName(name, server.name, server.instance,
server.cell);
if (code) {
! afs_com_err(whoami, code, "couldn't interpret name '%s'", name);
return code;
}
if (server.cell[0] == 0) {
***************
*** 1562,1574 ****
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! com_err(whoami, code, "Can't expand cell name");
return code;
}
}
code = ktc_ForgetToken(&server);
if (code) {
! com_err(whoami, code, "couldn't remove tokens for %s",
PrintedPrincipal(&server));
return code;
}
--- 1562,1574 ----
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code, "Can't expand cell name");
return code;
}
}
code = ktc_ForgetToken(&server);
if (code) {
! afs_com_err(whoami, code, "couldn't remove tokens for %s",
PrintedPrincipal(&server));
return code;
}
***************
*** 1579,1592 ****
}
code = ktc_ForgetAllTokens();
if (code) {
! com_err(whoami, code, "couldn't delete all tokens");
return code;
}
}
#endif
code = ktc_ForgetAllTokens();
if (code) {
! com_err(whoami, code, "couldn't delete all tokens");
return code;
}
return 0;
--- 1579,1592 ----
}
code = ktc_ForgetAllTokens();
if (code) {
! afs_com_err(whoami, code, "couldn't delete all tokens");
return code;
}
}
#endif
code = ktc_ForgetAllTokens();
if (code) {
! afs_com_err(whoami, code, "couldn't delete all tokens");
return code;
}
return 0;
***************
*** 1608,1614 ****
ka_ParseLoginName(name, server.name, server.instance,
server.cell);
if (code) {
! com_err(whoami, code, "couldn't interpret name '%s'", name);
return code;
}
if (server.cell[0] == 0) {
--- 1608,1614 ----
ka_ParseLoginName(name, server.name, server.instance,
server.cell);
if (code) {
! afs_com_err(whoami, code, "couldn't interpret name '%s'", name);
return code;
}
if (server.cell[0] == 0) {
***************
*** 1618,1624 ****
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! com_err(whoami, code, "Can't expand cell name");
return code;
}
}
--- 1618,1624 ----
} else {
code = ka_ExpandCell(server.cell, server.cell, 0 /*local */ );
if (code) {
! afs_com_err(whoami, code, "Can't expand cell name");
return code;
}
}
***************
*** 1833,1839 ****
code =
cmd_ParseLine(line, argv, &argc, sizeof(argv) / sizeof(argv[0]));
if (code) {
! com_err(whoami, code, "parsing line: '%s'", line);
return code;
}
code = cmd_Dispatch(argc, argv);
--- 1833,1839 ----
code =
cmd_ParseLine(line, argv, &argc, sizeof(argv) / sizeof(argv[0]));
if (code) {
! afs_com_err(whoami, code, "parsing line: '%s'", line);
return code;
}
code = cmd_Dispatch(argc, argv);
Index: openafs/src/kauth/decode_ticket.c
diff -c openafs/src/kauth/decode_ticket.c:1.6 openafs/src/kauth/decode_ticket.c:1.6.2.1
*** openafs/src/kauth/decode_ticket.c:1.6 Tue Jul 15 19:15:16 2003
--- openafs/src/kauth/decode_ticket.c Tue Apr 10 14:43:43 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/decode_ticket.c,v 1.6 2003/07/15 23:15:16 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/decode_ticket.c,v 1.6.2.1 2007/04/10 18:43:43 shadow Exp $");
#include
#include
***************
*** 45,51 ****
if (ka_ReadBytes(argv[1], key, sizeof(key)) != 8)
printf("Key must be 8 bytes long\n");
if (!des_check_key_parity(key) || des_is_weak_key(key)) {
! com_err(whoami, KABADKEY, "server's key for decoding ticket is bad");
exit(1);
}
ticketLen = ka_ReadBytes(argv[2], ticket, sizeof(ticket));
--- 45,51 ----
if (ka_ReadBytes(argv[1], key, sizeof(key)) != 8)
printf("Key must be 8 bytes long\n");
if (!des_check_key_parity(key) || des_is_weak_key(key)) {
! afs_com_err(whoami, KABADKEY, "server's key for decoding ticket is bad");
exit(1);
}
ticketLen = ka_ReadBytes(argv[2], ticket, sizeof(ticket));
***************
*** 55,68 ****
tkt_DecodeTicket(ticket, ticketLen, key, client.name, client.instance,
client.cell, &sessionkey, &host, &start, &end);
if (code) {
! com_err(whoami, code, "decoding ticket");
if (code = tkt_CheckTimes(start, end, time(0)) <= 0)
! com_err(whoami, 0, "because of start or end times");
exit(1);
}
if (!des_check_key_parity(&sessionkey) || des_is_weak_key(&sessionkey)) {
! com_err(whoami, KABADKEY, "checking ticket's session key");
exit(1);
}
--- 55,68 ----
tkt_DecodeTicket(ticket, ticketLen, key, client.name, client.instance,
client.cell, &sessionkey, &host, &start, &end);
if (code) {
! afs_com_err(whoami, code, "decoding ticket");
if (code = tkt_CheckTimes(start, end, time(0)) <= 0)
! afs_com_err(whoami, 0, "because of start or end times");
exit(1);
}
if (!des_check_key_parity(&sessionkey) || des_is_weak_key(&sessionkey)) {
! afs_com_err(whoami, KABADKEY, "checking ticket's session key");
exit(1);
}
Index: openafs/src/kauth/ka-forwarder.c
diff -c /dev/null openafs/src/kauth/ka-forwarder.c:1.2.4.2
*** /dev/null Thu Oct 11 16:05:08 2007
--- openafs/src/kauth/ka-forwarder.c Sun Aug 19 18:17:44 2007
***************
*** 0 ****
--- 1,294 ----
+ /*
+ * COPYRIGHT NOTICE
+ * Copyright (c) 1994 Carnegie Mellon University
+ * All Rights Reserved.
+ *
+ * See for use and distribution information.
+ */
+
+ /*
+ * HISTORY
+ * $Log: ka-forwarder.c,v $
+ * Revision 1.2.4.2 2007/08/19 22:17:44 rra
+ * DELTA STABLE14-ka-forwarder-20060731
+ * AUTHOR rra@stanford.edu
+ *
+ * Add ka-forwarder.
+ *
+ * Revision 1.1 2006/07/31 17:34:26 rra
+ * DELTA ka-forwarder-20060731
+ * AUTHOR rra@stanford.edu
+ *
+ * Add ka-forwarder.
+ *
+ * Revision 1.1 1997/06/03 18:23:54 kenh
+ * .
+ *
+ * Revision 1.4 1996/08/09 01:00:21 jhutz
+ * When initializing the array of fakeka servers, remember to set
+ * the address family of each server; otherwise SunOS complains.
+ * [1996/08/09 00:58:46 jhutz]
+ *
+ * Revision 1.3 1996/08/09 00:17:19 jhutz
+ * Merged in changes from Chuck Silvers:
+ * - Support for more than one fakeka server
+ * - Support for specifying ports for each fakeka server separately from the
+ * others, and from the port we listen on.
+ *
+ * Plus a minor bug fix to Chuck's code.
+ * Basically, this version is designed to provide both reliability and
+ * load-balancing cheaply. Basically, we forward packets to all of the
+ * fakeka servers in round-robin fashion. So, if a client is losing on
+ * one server, its retry should go to a different one, if more than one
+ * is specified.
+ * [1996/08/03 02:13:36 jhutz]
+ *
+ * Revision 1.2 1995/02/23 18:26:36 chs
+ * Created.
+ * [1995/02/23 18:26:03 chs]
+ *
+ * $EndLog$
+ */
+
+ /*
+ * This program is intended to run on afs DB servers.
+ * Its function is to forward KA requests to a fakeka server
+ * running on an MIT kerberos server.
+ */
+
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+
+ #if HAVE_GETOPT_H
+ #include
+ #else
+ int getopt (int, char * const *, const char *);
+ int optind, opterr;
+ char *optarg;
+ #endif
+
+ #define BUFFER_SIZE 2048
+
+
+ char *prog;
+
+ int num_servers, cur_server;
+ struct sockaddr_in *servers;
+
+
+ void
+ perrorexit(str)
+ char *str;
+ {
+ perror(str);
+ exit(1);
+ }
+
+
+ void
+ setup_servers(argc, argv)
+ int argc;
+ char **argv;
+ {
+ int i;
+ u_int fwdaddr;
+ u_short fwdport;
+
+ num_servers = argc;
+
+ servers = malloc(sizeof(*servers) * num_servers);
+ if (servers == NULL)
+ perrorexit("malloc failed");
+
+ for (i = 0; i < num_servers; i++) {
+ char *host, *port;
+
+ fwdport = htons(7004);
+
+ host = argv[i];
+ port = strchr(host, '/');
+ if (port != NULL) {
+ *port++ = 0;
+
+ if (isdigit(port[0])) {
+ fwdport = htons(atoi(port));
+ }
+ else {
+ struct servent *srv = getservbyname(port, "udp");
+ if (!srv) {
+ fprintf(stderr, "%s: unknown service %s\n", prog, port);
+ exit(1);
+ }
+ fwdport = srv->s_port;
+ }
+ }
+
+ if (isdigit(host[0])) {
+ fwdaddr = inet_addr(host);
+ }
+ else {
+ struct hostent *h = gethostbyname(host);
+ if (!h) {
+ fprintf(stderr, "%s: unknown host %s\n", prog, host);
+ exit(1);
+ }
+ bcopy(h->h_addr, &fwdaddr, 4);
+ }
+
+ servers[i].sin_family = AF_INET;
+ servers[i].sin_addr.s_addr = fwdaddr;
+ servers[i].sin_port = fwdport;
+ }
+ }
+
+
+ int
+ setup_socket(port)
+ u_short port;
+ {
+ int s, rv;
+ struct sockaddr_in sin;
+
+ s = socket(AF_INET, SOCK_DGRAM, 0);
+ if (s < 0)
+ perrorexit("Couldn't create socket");
+
+ sin.sin_family = AF_INET;
+ sin.sin_addr.s_addr = 0;
+ sin.sin_port = htons(port);
+
+ rv = bind(s, (struct sockaddr *)&sin, sizeof(sin));
+ if (rv < 0)
+ perrorexit("Couldn't bind socket");
+
+ return s;
+ }
+
+
+ int
+ packet_is_reply(from)
+ struct sockaddr_in *from;
+ {
+ int i;
+
+ for (i = 0; i < num_servers; i++) {
+ struct sockaddr_in *sin = &servers[i];
+
+ if (from->sin_addr.s_addr == sin->sin_addr.s_addr &&
+ from->sin_port == sin->sin_port)
+ {
+ return 1;
+ }
+ }
+
+ return 0;
+ }
+
+
+ int
+ main(argc, argv)
+ int argc;
+ char **argv;
+ {
+ int c, s, rv;
+ u_short port;
+
+ if (argc < 2) {
+ fprintf(stderr,
+ "usage: %s [-p port] [/port] [host/port ...]\n",
+ argv[0]);
+ exit(1);
+ }
+
+ prog = argv[0];
+ port = 7004;
+
+ while ((c = getopt(argc, argv, "p:")) != -1) {
+ switch (c) {
+ case 'p':
+ port = atoi(optarg);
+ break;
+ default:
+ fprintf(stderr, "%s: invalid option '%c'\n", prog, c);
+ exit(1);
+ }
+ }
+
+ /*
+ * hmm, different implementations of getopt seem to do different things
+ * when there aren't any options. linux sets optind = 1, which I would
+ * call correct, but sunos sets optind = 0. try to do the right thing.
+ */
+ if (optind == 0)
+ optind = 1;
+
+ setup_servers(argc - optind, argv + optind);
+ s = setup_socket(port);
+
+ openlog("ka-forwarder", LOG_PID, LOG_DAEMON);
+
+ for (;;) {
+ char buf[BUFFER_SIZE], *bufp, *sendptr;
+ struct sockaddr_in from, reply, *to;
+ int fromlen, sendlen;
+
+ bufp = buf + 8;
+ fromlen = sizeof(from);
+
+ rv = recvfrom(s, bufp, sizeof(buf) - 8,
+ 0, (struct sockaddr *)&from, &fromlen);
+ if (rv < 0) {
+ syslog(LOG_ERR, "recvfrom: %m");
+ sleep(1);
+ continue;
+ }
+
+ if (packet_is_reply(&from)) {
+ /* this is a reply, forward back to user */
+
+ to = &reply;
+ reply.sin_family = AF_INET;
+ bcopy(bufp, &reply.sin_addr.s_addr, 4);
+ bcopy(bufp + 4, &reply.sin_port, 2);
+ sendptr = bufp + 8;
+ sendlen = rv - 8;
+ }
+ else {
+ /* this is a request, forward to server */
+
+ cur_server = (cur_server + 1) % num_servers;
+ to = &servers[cur_server];
+
+ bcopy(&from.sin_addr.s_addr, bufp - 8, 4);
+ bcopy(&from.sin_port, bufp - 4, 2);
+
+ sendptr = bufp - 8;
+ sendlen = rv + 8;
+ }
+
+ {
+ char a1[16], a2[16];
+ strcpy(a1, inet_ntoa(from.sin_addr));
+ strcpy(a2, inet_ntoa(to->sin_addr));
+
+ syslog(LOG_INFO, "forwarding %d bytes from %s/%d to %s/%d\n",
+ sendlen, a1, htons(from.sin_port), a2, htons(to->sin_port));
+ }
+
+ rv = sendto(s, sendptr, sendlen,
+ 0, (struct sockaddr *)to, sizeof(*to));
+ if (rv < 0) {
+ syslog(LOG_ERR, "sendto: %m");
+ }
+ }
+ }
Index: openafs/src/kauth/kaprocs.c
diff -c openafs/src/kauth/kaprocs.c:1.16.2.1 openafs/src/kauth/kaprocs.c:1.16.2.2
*** openafs/src/kauth/kaprocs.c:1.16.2.1 Wed Aug 25 03:09:38 2004
--- openafs/src/kauth/kaprocs.c Tue Apr 10 14:43:43 2007
***************
*** 11,17 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/kaprocs.c,v 1.16.2.1 2004/08/25 07:09:38 shadow Exp $");
#include
#include
--- 11,17 ----
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/kaprocs.c,v 1.16.2.2 2007/04/10 18:43:43 shadow Exp $");
#include
#include
***************
*** 40,45 ****
--- 40,46 ----
#include
#include
#include
+ #include
#include "kautils.h"
#include "kaserver.h"
#include "kalog.h"
***************
*** 176,182 ****
} else {
es_Report
("in get_time: set_password failed because: %s\n",
! error_message(code));
return code;
}
}
--- 177,183 ----
} else {
es_Report
("in get_time: set_password failed because: %s\n",
! afs_error_message(code));
return code;
}
}
Index: openafs/src/kauth/kas.c
diff -c openafs/src/kauth/kas.c:1.7 openafs/src/kauth/kas.c:1.7.2.1
*** openafs/src/kauth/kas.c:1.7 Tue Jul 15 19:15:16 2003
--- openafs/src/kauth/kas.c Tue Apr 10 14:43:43 2007
***************
*** 12,18 ****
#include
RCSID
! ("$Header: /cvs/openafs/src/kauth/kas.c,v 1.7 2003/07/15 23:15:16 shadow Exp $");
#include