From 7117f963c2a530493ce54c93224bf845685c7adc Mon Sep 17 00:00:00 2001 From: phk Date: Thu, 5 Aug 1999 19:50:26 +0000 Subject: 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. --- usr.sbin/sade/install.c | 3 ++- usr.sbin/sade/label.c | 5 +++-- usr.sbin/sade/sade.h | 3 ++- usr.sbin/sysinstall/install.c | 3 ++- usr.sbin/sysinstall/label.c | 5 +++-- usr.sbin/sysinstall/options.c | 5 ++++- usr.sbin/sysinstall/sysinstall.h | 3 ++- 7 files changed, 18 insertions(+), 9 deletions(-) (limited to 'usr.sbin') diff --git a/usr.sbin/sade/install.c b/usr.sbin/sade/install.c index bce4e1c..4a26db0 100644 --- a/usr.sbin/sade/install.c +++ b/usr.sbin/sade/install.c @@ -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; } diff --git a/usr.sbin/sade/label.c b/usr.sbin/sade/label.c index 7d56a4c..1b34e20 100644 --- a/usr.sbin/sade/label.c +++ b/usr.sbin/sade/label.c @@ -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; diff --git a/usr.sbin/sade/sade.h b/usr.sbin/sade/sade.h index 76d1c00..6a6a6ad 100644 --- a/usr.sbin/sade/sade.h +++ b/usr.sbin/sade/sade.h @@ -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" diff --git a/usr.sbin/sysinstall/install.c b/usr.sbin/sysinstall/install.c index bce4e1c..4a26db0 100644 --- a/usr.sbin/sysinstall/install.c +++ b/usr.sbin/sysinstall/install.c @@ -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; } diff --git a/usr.sbin/sysinstall/label.c b/usr.sbin/sysinstall/label.c index 7d56a4c..1b34e20 100644 --- a/usr.sbin/sysinstall/label.c +++ b/usr.sbin/sysinstall/label.c @@ -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; diff --git a/usr.sbin/sysinstall/options.c b/usr.sbin/sysinstall/options.c index f8f7de9..ac314ce 100644 --- a/usr.sbin/sysinstall/options.c +++ b/usr.sbin/sysinstall/options.c @@ -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", diff --git a/usr.sbin/sysinstall/sysinstall.h b/usr.sbin/sysinstall/sysinstall.h index 76d1c00..6a6a6ad 100644 --- a/usr.sbin/sysinstall/sysinstall.h +++ b/usr.sbin/sysinstall/sysinstall.h @@ -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" -- cgit v1.1