Search Results

Search: Posts Made By: MDominok
3,046
Posted By MDominok
Solved
Hi Folks

Thanks all for the quick replies and sorry for my late response. Healthwise 2018 isn't my year exactly....

Decided to follow RudiC (https://www.unix.com/members/302122047.html)s...
3,046
Posted By MDominok
Lost redirecting stderr & stdout to 3 files - one each plus combined
Hi folks

I need/want to redirect output (stdout, stderr) from an exec call to separate files. One for stderr only and two(!) different (!) ones for the combined output of stderr and stdout.
...
2,549
Posted By MDominok
Yours is neater than mine and should work for me...
Yours is neater than mine and should work for me as well.



Neither a comma nor a tick.

$ grep \' test.dat
ok: [20.6.1.1] => {"msg": "[u'/project/cars/version/scripts/',...
2,549
Posted By MDominok
Gives me, on bash : $ awk -F\' '{print $2}'...
Gives me, on bash :
$ awk -F\' '{print $2}' RS=, test.dat
GATHERING FACTS *****************************
/project/cars/version/scripts/y.txt
/project/cars/version/scripts/x.txt
2,549
Posted By MDominok
Done with bash. grep "'" test.dat | cut -d...
Done with bash.

grep "'" test.dat | cut -d \' -f2
grep "'" test.dat | cut -d \' -f4
grep "'" test.dat | cut -d \' -f6

You could also do
grep "'" test.dat | cut -s -d \' -f2,4,6

in a...
6,517
Posted By MDominok
You can select the chars with cut byte- or...
You can select the chars with cut byte- or character-wise:

From manpage:

-c list The list following -c specifies character
positions (for instance, -c1-72...
6,517
Posted By MDominok
#!/bin/bash a="aa bb cc dd ee" b="11 22 33...
#!/bin/bash

a="aa bb cc dd ee"
b="11 22 33 44 55"
c="AA BB CC DD EE"

for segment in 1 2 3 4 5; do
echo $a | cut -d' ' -f${segment} | tr -d "\n"
echo " " | tr -d "\n"
echo $b | cut...
2,504
Posted By MDominok
Which shell are you using? sh, csh, bash?
Which shell are you using? sh, csh, bash?
5,133
Posted By MDominok
Right after the send "cd dir\r" You...
Right after the
send "cd dir\r"

You probably have to adjust the "550 .." and "250 CWD..." to your servers response as well.

This works like case/switch. You could add even more "cases".
5,133
Posted By MDominok
expect { "550 dir: No such file or directory"...
expect {
"550 dir: No such file or directory" {send "quit\n" ; exit }
"250 CWD command successful" {exp_continue}
}
1,822
Posted By MDominok
Yep, that was it. Added some more debug...
Yep, that was it.

Added some more debug lines to the script and noticed that the process (S)leeps from time to time. Which is perfectly normal for unix.

So, puh, the world still _is_ a sphere...
1,822
Posted By MDominok
Stateless process
Hi Folks

I'm trying to monitor that a process is running, using ps.

Astonishingly the process, which is checked every 15 minutes, is runnnig but without a state about 2-3 times a day.
...
Showing results 1 to 12 of 12

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