On Tue, 22 Oct 2002, Darrell May wrote: > [Seagate STT20000A 20GB IDE] > - Tape block size: [ 10 ] ... > [OnStream ADR260.IDE] > - Tape block size: [ 32 ] ...
Since your template contains: $mt_var_blksize = 'true'; the blocksize setting will be ignored for dd commands. Perhaps you want the blocksize to be used for all commands, in which case you need to set $mt_var_blksize to 'false'. I suggest instead of: { # Block size (k) to use (default for most things is 10) use esmith::db; my %conf; tie %conf, 'esmith::config'; # Block size (k) to use (default for most things is 10) my $blksize = db_get_prop(\%conf, "flexbackup", "blksize") || "10"; $OUT .="\$blksize = \'$blksize\'\;\n"; # True to use "variable" block size for the tape device (mt setblk 0) # If false, will use the $blksize parameter above. All non-mt commands # will still use $blksize regardless of this value $OUT .="\$mt_var_blksize = \'true\'\;\n"; } you have: { my $blksize = db_get_prop(\%conf, "flexbackup", "blksize"); if (defined $blksize) { $OUT .="\$blksize = \'$blksize\'\;\n"; $OUT .="\$mt_var_blksize = \'false\'\;\n"; } else { $OUT .="\$blksize = \'10\'\;\n"; $OUT .="\$mt_var_blksize = \'true\'\;\n"; } } (there's no need to set up %conf since it is implicitly available to all templates). Or, for version 5.5 and 5.6, you can access configuration settings as predefined variables (plus we can eliminate some excessive escapes): { my $blksize = $flexbackup{blksize}; $OUT = (defined $blksize) ? "\$blksize = '$blksize';\n\$mt_var_blksize = 'false';" : "\$blksize = '10';\n\$mt_var_blksize = 'true';"; } I prefer to have properties capitalised, and spelt fully, so would use BlockSize rather than blksize as the property name. -- Charlie Brady [EMAIL PROTECTED] Lead Product Developer Network Server Solutions Group http://www.e-smith.com/ Mitel Networks Corporation http://www.mitel.com/ Phone: +1 (613) 592 5660 or 592 2122 Fax: +1 (613) 592 1175 -- Please report bugs to [EMAIL PROTECTED] Please mail [EMAIL PROTECTED] (only) to discuss security issues Support for registered customers and partners to [EMAIL PROTECTED] To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Searchable archive at http://www.mail-archive.com/devinfo%40lists.e-smith.org