New answers tagged

0 votes

Can't get sub_filter to work in nginx, could it be an ownership/permissions issue?

Turns out, I had zlib.output_compression = On in php.ini, which was interfering. It's not needed, since I have gzip on in nginx.
jamminjames's user avatar
0 votes

Shell script capturing values from output of command

If you only want to know if all the packets were lost (i.e. host is unreachable), some versions of ping return an exit code of 1 in such cases:
Phill  W.'s user avatar
  • 1,489
1 vote

Shell script capturing values from output of command

Something like in awk can do the work: packet_lost=$(ping -c4 8.8.8.8|awk '/packet loss/ {print $6}')
Romeo Ninov's user avatar
  • 5,543
1 vote

Shell script capturing values from output of command

You can use grep and awk to capture the packet loss from the output of the ping command. Here's an example: ping_result=$(ping -c4 8.8.8.8) packet_loss=$(echo "$ping_result" | grep -oP '\d+% ...
OscarG's user avatar
  • 26
0 votes
Accepted

not able to send mails from linux ubuntu : 20.04 by using email mailutils (sendmail or mail keyword)

You need to configure the sasl_password parameter: smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd smtp_sasl_security_options = noanonymous smtp_tls_security_level ...
OscarG's user avatar
  • 26
1 vote

PowerShell prompt to continue execution of code

I completely agree with the currently accepted answer. Using Read-Host is a great way to add that user-friendly touch, giving users the option to proceed or halt the process. But if someone's looking ...
acast's user avatar
  • 21

Top 50 recent answers are included