Sponsored Content
Top Forums Shell Programming and Scripting Difference between WHILE and FOR loops Post 302941961 by mccmjc on Thursday 23rd of April 2015 06:52:27 AM
Old 04-23-2015
Hi disedorgue,

I still get the same when using that method:

Code:
[chris@x] while read HOST; do ssh $HOST; done <dbs_group
Pseudo-terminal will not be allocated because stdin is not a terminal.
-bash: line 1: xxx1: command not found
-bash: line 2: xxx2: command not found
-bash: line 3: xxx3: command not found
-bash: line 4: xxx4: command not found
-bash: line 5: xxx5: command not found
[chris@x]

Cheers,

Chris
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

While loops

Hi all, I am an amateur k shell scripter and came across something I need clarification on. while ; do various commands done What is the "" condition testing for in the above while loop? THx, Bookoo (5 Replies)
Discussion started by: bookoo
5 Replies

2. UNIX for Dummies Questions & Answers

While Loops

I'm trying to create a loop that will prompt the user for 15 values, not forcing them to enter all 15. If the user enters through one or more of the prompts the null value needs to be converted to 0, otherwise set the parameter = to the value entered: ex. Please enter file no #1: 17920 ... (4 Replies)
Discussion started by: vdc
4 Replies

3. UNIX for Dummies Questions & Answers

loops with tr

Hello, I'm not sure if this is more appropriate for the 'unix for dummies' or the 'unix for experts' forum because I'm new to this forum and this is the second topic I've discussed, but if you could let me know which one was more appropriate for something like this, please do! So in tr (an... (2 Replies)
Discussion started by: juliette salexa
2 Replies

4. Shell Programming and Scripting

loops

Hi All I have some directories on our server which are containing .csv files. i need to print value of cell "B2" from those csv files. Please advise. I have tried head command as example: head -2 */Book_Collection_Report_1_-_Collection_Requests_trials.csv | sed -n "3p" | awk -F","... (4 Replies)
Discussion started by: yash1978
4 Replies

5. Shell Programming and Scripting

Loops

Hi All, I am very new to Shell scripting. I read basic scripting manual. But i didn't understand the code. Please tell the meaning of the below code: while getopts "F:f:R:r:C:c:" opt 2>/dev/null do case ${opt} in F|f) FREQUENCY_MODE=$OPTARG;; ... (3 Replies)
Discussion started by: pdathu
3 Replies

6. Shell Programming and Scripting

Find with in loops and then difference

Hi All, Please find my problem below: I have a file at two different nodes dev and test 1st find> find /u/dev/local/abc -name ab.dat --Since this file can be in several sub directories 2nd find> find /u/test/local/abc -name ab.dat I find my 1st find result and do compare with 2nd... (5 Replies)
Discussion started by: varun_bharadwaj
5 Replies

7. Programming

what is the main difference between difference between using nonatomic lseek and O_APPEND

I think both write at the end of the file ...... but is there a sharp difference between those 2 instruction ..... thank you this is my 3rd question today forgive me :D (1 Reply)
Discussion started by: fwrlfo
1 Replies

8. Homework & Coursework Questions

If and Loops

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: In this script you will take a directory as input from the user and change the end of line sequence from a Unix... (1 Reply)
Discussion started by: Pcarson
1 Replies

9. UNIX for Dummies Questions & Answers

Need help with for loops

Why wont my for statements work? Im trying to get this script to swich to a user an if you put in a start/stop/or restart paramater to do just that for each user. I commented out the actual start/stop actions to test it just by using echos and not do anything hasty in the environment but it... (0 Replies)
Discussion started by: LilyClaro
0 Replies

10. Shell Programming and Scripting

awk to calculate difference of split and sum the difference

In the awk I am trying to subtract the difference $3-$2 of each matching $4 before the first _ (underscore) and print that value in $13. I think the awk will do that, but added comments. What I am not sure off is how to add a line or lines that will add sum each matching $13 value and put it in... (2 Replies)
Discussion started by: cmccabe
2 Replies
ql-set-cmd-timeout(8)					       System Administration					     ql-set-cmd-timeout(8)

NAME
ql-set-cmd-timeout - set the timeout on the devices connected to the QLogic FC HBA. SYNOPSIS
ql-set-cmd-timeout [OPTIONS] DESCRIPTION
QLogic Linux Set Device Timeout Utility This utility allows you to set the timeout on the devices connected to the QLogic FC HBA. This timeout value applies to the commands sent to the device. This can help when target devices take longer to execute a command, for example under heavy I/O. Setting a longer timeout reduces the chance of the Linux SCSI mid-layer driver aborting the tasks after a timeout. [DEFAULT] Display timeout of devices connected to all HOSTs [HOST] Display timeout of devices connected to HOST [HOST] [TARGET] Display timeout of devices connected to a TARGET on HOST [HOST] [TARGET] [TIMEOUT] To set timeout on devices connected to a TARGET on HOST -h, --help, ? Prints this help message -i, --interactive Use this option to use the menu driven program SEE ALSO
ql-dynamic-tgt-lun-disc(8), ql-lun-state-online(8), ql-hba-snapshot(8) Matthias Schmitz <;matthias@sigxcpu.org> August 2008 ql-set-cmd-timeout(8)
All times are GMT -4. The time now is 03:28 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy