Make the newfs parameters a global option.

The default is still "-b 8192 -f 1024" but my experiments show that
"-b 16384 -f 4096 -c 100" is a more sensible value for modern
disksizes.
This commit is contained in:
Poul-Henning Kamp 1999-08-05 19:50:26 +00:00
parent fa7c4d5575
commit 8a9b8e429b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=49441
11 changed files with 29 additions and 14 deletions

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: install.c,v 1.242 1999/07/18 10:18:05 jkh Exp $
* $Id: install.c,v 1.243 1999/08/05 10:07:09 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1049,6 +1049,7 @@ installVarDefaults(dialogMenuItem *self)
variable_set2(SYSTEM_STATE, "update", 0);
else
variable_set2(SYSTEM_STATE, "init", 0);
variable_set2(VAR_NEWFS_ARGS, "-b 8192 -f 1024", 0);
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: label.c,v 1.89 1999/05/07 04:36:21 jkh Exp $
* $Id: label.c,v 1.90 1999/07/29 06:28:52 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -309,7 +309,8 @@ new_part(char *mpoint, Boolean newfs, u_long size)
ret = (PartInfo *)safe_malloc(sizeof(PartInfo));
sstrncpy(ret->mountpoint, mpoint, FILENAME_MAX);
strcpy(ret->newfs_cmd, "newfs -b 8192 -f 1024");
strcpy(ret->newfs_cmd, "newfs ");
strcat(ret->newfs_cmd, variable_get(VAR_NEWFS_ARGS));
ret->newfs = newfs;
if (!size)
return ret;

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated for what's essentially a complete rewrite.
*
* $Id: options.c,v 1.60 1999/05/07 11:02:57 jkh Exp $
* $Id: options.c,v 1.61 1999/07/16 11:13:09 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -94,6 +94,7 @@ mediaCheck(Option opt)
}
#define TAPE_PROMPT "Please enter the tape block size in 512 byte blocks:"
#define NEWFS_PROMPT "Please enter newfs(8) parameters:"
#define RELNAME_PROMPT "Please specify the release you wish to load or\n\"none\" for a generic release install:"
#define BPKG_PROMPT "Please specify the name of the HTML browser package:"
#define BBIN_PROMPT "Please specify a full pathname to the HTML browser binary:"
@ -137,6 +138,8 @@ static Option Options[] = {
OPT_IS_VAR, TIMEOUT_PROMPT, VAR_MEDIA_TIMEOUT, varCheck },
{ "Package Temp", "The directory where package temporary files should go",
OPT_IS_VAR, PKG_PROMPT, VAR_PKG_TMPDIR, varCheck },
{ "Newfs Args", "Default parameters for newfs(8)",
OPT_IS_VAR, NEWFS_PROMPT, VAR_NEWFS_ARGS, varCheck },
{ "Config save", "Whether or not to save installation kernel config changes",
OPT_IS_VAR, NULL, VAR_KGET, varCheck },
{ "Re-scan Devices", "Re-run sysinstall's initial device probe",

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.171 1999/07/19 10:06:17 jkh Exp $
* $Id: sysinstall.h,v 1.172 1999/07/26 10:49:36 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -132,6 +132,7 @@
#define VAR_NETINTERACTIVE "netInteractive"
#define VAR_NETMASK "netmask"
#define VAR_NETWORK_DEVICE "netDev"
#define VAR_NEWFS_ARGS "newfsArgs"
#define VAR_NFS_PATH "nfs"
#define VAR_NFS_HOST "nfsHost"
#define VAR_NFS_SECURE "nfs_reserved_port_only"

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: install.c,v 1.242 1999/07/18 10:18:05 jkh Exp $
* $Id: install.c,v 1.243 1999/08/05 10:07:09 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1049,6 +1049,7 @@ installVarDefaults(dialogMenuItem *self)
variable_set2(SYSTEM_STATE, "update", 0);
else
variable_set2(SYSTEM_STATE, "init", 0);
variable_set2(VAR_NEWFS_ARGS, "-b 8192 -f 1024", 0);
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: label.c,v 1.89 1999/05/07 04:36:21 jkh Exp $
* $Id: label.c,v 1.90 1999/07/29 06:28:52 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -309,7 +309,8 @@ new_part(char *mpoint, Boolean newfs, u_long size)
ret = (PartInfo *)safe_malloc(sizeof(PartInfo));
sstrncpy(ret->mountpoint, mpoint, FILENAME_MAX);
strcpy(ret->newfs_cmd, "newfs -b 8192 -f 1024");
strcpy(ret->newfs_cmd, "newfs ");
strcat(ret->newfs_cmd, variable_get(VAR_NEWFS_ARGS));
ret->newfs = newfs;
if (!size)
return ret;

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.171 1999/07/19 10:06:17 jkh Exp $
* $Id: sysinstall.h,v 1.172 1999/07/26 10:49:36 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -132,6 +132,7 @@
#define VAR_NETINTERACTIVE "netInteractive"
#define VAR_NETMASK "netmask"
#define VAR_NETWORK_DEVICE "netDev"
#define VAR_NEWFS_ARGS "newfsArgs"
#define VAR_NFS_PATH "nfs"
#define VAR_NFS_HOST "nfsHost"
#define VAR_NFS_SECURE "nfs_reserved_port_only"

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: install.c,v 1.242 1999/07/18 10:18:05 jkh Exp $
* $Id: install.c,v 1.243 1999/08/05 10:07:09 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1049,6 +1049,7 @@ installVarDefaults(dialogMenuItem *self)
variable_set2(SYSTEM_STATE, "update", 0);
else
variable_set2(SYSTEM_STATE, "init", 0);
variable_set2(VAR_NEWFS_ARGS, "-b 8192 -f 1024", 0);
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: label.c,v 1.89 1999/05/07 04:36:21 jkh Exp $
* $Id: label.c,v 1.90 1999/07/29 06:28:52 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -309,7 +309,8 @@ new_part(char *mpoint, Boolean newfs, u_long size)
ret = (PartInfo *)safe_malloc(sizeof(PartInfo));
sstrncpy(ret->mountpoint, mpoint, FILENAME_MAX);
strcpy(ret->newfs_cmd, "newfs -b 8192 -f 1024");
strcpy(ret->newfs_cmd, "newfs ");
strcat(ret->newfs_cmd, variable_get(VAR_NEWFS_ARGS));
ret->newfs = newfs;
if (!size)
return ret;

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated for what's essentially a complete rewrite.
*
* $Id: options.c,v 1.60 1999/05/07 11:02:57 jkh Exp $
* $Id: options.c,v 1.61 1999/07/16 11:13:09 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -94,6 +94,7 @@ mediaCheck(Option opt)
}
#define TAPE_PROMPT "Please enter the tape block size in 512 byte blocks:"
#define NEWFS_PROMPT "Please enter newfs(8) parameters:"
#define RELNAME_PROMPT "Please specify the release you wish to load or\n\"none\" for a generic release install:"
#define BPKG_PROMPT "Please specify the name of the HTML browser package:"
#define BBIN_PROMPT "Please specify a full pathname to the HTML browser binary:"
@ -137,6 +138,8 @@ static Option Options[] = {
OPT_IS_VAR, TIMEOUT_PROMPT, VAR_MEDIA_TIMEOUT, varCheck },
{ "Package Temp", "The directory where package temporary files should go",
OPT_IS_VAR, PKG_PROMPT, VAR_PKG_TMPDIR, varCheck },
{ "Newfs Args", "Default parameters for newfs(8)",
OPT_IS_VAR, NEWFS_PROMPT, VAR_NEWFS_ARGS, varCheck },
{ "Config save", "Whether or not to save installation kernel config changes",
OPT_IS_VAR, NULL, VAR_KGET, varCheck },
{ "Re-scan Devices", "Re-run sysinstall's initial device probe",

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.171 1999/07/19 10:06:17 jkh Exp $
* $Id: sysinstall.h,v 1.172 1999/07/26 10:49:36 brian Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -132,6 +132,7 @@
#define VAR_NETINTERACTIVE "netInteractive"
#define VAR_NETMASK "netmask"
#define VAR_NETWORK_DEVICE "netDev"
#define VAR_NEWFS_ARGS "newfsArgs"
#define VAR_NFS_PATH "nfs"
#define VAR_NFS_HOST "nfsHost"
#define VAR_NFS_SECURE "nfs_reserved_port_only"