I’m using Wget to make http requests to a fresh web server. I am doing this to warm the MySQL cache. I do not want to save the files after they are served.
wget -nv -do-not-save-file $url
Can I do something like -do-not-save-file with wget?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Use
qflag for quiet mode, and tellwgetto output to stdout withO-(uppercase o) and redirect to/dev/nullto discard the output:wget -qO- $url &> /dev/null>redirects application output (to a file). if>is preceded by ampersand, shell redirects all outputs (error and normal) to the file right of>. If you don’t specify ampersand, then only normal output is redirected.if file is
/dev/nullthen all is discarded.This works as well, and simpler: