05-14-2009
change the "=" to "==" . by the way, your code has a lot of processing overheads.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
set -A arr a1 a2 a3 a4
# START
ssh -xq $Server1 -l $Username /usr/bin/ksh <<-EOS
integer j=0
for loop in ${arr}
do
printf "array - ${arr}\n"
(( j = j + 1 ))
j=`expr j+1`
done
EOS
# END
=========
this is not giving me correct output.
I... (5 Replies)
Discussion started by: reldb
5 Replies
2. Shell Programming and Scripting
I'm trying to understand if it's possible to create a set of variables that are numbered based on another variable (using eval) in a loop, and then call on it before the loop ends.
As an example I've written a script called question (The fist command is to show what is the contents of the... (2 Replies)
Discussion started by: DeCoTwc
2 Replies
3. Shell Programming and Scripting
Hi Im running this script, which is supposed to find the max value build some tables and then stop running once all the tables are built. Thing is , it keeps assigning a null value to $h and then $g is null so it keep building tables i.e. testupdateNUL. How can I stop this? Here is what I have:
... (4 Replies)
Discussion started by: brandono66
4 Replies
4. Shell Programming and Scripting
Hi,
First post, so I hope someone can help me with this weirdness :)
I have a number files with some rows of information I want to extract, at the same time I want to add to a string some details from the file. I have found two different ways of looping over rows in a file, but one method... (5 Replies)
Discussion started by: LostInTheWoods
5 Replies
5. Shell Programming and Scripting
Hi all
Sorry for the basic question, but i am writing a shell script to get around a slightly flaky binary that ships with one of our servers. This particular utility randomly generates the correct information and could work first time or may work on the 12th or 100th attempt etc !.... (4 Replies)
Discussion started by: rethink
4 Replies
6. Shell Programming and Scripting
Hi,
In the code included below, the string comparision is not working fine. Please help
while (( find_out >= i ))
do
file=`head -$i f.out|tail -1`
dir=`dirname $file`
cd $dir
Status=""
if ; then
Status=`cvs -Q status... (3 Replies)
Discussion started by: sudvishw
3 Replies
7. Shell Programming and Scripting
The string comparison highlighted below is not working fine. Please help:
while read line
do
# Get File name by deleting everything that preceedes and follows Filename as printed in cvs status' output
f_name=`echo $line | sed -e 's/^File://' -e 's/ *Status:.*//' | awk '{print $NF}'`
... (4 Replies)
Discussion started by: sudvishw
4 Replies
8. Shell Programming and Scripting
I'm a beginner in shell scripting (I'm using ksh). I'm manipulating some files and I'm using set -A to transform each read line into a numeric array.
However, inside the 'for' loop the options of set (ie '-A') are not recognized (the vi editor doesn't highlight it and it doesn't work).
Where... (4 Replies)
Discussion started by: kasumlolla
4 Replies
9. Shell Programming and Scripting
check_deplver ()
{
dir=/abc/def/ghi
if ssh -o StrictHostKeychecking=no $1 "" 2> /dev/null
then
echo " output is "
ssh -o StrictHostKeychecking=no $1 "ls -lrt $dir | grep -i abc" 2> /dev/null
else
echo " directory not presnt"
fi
}
This is not working.
But... (7 Replies)
Discussion started by: NarayanaPrakash
7 Replies
10. Shell Programming and Scripting
Hi,
I have a perl script which is just reading from the file but what I would like to understand is how the counter is moving without using the loop in the script.
Below are the details:
$ more /tmp/abc.txt
This is 0
This is 1
This is 2
This is 3
This is 4
This is 5
This is 6
This... (2 Replies)
Discussion started by: siddharthjindal
2 Replies
LEARN ABOUT DEBIAN
jablicator
JABLICATOR(1) General Commands Manual JABLICATOR(1)
NAME
jablicator - Share package collection choice across machines
SYNOPSIS
jablicator [--root <path>]
DESCRIPTION
jablicator generates an "apt-get"-able package. The package itself is empty. However it has a dependency for every non-required Debian
package that is on the machine. This program will create and populate two directories dists and pool in your working directory. You can
then move them to a web accessible location.
This utility is designed to reduce software distribution and maintenance costs by reducing redundant system administration. For example, I
have spent a lot of time finding and vetting image processing software from Debian's large package collection. With this utility, my image
processing colleague down the hall can easily benefit from the fruit of my labor.
There are many replication techniques in Debian. This one has the advantage of using the apt and dpkg infrastructure. A disadvantage is the
possibility of packages changing out from under you in the Debian distribution (especially in testing or unstable). That means that jabli-
cator output can grow stale over time if it is not regenerated.
SECURITY
The packages produced by this program contain a lot of information, including a list of the Debian packages installed on the machine and a
listing of apt-get sources. Some system administrators consider sharing such information a security risk.
FILES
/etc/apt/sources.list
OPTIONS
--root <path>
Being able to pull in package selections from another install can be helpful, in the cases of a non-functional system, or reading
from a hard drive install under Knoppix. In other words, source from a root filesystem that is not mounted at the root. This is a
rare situation and most users should not use this option.
SEE ALSO
dpkg(8) apt-get(8).
AUTHOR
Jeff Breidenbach <jab@debian.org>.
THANKS
Tom Parks, Cliff Weinstein, Burkhard Perkens-Golomb.
Debian/GNU Linux September 2001 JABLICATOR(1)