10-22-2007
Quote:
Originally Posted by
harim
Hi Perderabo,
i am recieving the following error message while executing the above snippet of code.
could you advice what should i do to avoid the below error
test3: line 25: syntax error near unexpected token `&'
test3: line 25: `ftp -nv >&4 2>&4 | &'
Cut and paste if you can't get the syntax right. There is no space between the | and the & in my code. You added a space between them.
10 More Discussions You Might Find Interesting
1. Programming
Hey all,
I'm writting my first C program (Apart from the little ones I did to learn the program).
What I want for this program to do is ping a range of IP's and then place the reply if alive into a file the compare all in that file to the /etc/hosts file to find the host name.
I know I... (2 Replies)
Discussion started by: merlin
2 Replies
2. Shell Programming and Scripting
ok, i tried to write a script called purge.sh
which searches current process' for a specified user running a process with a specified keyword. it also prompts the user to see how many times to purge for the specified process and how many different processes they wish to do this to.it worked until... (11 Replies)
Discussion started by: Blip
11 Replies
3. Shell Programming and Scripting
Dear friends,
please tell me how to identify the type of the shell (whether cShell, kshell or anything else)
please tell me the command.
waiting for ur reply....
regards,
swamymns (2 Replies)
Discussion started by: swamymns
2 Replies
4. Shell Programming and Scripting
Hi guys,
i need to script the sending of multiple files through one ftp session. I have done this so far:
----------------------------------------------------------------
#!/bin/sh
USER=myuser
PASSWD=mypass
filenum=$1
x=0
ftp -n 159.167.95.199 <<SCRIPT
user $USER $PASSWD
binary
while ... (4 Replies)
Discussion started by: zaff
4 Replies
5. Cybersecurity
hi,
i want to put a set of commands inside a script and executing commands sequentially. there are 2 commands, the first command copies the program from my machine to another machine, execute it and get the result on my machine. the second command removes the program which was copied to the... (4 Replies)
Discussion started by: mercuryshipzz
4 Replies
6. Solaris
Hi everbody,
Can anyone let me know the resources for list of network, process, database related commands of solaris10 possibly with little bit of explanation.
Thanks in advance,
Chandra Sekhar. (1 Reply)
Discussion started by: chandoo.java
1 Replies
7. Shell Programming and Scripting
Hello All,
I have another Korn shell question. I am writing a script that will ftp a file from my production database to my test database.
To this, I have to construct a loop that checks a specified folder for a file.
If the file exists, I want it execute the ftp protocol and then exit. ... (2 Replies)
Discussion started by: jonesdk5
2 Replies
8. Shell Programming and Scripting
Hi guys I am trying to get a bunch of lines into a .sh script that will let me easily run a bunch of commands on its own without me having to be there... I have done this with other things but apparetnly it doesn't like to use yum.. I will post my script you will see what im trying to do..
... (3 Replies)
Discussion started by: Bigstack
3 Replies
9. UNIX for Dummies Questions & Answers
hi, I have a litle problem i wish to excute this comand :
./test.sh -e txt /home -l a
so what it says is that "-e" shows me all the extenions that are ".txt" in "home" this works but then i wish that "-l" will show all files begining in this case with the letter "a" . Both comands work... (5 Replies)
Discussion started by: samirboss
5 Replies
10. Shell Programming and Scripting
plz let me know what the below ftp is doing it .
ftp -m amazon-d . -i /test/load/y748_W*.stc (1 Reply)
Discussion started by: ramkumar15
1 Replies
LEARN ABOUT OPENDARWIN
while
while(n) Tcl Built-In Commands while(n)
__________________________________________________________________________________________________________________________________________________
NAME
while - Execute script repeatedly as long as a condition is met
SYNOPSIS
while test body
_________________________________________________________________
DESCRIPTION
The while command evaluates test as an expression (in the same way that expr evaluates its argument). The value of the expression must a
proper boolean value; if it is a true value then body is executed by passing it to the Tcl interpreter. Once body has been executed then
test is evaluated again, and the process repeats until eventually test evaluates to a false boolean value. Continue commands may be exe-
cuted inside body to terminate the current iteration of the loop, and break commands may be executed inside body to cause immediate termi-
nation of the while command. The while command always returns an empty string.
Note: test should almost always be enclosed in braces. If not, variable substitutions will be made before the while command starts execut-
ing, which means that variable changes made by the loop body will not be considered in the expression. This is likely to result in an
infinite loop. If test is enclosed in braces, variable substitutions are delayed until the expression is evaluated (before each loop iter-
ation), so changes in the variables will be visible. For an example, try the following script with and without the braces around $x<10:
set x 0
while {$x<10} {
puts "x is $x"
incr x
}
SEE ALSO
break(n), continue(n), for(n), foreach(n)
KEYWORDS
boolean value, loop, test, while
Tcl while(n)