[X4U] How to determine which network component is failing

Stroller macmonster at myrealbox.com
Sun Jul 23 20:13:44 PDT 2006


On 23 Jul 2006, at 14:39, Charles Howse wrote:
> ...
> Sure do hope someone comes up with a way to release/renew via a  
> shell script, that might solve my issues.

Sorry, I meant to reply earlier.

This is certainly quite possible - I just don't know the best way to  
do it.

For instance, Mac OS X has the `curl` utility installed, and this can  
be used both at the command line & in shell-scripts to grab webpages.  
I use it regularly in the context of `curl -O http://somesite.com/ 
file/which/is/downloading/annoyingly/slowly/and/stalling/safari.mov`  
and in a daily cronjob for downloading the Dilbert cartoon & emailing  
it to myself. See <http://groups.google.com/group/linux.gentoo.user/ 
msg/be8beb3c63ddcdee?dmode=sourcee> for sample code.

I'm not sure how elegantly `curl` could be used to call the reboot  
function of the router, because I think that might be a CGI function.  
I'm not sure what exactly that is, but I've seen it in the source of  
routers' webpages before, and actually I was looking at that of the  
DG834GT today and the reboot button of that seems to make some kind  
of cgi calls. I think it's a way of activating buttons in a webpage?  
I'm not sure how easy it is to create a URL to a button activation,  
you see?

If you were to post the source for the particular part of the  
router's webpage to x-unix at listserver.themacintoshguy.com then  
someone there might be able to help with this scripting. I think it's  
the sort of thing that might lend itself to perl or python - I  
believe both these languages have comprehensive http libraries, but  
I'm afraid I'm experienced in neither.

Stroller.







More information about the X4U mailing list