10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I'm trying to achieve the follwoinig with no luck.
Find the directories that are greater than 50GB in size and pick the owner of the directory as I would like to send an alert notification.
du -sh * | sort -rh
139G Dir_1
84G Dir_2
15G Dir_3
ls -l Dir_1
drwx------ 2... (3 Replies)
Discussion started by: 308002184
3 Replies
2. Shell Programming and Scripting
I want to create an array which can store the strings from the user input in shell script .
example :-
I want to store the 5 fruits name in a single array which the user provides . (1 Reply)
Discussion started by: Pkast
1 Replies
3. UNIX for Dummies Questions & Answers
Hi,
when I enter 'ps -ef| grep process_name'/'psu | grep process_name', i am getting multiple number of lines output( i mean multiple no of processes).how can i store it one by one and echo it in the same way(one by one).
part of script is
var1=$(remsh hostname -l username ps -ef|grep... (2 Replies)
Discussion started by: jeanzibbin
2 Replies
4. Shell Programming and Scripting
Hi all,
I want to split a string into array based on given delimiter, for example:
String:
"foo|bar|baz"
with delimiter "|"
into array:
strArr to strArr with values foo, bar and baz.
Thanks a lot.
Roy987 (5 Replies)
Discussion started by: Roy987
5 Replies
5. Shell Programming and Scripting
Dear All,
I have been trying to do a simple task of extracting 2 fields from the file (3 rows) and store it in an array variable. I tried with:
#! /bin/bash
ch=`cut -f10 tmp.txt`
counter=0
for p in $pid
do
c=${ch}
echo "$c ..$counter"
counter=$((counter+1))... (2 Replies)
Discussion started by: ezhil01
2 Replies
6. Shell Programming and Scripting
consider this is a line A#B#C#D#E#F#G#H
note the delimeter is #
i want to cut or spilt in to fields using the delimeter # and to store in an array.
like this
array=A
array=B
array=C
array=D
array=E
and the array content should be displayed.
echo "${array}"
echo "${array}"... (5 Replies)
Discussion started by: barani75
5 Replies
7. Shell Programming and Scripting
Hi,
the csv file with the delimeter #.
A#B#C#D#E#F#G#H
1#2#3#4#5#6#7#8
Z#x#c#V
7#2#8#9
N.
I want to read the file line by line and store in rowarray.
then the rowarray content should be spilt or made to fields using the delimeter #.
i am not sure can we store the fields in to... (3 Replies)
Discussion started by: barani75
3 Replies
8. Shell Programming and Scripting
I want to store contents of command
dir in array of variables
For eg: dir contents are
command d2 demovi~ file inven java new untitled folder
d1 demovi er1 filename inven~ myfiles ubuntu desktop xmms
-----------------------------------
I... (3 Replies)
Discussion started by: netresearch
3 Replies
9. Shell Programming and Scripting
:)
Suppose,I have one table A. Table A have one column. Table A have 10 rows. I want this 10 rows store into shell script variable.
like
#!/bin/ksh
v_shell_var=Hi
here in call oracle , through loop How can I store table A's 10 rows into v_shell_var (Shell Script Array).
Regards,
Div (4 Replies)
Discussion started by: div_Neev
4 Replies
10. UNIX for Advanced & Expert Users
Hi,
Is is possible to get the value using shell script?
x=1
y1 = 10
y2 = 15
y3 = 7
echo $y$x is giving y1 (variable name)
but I need the value of y1 (i.e. 10 dynamically)
Is there any solution?
if so, please mail me at kkodava@maxis.com.my
... (2 Replies)
Discussion started by: krishna
2 Replies