04-07-2015
pipe the 'awk' output into whatever you want to get you random output.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello all,
I need some help to create a script which contain a few strings on every line, and use those strings in a loop to fire some commands.
for exmaple the file looks like
tom
dave
bill
andy
paul
I want to read one line at a time and use it in loop like
command tom
command dave... (3 Replies)
Discussion started by: xboxer21
3 Replies
2. UNIX for Dummies Questions & Answers
Hi ,
can some give me idea about how to use do...done while loop in UNIX to read the contents of a file.. (2 Replies)
Discussion started by: sreenusola
2 Replies
3. Shell Programming and Scripting
Guys,
I am trying to read the whole file using while loop but when i run the ssh part of the script it reads only the first line and exit after that.
There are in total 134 lines in the file, but when the output is redirected, it does only for one line and comes to command prompt.
pls help..... (11 Replies)
Discussion started by: sdosanjh
11 Replies
4. SCO
After System power get failed
File system is not getting mounted in read- write mode (1 Reply)
Discussion started by: gtkpmbpl
1 Replies
5. Shell Programming and Scripting
Hi
As a newbe in scripting, i struggle hard with my first script.
What i want to do is, bringing data of two files together.
file1:
....
05/14/12-04:00:00 41253 4259 5135 5604 5812 5372
05/14/12-04:10:00 53408 5501 6592 7402 7354 6639
05/14/12-04:20:00 58748 6037 7292 8223... (13 Replies)
Discussion started by: IMPe
13 Replies
6. UNIX for Dummies Questions & Answers
I have a file of protein sequences with headers (my source file). Based on a list of IDs (which are included in some of the headers), I'd like to print out only the specified sequences, with only the ID as header.
In other words, I'd like to search source.txt for the terms in IDs.txt, and print... (3 Replies)
Discussion started by: pathunkathunk
3 Replies
7. Shell Programming and Scripting
Hello,
I have a huge file, I am currently using while loop to read and do some calculation on it, but it is taking a lot of time.
I want to use AWK to read and do those calculations.
Please suggest.
currently doing:
cat input2 | while read var1
do
num=`echo $var1 | awk... (6 Replies)
Discussion started by: anand2308
6 Replies
8. Shell Programming and Scripting
Hello,
I have a set of files Xfile0001 - Xfile0021, and the content of this files (one at a time) needs to be printed between some line (lines start with word "Generated") that I am extracting from another file called file7.txt and all the output goes into output.txt. First I tried creating a for... (5 Replies)
Discussion started by: jaldo0805
5 Replies
9. Shell Programming and Scripting
I have files named with different prefixes. From each I want to extract the first line containing a specific string, and then print that line along with the prefix.
I've tried to do this with a while loop, but instead of printing the prefix I print the first line of the file twice.
Files:... (3 Replies)
Discussion started by: pathunkathunk
3 Replies
10. Shell Programming and Scripting
Hi everybody,
I am new at Unix/Bourne shell scripting and with my youngest experiences, I will not become very old with it :o
My code:
#!/bin/sh
set -e
set -u
export IFS=
optl="Optl"
LOCSTORCLI="/opt/lsi/storcli/storcli"
($LOCSTORCLI /c0 /vall show | grep RAID | cut -d " "... (5 Replies)
Discussion started by: Subsonic66
5 Replies
LEARN ABOUT DEBIAN
bup-random
bup-random(1) General Commands Manual bup-random(1)
NAME
bup-random - generate a stream of random output
SYNOPSIS
bup random [-S seed] [-fv]
DESCRIPTION
bup random produces a stream of pseudorandom output bytes to stdout. Note: the bytes are not generated using a cryptographic algorithm and
should never be used for security.
Note that the stream of random bytes will be identical every time bup random is run, unless you provide a different seed value. This is
intentional: the purpose of this program is to be able to run repeatable tests on large amounts of data, so we want identical data every
time.
bup random generates about 240 megabytes per second on a modern test system (Intel Core2), which is faster than you could achieve by read-
ing data from most disks. Thus, it can be helpful when running microbenchmarks.
OPTIONS
the number of bytes of data to generate.
Can be used with the suffices k, M, or G to indicate kilobytes, megabytes, or gigabytes, respectively.
-S, --seed=seed
use the given value to seed the pseudorandom number generator. The generated output stream will be identical for every stream
seeded with the same value. The default seed is 1. A seed value of 0 is equivalent to 1.
-f, --force
generate output even if stdout is a tty. (Generating random data to a tty is generally considered ill-advised, but you can do if
you really want.)
-v, --verbose
print a progress message showing the number of bytes that has been output so far.
EXAMPLES
$ bup random 1k | sha1sum
2108c55d0a2687c8dacf9192677c58437a55db71 -
$ bup random -S1 1k | sha1sum
2108c55d0a2687c8dacf9192677c58437a55db71 -
$ bup random -S2 1k | sha1sum
f71acb90e135d98dad7efc136e8d2cc30573e71a -
$ time bup random 1G >/dev/null
Random: 1024 Mbytes, done.
real 0m4.261s
user 0m4.048s
sys 0m0.172s
$ bup random 1G | bup split -t --bench
Random: 1024 Mbytes, done.
bup: 1048576.00kbytes in 18.59 secs = 56417.78 kbytes/sec
1092599b9c7b2909652ef1e6edac0796bfbfc573
BUP
Part of the bup(1) suite.
AUTHORS
Avery Pennarun <apenwarr@gmail.com>.
Bup unknown- bup-random(1)