LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-11-2006, 06:55 PM   #1
joebu23
LQ Newbie
 
Registered: Dec 2005
Distribution: Ubuntu 6.06 LTS
Posts: 4

Rep: Reputation: 0
Bash script help


Hello, fairly new to linux and I have an issue that I am hoping someone can help me with. I want to write a bash script that will look up the info of my dsl router (via http) automatically every 24 hours or so and email me the page so that I can tell when my ip address changes when I am not at home.
 
Old 05-11-2006, 07:54 PM   #2
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
You might be able to use curl or wget to retrieve the status page from the router and extract the IP lease information from the page using sed. The hardest part may be getting the HTTPS (SSL/TLS) Options to authenticate with the router properly.

Last edited by jschiwal; 05-11-2006 at 08:05 PM.
 
Old 05-11-2006, 08:03 PM   #3
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,545

Rep: Reputation: 57
Here is something to start with, if you have trouble with the regex in sed/awk/grep post back what you tried and where it went wrong and we'll help.
Code:
lynx -dump http://192.168.0.254 | sed/awk/grep
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Bash script - executing a script through subdirectories bubkus_jones Programming 5 04-24-2006 05:05 PM
Need bash script bagoong_199 Programming 4 01-02-2005 08:58 AM
send automatic input to a script called by another script in bash programming jorgecab Programming 2 04-01-2004 12:20 AM
bash script - incrementing a filename in a script tslinux Programming 10 08-05-2003 11:58 PM
bash script prob: how can i tell the script that a 'dd' has finished? Frustin Linux - General 2 04-02-2003 05:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration