02-16-2007
Thanks anbu23 and matrixmadhan!
It worked!
Cheers
Steve
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am trying write a script that takes user input date in the format "Mar 18". If it is march1 it is like "Mar 1" . Once i take this input i will go back to my log files and search for any failed transactions recorded that day. If there are then i will send it to a file and mail it.
I am... (10 Replies)
Discussion started by: gundu
10 Replies
2. UNIX for Dummies Questions & Answers
how would i accept user input from the keyboard? (2 Replies)
Discussion started by: JamieMurry
2 Replies
3. Shell Programming and Scripting
Hi,
echo "Enter file name of input file list along with absolute path : "
read inputFileList
if
then
for string in `cat inputFileList`
do
echo $string
done
else
echo " file does not exist"
fi
From the above code, if the user enters a invalid file... (1 Reply)
Discussion started by: i.srini89
1 Replies
4. Shell Programming and Scripting
i have a script which takes input from user, if user gives either Y/y then it should continue, else it should quit by displaying user cancelled.
#!/bin/sh
echo " Enter your choice to continue y/Y OR n/N to quit "
read A
if
then
echo " user requested to continue "
##some commands... (7 Replies)
Discussion started by: only4satish
7 Replies
5. Shell Programming and Scripting
Hi,
I need my script to check if the user enters 3 values if not 5 values to my script and alert if the input has any other number of values.
for example:
./myscript.sh 22 56 3221 - > correct
./myscript.sh 22 56 3221 45 777 -> correct
./myscript.sh 22 56 3221 45 -> incorrect
Please... (6 Replies)
Discussion started by: mohtashims
6 Replies
6. Shell Programming and Scripting
Hi,
The user inputs either "/tmp/bea" or "/tmp/bea/". Regardless my script should extract and store in a variable the last directory in the user input path.
Desired output: "bea"
Please help. (6 Replies)
Discussion started by: mohtashims
6 Replies
7. Shell Programming and Scripting
$Input_filename=$ARGV;
if (!-d $Input_filename && ! -e $Input_filename)
{
print "USAGE: Please enter '$ABCD/def/dsed.txt' as an arguement \n";
exit;
}
1. Input Is suppose to be something like "$ABCD/def/dsed.txt".
if the input is wrong the script should throw an ERROR message.... (2 Replies)
Discussion started by: Rashid Khan
2 Replies
8. UNIX for Dummies Questions & Answers
The (longer) script that I am working on does something like this:
#!/bin/bash
while true
do
clear
sleep 1
shuf -i1-2 -n1
sleep .1
clear
echo "Press 1 if you saw a 1. Press 2 if you saw a 2."
read -s -n1 RESPONSE
done
If the user accidentally presses two... (1 Reply)
Discussion started by: darwin_886
1 Replies
9. Shell Programming and Scripting
I am trying to allow a user to enter in text and then store that text in a variable $gene to run in an awk command in which those values are used to run some calculations. I am getting syntax errors however, when I try. Thank you :).
The awk runs great if it is a pre-defined file that is used,... (7 Replies)
Discussion started by: cmccabe
7 Replies
10. Shell Programming and Scripting
I'm trying to use a bash script for a psych experiment that involves listening to sound files and responding. If I have something like the code below, how can I make sure that a key press is assigned to RESPONSE only after the second echo statement?
for i in 1 2 3; do
echo "Ready?"
sleep 2
... (10 Replies)
Discussion started by: darwin_886
10 Replies
LEARN ABOUT DEBIAN
xen-update-image
XEN-UPDATE-IMAGE(8) Perl Programmers Reference Guide XEN-UPDATE-IMAGE(8)
NAME
xen-update-image - Update the software installed upon offline Xen images.
SYNOPSIS
xen-update-image [options] imageName1 imageName2 .. imageNameN
Help Options:
--help Show this scripts help information.
--manual Read this scripts manual.
--version Show the version number and exit.
General Options:
--dir Specify the directory which contains the image(s).
--lvm Specify the LVM volume group which contains the image(s).
--evms Specify the EVMS container which contains the image(s).
OPTIONS
--dir Specify the directory which contains the image(s).
--evms Specify the EVMS container which contains the image(s).
--help Show the script help.
--lvm Specify the LVM volume group which contains the image(s).
--manual Read the manual.
--version Show the version number and exit.
DESCRIPTION
xen-update-image is a simple script which allows you to update
a Xen image of Debian which has been created with xen-create-image.
It does this by mounting the image inside a temporary directory
then running:
apt-get update
apt-get upgrade
NOTE If the image is already running within Xen this will cause
corruption otherwise it will allow you to update your image without
booting it.
EXAMPLES
The following assumes there are two images which are not currently
running. The images are called 'test.my.flat', and 'x11.my.flat'.
Updating both images can be accomplished by executing:
xen-update-images --dir=/home/xen test.my.flat x11.my.flat
AUTHORS
Steve Kemp, http://www.steve.org.uk/
Axel Beckert, http://noone.org/abe/
StA~Xphane Jourdois
LICENSE
Copyright (c) 2005-2009 by Steve Kemp, (c) 2010 by The Xen-Tools Development Team. All rights reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The LICENSE file contains the
full text of the license.
4.3.1 2012-06-30 XEN-UPDATE-IMAGE(8)