Search Results

Search: Posts Made By: looney
987
Posted By looney
Website is up and running
I want to check if web url is up and running through command or script. I will use that output in one job to make it fail or succeed. I searched wget curl but they have lot of description. I don't...
937
Posted By looney
Replace multiple file by passing parameter value
Hello All,
I want to change date part in file name to yesterday date in the file name.

example file name file-12122017-06-30-41.dat want file-12112017-06-30-41.dat I am doing like below. Below it...
3,659
Posted By looney
@Aia Thanks for looking into it. As i said there...
@Aia Thanks for looking into it. As i said there is no logic , i have randomly selected different columns of different files. I know the code i wrote was not correct that is the reason i mentioned...
3,659
Posted By looney
Appending different columns of multiple files in awk
Hello All,
I have three input files
cat file1
col1|col2|col3
a|1|A
b|2|B

cat file2
col1|col2|col3
c|3|C

cat file3
col1|col2|col3
d|4|D
e|5|E


i want below output
file4 col1|col2...
1,600
Posted By looney
Network connectivity Pre checks
Hello All,
We are running multiple codes in prod all having different sources of databases in other servers. Many times due to network issue connectivity and DB issue the jobs got failed and to...
3,388
Posted By looney
hi , I have replaced while with for loop in mail...
hi , I have replaced while with for loop in mail program , and now it is working fine. I don't know what is going on internally. Please suggest if for loop is correct at this place._prompt () {...
3,388
Posted By looney
Hello Ravinder , none of those working , if i use...
Hello Ravinder , none of those working , if i use exit whole script is exiting and if i use continue or break it is going in infinite.

_prompt () {
while true
do
echo "$1"
read var
[[ "$var"...
3,388
Posted By looney
Read function is going in infinite in another script having while loop
Hello Experts,

I have created one user confirmation process that will ask for user input. I have created one func for it. The issue is if i call it as normal then it works fine but if i am calling...
6,074
Posted By looney
Modified vgresh99 script awk -F';' ' /^;/...
Modified vgresh99 script

awk -F';' ' /^;/ {next } FNR>1 { $2=($2) ? "Disabled":"Enabled"}1' OFS=';' file
6,074
Posted By looney
bashwhile IFS=";" read f1 f2 do [[ $f2 ==...
bashwhile IFS=";" read f1 f2
do
[[ $f2 == "S" ]] && echo "$f1;Disabled" || { echo "$f1;Enabled" ;}
done < file
4,393
Posted By looney
Hi Shaky, Please try orig=Original ...
Hi Shaky, Please try
orig=Original
orig_ext=*.mpeg
opti=Optimized
opti_ext=*.mp4

for i in $orig/$orig_ext
do
original_file=`basename ${i%.mpeg}`
for l in $opti/$opti_ext
do...
11,072
Posted By looney
Thanks Mr Don, this seems very valid approach to...
Thanks Mr Don, this seems very valid approach to wait for completion of transfer of main file by watching it's checksum file that will arrive at end. But just for a knowledge how third party will...
11,072
Posted By looney
Thanks stomp Hello Mr. Don, the third party is...
Thanks stomp
Hello Mr. Don, the third party is sending us a zip file , presently they are not sending checksum but it is a good idea to ask them also to send checksum. But i don't understand by your...
11,072
Posted By looney
How to check if downloading of a file is completed?
Hello All.
We are getting one zip file from another server daily. The size of the zip file will be around 4.5 gb that takes time to download completely. I have to process that file furthest once get...
1,165
Posted By looney
Thanks MIG, I have applied your function and it...
Thanks MIG, I have applied your function and it is working fine. Could you please explain it. Also what if i simply use below code if ls 20170108/file* ; then
echo "file is present"
else
"file is...
1,165
Posted By looney
Hello RudiC, In the directory I will get...
Hello RudiC,
In the directory I will get filename say files-20170105-09.gz. I have to check if file exists also if exists then it should have today's date minus one. So I have to search this part...
1,165
Posted By looney
Match filename pattern with -f
Hello All,
I have two issues.
1).I want to check if directory exists and inside that if file exists with today's date minus one. I can check directory exists but how can i check only a pattern of...
1,705
Posted By looney
Hello RudiC, could you please explain below...
Hello RudiC, could you please explain below highlighted part of code.sed:

sed 's/#growncars#/\n/g; s/^[^\n]*\n\|\n[^\n]*$//g' file.
1,008
Posted By looney
sedsed -E ...
sedsed -E 's/(\w+):([0-9]+)-([0-9]+)\|(.*)/\1\t\2\t\3\t\1:\2-\3\t.\t\4/' file
1,425
Posted By looney
awkawk -FS=" |;|=" '$2 < 0.4' file grepgrep...
awkawk -FS=" |;|=" '$2 < 0.4' file
grepgrep "AF=0.[0-3]" file
1,633
Posted By looney
Hi Aia , could you please explain below...
Hi Aia , could you please explain below highlighted part of code.perl -ne 'print if (()=/MODE/g) == 1' migurus.file
17,840
Posted By looney
Hi Ronaldxs , Could you please explain below...
Hi Ronaldxs , Could you please explain below code.
perl -Mstrict -MList::Util=sum -wanE 'say sum(@F)'
3,687
Posted By looney
grepgrep -o '.*\.[0-9]\{3\}' file
grepgrep -o '.*\.[0-9]\{3\}' file
910
Posted By looney
Hi cmccabe, where function pa is being used.?
Hi cmccabe,
where function pa is being used.?
1,169
Posted By looney
Hi RudiC, Kindly explain below part of code. if...
Hi RudiC,
Kindly explain below part of code. if ($1+0) sub ($1 FS, _) I could understand that first we are checking if first field is number then substituting it and space with _. If it is so then...
Showing results 1 to 25 of 92

 
All times are GMT -4. The time now is 05:20 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy