Search Results

Search: Posts Made By: robertkwild
Forum: Programming 11-15-2017
3,366
Posted By jim mcnamara
should be with the echo statement before su: if...
should be with the echo statement before su:
if [ id -u root -ne 0 ]; then

echo "type in the root password"
su # or sudo
fi
Forum: Programming 09-28-2017
3,748
Posted By rbatte1
Does the suggestion do what you want? ...
Does the suggestion do what you want?

Another might be to use xargs similar to this:-find . -type f | xargs -tn1 md5sum > /md5sums/file.txt

The flags are:-
-t - write the arguments to STDERR...
Forum: Programming 07-20-2017
13,303
Posted By apmcd47
You are expecting the form elements user and...
You are expecting the form elements user and passwd to be converted to shell variables and exported to your scripts environment before calling it. It doesn't happen that way (unless there is an...
Forum: Programming 05-31-2017
1,336
Posted By jim mcnamara
$tar evaluates to a file name, which is not...
$tar

evaluates to a file name, which is not a valid script or command.
try:
tar -tvf "$base" >> /mnt/local/data/logs/"$base".csv
Forum: Programming 02-18-2017
1,399
Posted By Scrutinizer
Try something like: awk ' { s=$1 ...
Try something like:

awk '
{
s=$1
for(i=4; i<=6; i++) {
if (FNR==NR)
A[NR,i]=$i
else
s=s OFS A[FNR,i]-$i
}
}
NR>FNR && FNR>1 {
print s...
29,901
Posted By Don Cragun
Hi Robert, You didn't pay close enough...
Hi Robert,
You didn't pay close enough attention to what I suggested in post #40: I said it would be much better if you would create a hidden directory under /to_be_archived (such as...
29,901
Posted By drl
Hi. Did you edit the file in WIndows? ......
Hi.

Did you edit the file in WIndows? ... cheers, drl
1,535
Posted By Don Cragun
Please don't ask the same question in two...
Please don't ask the same question in two threads! It is almost impossible for people trying to help you to follow one discussion being held in two places!

As I said in post #40 in the thread...
29,901
Posted By bakunin
Yes. Whenever the tar-command returns a non-zero...
Yes. Whenever the tar-command returns a non-zero value the part between "then" and "fi" (or, in case an else-branch is there, the "then and the "else") is executed. In your case, since there is a...
Showing results 1 to 9 of 9

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