wget ip update is giving ...
wget ip update is giving "can't open update?... : File exists"
- 主页
- 后台控制中心
- Community Forum
- Services
- Dynamic DNS Service
- wget ip update is giving "can't open update?... : File exists"
- Community Forum
- wget ip update is giving "can't open update?... : File exists"
Topic: wget ip update is giving "can't open update?... : File exists"
I'm using ddns to my home server and I want to update my ip using wget on my crontab.
For that I have a command on my crontab that is of the form:
*/5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error:
"wget: can't open 'update?username=alexandre1985&password=pass': File exists".
1) Why does this happen?
2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one?
Thank you
Daniel Santos
For that I have a command on my crontab that is of the form:
*/5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error:
"wget: can't open 'update?username=alexandre1985&password=pass': File exists".
1) Why does this happen?
2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one?
Thank you
Daniel Santos
Reply with quote |Report
[quote=Daniel Santos]I'm using ddns to my home server and I want to update my ip using wget on my crontab.
For that I have a command on my crontab that is of the form:
*/5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error:
"wget: can't open 'update?username=alexandre1985&password=pass': File exists".
1) Why does this happen?
2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one?
Thank you
Daniel Santos[/quote]Could you try using the -N parameter because that would allow it to overwrite the file which was downloaded the first time. Alternately, you could use the -nc parameter which would perform the HTTP request but not really download any existing file.
For that I have a command on my crontab that is of the form:
*/5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error:
"wget: can't open 'update?username=alexandre1985&password=pass': File exists".
1) Why does this happen?
2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one?
Thank you
Daniel Santos[/quote]Could you try using the -N parameter because that would allow it to overwrite the file which was downloaded the first time. Alternately, you could use the -nc parameter which would perform the HTTP request but not really download any existing file.
Reply with quote |Report
| Author | Topic: wget ip update is giving "can't open update?... : File exists" |
|---|---|
|
Daniel Santos Joined: 2016/12/19 |
2017年4月23日星期日 上午4:09
I'm using ddns to my home server and I want to update my ip using wget on my crontab.
For that I have a command on my crontab that is of the form: */5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error: "wget: can't open 'update?username=alexandre1985&password=pass': File exists". 1) Why does this happen? 2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one? Thank you Daniel Santos |
|
rahsharma Joined: 2010/11/25 |
2017年4月23日星期日 下午7:48
[quote=Daniel Santos]I'm using ddns to my home server and I want to update my ip using wget on my crontab.
For that I have a command on my crontab that is of the form: */5 * * * * sleep 15; wget "http://api.dynu.com/nic/update?username=USERNAME&password=MD5PASSWORD" . But I have notice that when I run the wget command the second time I get the a error: "wget: can't open 'update?username=alexandre1985&password=pass': File exists". 1) Why does this happen? 2) What is the proper way of doing a wget from cron so it doesn't appear any error like this one? Thank you Daniel Santos[/quote]Could you try using the -N parameter because that would allow it to overwrite the file which was downloaded the first time. Alternately, you could use the -nc parameter which would perform the HTTP request but not really download any existing file. |
2026年6月19日星期五 上午8:53
