Index: sbin/newfs/newfs.8 =================================================================== RCS file: /home/ncvs/src/sbin/newfs/newfs.8,v retrieving revision 1.59 diff -u -r1.59 newfs.8 --- sbin/newfs/newfs.8 23 Feb 2003 01:47:48 -0000 1.59 +++ sbin/newfs/newfs.8 18 Apr 2003 20:04:47 -0000 @@ -89,7 +89,7 @@ .It Fl O Ar filesystem-type Use 1 to specify that a UFS1 format file system be built; use 2 to specify that a UFS2 format file system be built. -The default is UFS1 format, but will eventually be changed to UFS2. +The default is UFS2 format. .It Fl T Ar disktype For backward compatibility. .It Fl U Index: sbin/newfs/newfs.c =================================================================== RCS file: /home/ncvs/src/sbin/newfs/newfs.c,v retrieving revision 1.71 diff -u -r1.71 newfs.c --- sbin/newfs/newfs.c 14 Feb 2003 21:05:35 -0000 1.71 +++ sbin/newfs/newfs.c 18 Apr 2003 20:05:36 -0000 @@ -116,7 +116,7 @@ int Lflag; /* add a volume label */ int Nflag; /* run without writing file system */ -int Oflag = 1; /* file system format (1 => UFS1, 2 => UFS2) */ +int Oflag = 2; /* file system format (1 => UFS1, 2 => UFS2) */ int Rflag; /* regression test */ int Uflag; /* enable soft updates for file system */ quad_t fssize; /* file system size */ Index: usr.sbin/sysinstall/install.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/sysinstall/install.c,v retrieving revision 1.340 diff -u -r1.340 install.c --- usr.sbin/sysinstall/install.c 19 Feb 2003 21:48:28 -0000 1.340 +++ usr.sbin/sysinstall/install.c 18 Apr 2003 20:06:53 -0000 @@ -879,7 +879,7 @@ snprintf(buffer, LINE_MAX, "%s %s %s %s %s", NEWFS_UFS_CMD, pi->newfs_data.newfs_ufs.softupdates ? "-U" : "", - pi->newfs_data.newfs_ufs.ufs2 ? "-O2" : "-O1", + pi->newfs_data.newfs_ufs.ufs1 ? "-O1" : "-O2", pi->newfs_data.newfs_ufs.user_options, dname); break; Index: usr.sbin/sysinstall/label.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/sysinstall/label.c,v retrieving revision 1.136 diff -u -r1.136 label.c --- usr.sbin/sysinstall/label.c 25 Jan 2003 19:32:35 -0000 1.136 +++ usr.sbin/sysinstall/label.c 18 Apr 2003 20:09:11 -0000 @@ -337,7 +337,7 @@ pi->newfs_data.newfs_ufs.acls = FALSE; pi->newfs_data.newfs_ufs.multilabel = FALSE; pi->newfs_data.newfs_ufs.softupdates = strcmp(mpoint, "/"); - pi->newfs_data.newfs_ufs.ufs2 = FALSE; + pi->newfs_data.newfs_ufs.ufs1 = FALSE; return pi; } @@ -461,7 +461,7 @@ case NEWFS_UFS: snprintf(buffer, NEWFS_CMD_ARGS_MAX, "%s %s %s %s", NEWFS_UFS_CMD, p->newfs_data.newfs_ufs.softupdates ? "-U" : "", - p->newfs_data.newfs_ufs.ufs2 ? "-O2" : "-O1", + p->newfs_data.newfs_ufs.ufs1 ? "-O1" : "-O2", p->newfs_data.newfs_ufs.user_options); break; case NEWFS_MSDOS: @@ -686,10 +686,10 @@ switch (pi->newfs_type) { case NEWFS_UFS: strcpy(newfs, NEWFS_UFS_STRING); - if (pi->newfs_data.newfs_ufs.ufs2) - strcat(newfs, "2"); - else + if (pi->newfs_data.newfs_ufs.ufs1) strcat(newfs, "1"); + else + strcat(newfs, "2"); if (pi->newfs_data.newfs_ufs.softupdates) strcat(newfs, "+S"); else @@ -872,6 +872,21 @@ clear_wins(); break; + case '1': + if (label_chunk_info[here].type == PART_FILESYSTEM) { + PartInfo *pi = + ((PartInfo *)label_chunk_info[here].c->private_data); + + if ((pi != NULL) && + (pi->newfs_type == NEWFS_UFS)) { + pi->newfs_data.newfs_ufs.ufs1 = true; + } else + msg = MSG_NOT_APPLICABLE; + } else + msg = MSG_NOT_APPLICABLE; + break; + break; + case '2': if (label_chunk_info[here].type == PART_FILESYSTEM) { PartInfo *pi = @@ -879,8 +894,7 @@ if ((pi != NULL) && (pi->newfs_type == NEWFS_UFS)) { - pi->newfs_data.newfs_ufs.ufs2 = - !pi->newfs_data.newfs_ufs.ufs2; + pi->newfs_data.newfs_ufs.ufs1 = false; } else msg = MSG_NOT_APPLICABLE; } else Index: usr.sbin/sysinstall/sysinstall.h =================================================================== RCS file: /home/ncvs/src/usr.sbin/sysinstall/sysinstall.h,v retrieving revision 1.243 diff -u -r1.243 sysinstall.h --- usr.sbin/sysinstall/sysinstall.h 9 Mar 2003 02:28:04 -0000 1.243 +++ usr.sbin/sysinstall/sysinstall.h 18 Apr 2003 20:09:14 -0000 @@ -334,7 +334,7 @@ Boolean acls; /* unused */ Boolean multilabel; /* unused */ Boolean softupdates; - Boolean ufs2; + Boolean ufs1; } newfs_ufs; struct { /* unused */ Index: usr.sbin/sysinstall/help/partition.hlp =================================================================== RCS file: /home/ncvs/src/usr.sbin/sysinstall/help/partition.hlp,v retrieving revision 1.11 diff -u -r1.11 partition.hlp --- usr.sbin/sysinstall/help/partition.hlp 13 Jan 2003 21:57:07 -0000 1.11 +++ usr.sbin/sysinstall/help/partition.hlp 18 Apr 2003 20:13:24 -0000 @@ -126,16 +126,18 @@ policy results in free'd blocks not being "garbage collected" as fast as they're being requested. -To make use of UFS2, press '2' on a UFS file system to toggle the -on-disk format revision. UFS2 provides native support for extended -attributes, larger disk sizes, and forward compatibility with new -on-disk high performance directory layout and storage extents. -However, UFS2 is unsupported on versions of FreeBSD prior to 5.0, -so it is not recommended for environments requiring backward -compatibility. Also, UFS2 is not currently recommended as a root -file system format for non-64-bit platforms due to increased size -of the boot loader; special local configuration is required to boot -UFS2 as a root file system on i386 and PC98. +The UNIX File System (UFS) on FreeBSD supports two different on-disk +layouts: UFS1, and UFS2. UFS1 was the default file system in use +through FreeBSD 5.0-RELEASE; as of FreeBSD 5.1-RELEASE, the default +is now UFS2. UFS2 provides for sparse inode allocation (faster +fsck), 64-bit storage pointers (larger maximum size), and native +extended attributes (required for ACLs, MAC, and other advanced +security and file system services). The selection of UFS1 or +UFS2 must be made when the file system is created--later conversion +is not currently possible. UFS2 is the recommended file system, but +if disks are to be used on older FreeBSD systems, UFS1 improves +portability. To toggle a file system to UFS1, press '1'. To restore +it to UFS2, press '2'. To add additional flags to the newfs command line for UFS file systems, press 'N'. These options will be specified before the