I believe I read somewhere that you can do a diff of two ksh scripts and use the output to create a new script with the differences. :p
Could someone please show me the command(s) I'd need to use to get this accomplished? Or perhaps point me to a thread that explains this in detail.
Thanks... (1 Reply)
help trying to figure out a batch shell script to zip each file in a directory into its own zip file
using this code but it does not work
tryed this also
nothing seems to work , just ends without zipping any files
i have over 3000 files i need to zip up individualy
... (7 Replies)
Hi All,
I am using the awk command to replace ',' by '\t' (tabs) in a csv file. I would like to apply this to all .csv files in a directory and create .txt files with the tabs.
How would I do this in a script?
I have the following script called "csvtabs":
awk 'BEGIN {
FS... (4 Replies)
Hi,
I have a situation to compare one file, say file1.txt with a set of files in directory.The directory contains more than 100 files.
To be more precise, the requirement is to compare the first field of file1.txt with the first field in all the files in the directory.The files in the... (10 Replies)
Hi All,
I have some data like below.
Step1,Param1,Param2,Param3
1,2,3,4
2,3,4,5
2,4,5,6
3,0,1,2
3,0,0,0
3,2,1,3
........
so on
Where I need to find the median(arithmetic) of each column from Param1...to..Param3 for each set of Step1 values.
(Sort each specific column, if the... (5 Replies)
Hi all,
I'll like to search a list of tems in a huge file and then output each of the terms to individual files. I know I can use grep -f list main.file to search them but how can I split the output into individual files? Thank you. (6 Replies)
Hi All,
I am new here but I have a scripting question that I can't seem to figure out with the "find" cmd.
What I am trying to do is to only have to run a single find cmd parsing the directories and output the different file types to induvidual files and I have been running into problems.... (3 Replies)
Hi ,
I'm trying to list the files and output is written to a file. But when I execute the command , the output file is being listed. How to exclude it ?
/tmp
file1.txt
file2.txt
ls -ltr |grep -v '-' | awk print {$9, $5} > output.txt
cat output.txt
file1.txt
file2.txt
output.txt (8 Replies)
Discussion started by: etldeveloper
8 Replies
LEARN ABOUT OSF1
makedbm
makedbm(8) System Manager's Manual makedbm(8)NAME
makedbm - Makes a Network Information Service (NIS) dbm file
SYNOPSIS
/var/yp/makedbm [-i yp_input_file] [-s yp_secure_name] [-a method] [-o yp_output_name] [-d yp_domain_name] [-m yp_master_name] infile out-
file
/var/yp/makedbm [-u dbmfilename]
OPTIONS
Specifies that NIS maps are to be stored in one of the following formats: btree -- Recommended when creating and maintaining very large
maps. dbm/ndbm -- For backward compatibility. This is the default. hash -- A potentially quicker method for managing small maps. Cre-
ates a special entry with the key yp_input_file. Creates a special entry with the key yp_secure_file. This causes the makedbm command to
write a secure map. The key value ypserver looks for YP_SECURE. Creates a special entry with the key yp_output_name. Creates a special
entry with the key yp_domain_name. Creates a special entry with the key yp_master_name. If no master host name is specified, yp_mas-
ter_name will be set to the local host name. Undoes a dbm file. That is, prints out a dbm file one entry per line, with a single space
separating keys from values.
DESCRIPTION
The makedbm command takes the file specified by the argument infile and converts it to a single file or a pair of files in dbm(3),
btree(3), or hash(3) format. The dbm(3) files are stored as outfile.pag and outfile.dir. The btree(3) files are stored as outfile.btree.
Each line of the input file is converted to a single dbm record. All characters up to the first tab or space form the key, and the rest of
the line is defined as the key's associated data. If a line ends with a backslash (), the data for that record is continued onto the next
line. It is left for the Network Information Service (NIS) clients to interpret the number sign (#); makedbm does not treat it as a comment
character. The infile parameter can be a hyphen (-), in which case makedbm reads the standard input.
The makedbm command is meant to be used in generating database files for NIS. The makedbm command generates a special entry with the key
yp_last_modified, which is the date of infile.
RESTRICTIONS
You must use the same database format for each map in a domain. In addition, a server serving multiple NIS domains must use the same data-
base format for all domains.
Although a Tru64 UNIX NIS server that takes advantage of btree files will be able to store very large maps, NIS slave servers that lack
this feature might have a much smaller limit on the number of map entries they can handle. It may not be possible to distribute very large
maps from a Tru64 UNIX NIS master server to a slave server that lacks support for very large maps. NIS clients are not affected by these
enhancements.
EXAMPLES
The following example shows how a combination of commands can be used to make the NIS dbm files passwd.byname.pag and passwd.byname.dir
from the /etc/passwd file. The percent sign (%) signifies the system prompt. % awk 'BEGIN { FS = ":"; OFS = " "; }
{ print $1, $0 }' /etc/passwd > ptmp % makedbm ptmp passwd.byname % rm ptmp
The awk command creates the file ptmp which is in a form usable by makedbm. The makedbm command uses the ptmp file to create the
database files. The rm command removes the ptmp file. The following is an example of the makedb command used with the btree format
database routine to store NIS maps. makedbm -a b ...
SEE ALSO
Commands: yppasswd(1), ypmake(8)
Functions: btree(3), dbm(3), dbopen(3), hash(3), ndbm(3)makedbm(8)