1

I am trying to grab an image from my weathercam using wget and cron. For now I just need to see how to get an image downloaded and timestamp the filename.

http://xx.xx.xx.145:8888/snapshot.cgi?user=wxcam&pwd=getsomewx

I tried various versions of wget and curl and receive unauthorized but it work fine in the browser. I will change my ip in a few hours or when the question gets answered. ;)

1
  • can you tell us how you invoked wget/curl and what is the exact error you are getting ?
    – amisax
    Commented Jun 30, 2015 at 4:32

1 Answer 1

2

Not sure what is actually wrong on your side without the actual wget/curl command, but this

wget "http://xx.xx.xx.145:8888/snapshot.cgi?user=wxcam&pwd=getsomewx" --output-document cam_$(date +%Y%m%dT%H%M%S).jpeg

worked. I did this both from a computer where I previously had used the browser to access the cam and from a system where I did not do so (in case the cam caches some information based on the browser authentication).

The shell handles an unquoted question mark so, you have to quote the URL. Without that, I get Authorization failed as well.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .