LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 10-04-2006, 12:45 AM   #1
Ipolit
Member
 
Registered: Nov 2003
Location: Bulgaria
Distribution: Vector Linux, Morphix
Posts: 321

Rep: Reputation: 33
crontab problem with pon on knoppix 5


Hello,
I have a VPN network and I made a script to check if ppp interfaces are brought on.

Code:
#!/bin/bash
X=`/sbin/ifconfig | grep ppp`
if [ -n "$X" ]; then    # -n tests to see if the argument is non empty
        echo ""
else
        pon sofia 
fi
When I execute the script manualy it works perfect, but I want it to make this check every 5 minutes, so I put it in crontab. Unfortunatelly it dowsn't work.

Code:
Oct  4 05:50:01 levski pppd[5382]: pppd 2.4.4b1 started by root, uid 0
Oct  4 05:50:01 levski pppd[5382]: Couldn't get channel number: Input/output error
Oct  4 05:50:01 levski last message repeated 4 times
Oct  4 05:50:01 levski pppd[5382]: Using interface ppp0
Oct  4 05:50:01 levski pppd[5382]: Connect: ppp0 <--> /dev/pts/1
Oct  4 05:50:01 levski pppd[5382]: Modem hangup
Oct  4 05:50:01 levski pppd[5382]: Connection terminated.
Oct  4 05:50:01 levski pppd[5382]: Couldn't get channel number: Input/output error
Oct  4 05:50:01 levski last message repeated 3 times
Oct  4 05:50:01 levski pppd[5382]: Exit.
Also I tried just to run pon from crontab without the script - same result.
Please, suggest

Best regards
Ipolit
 
Old 10-04-2006, 05:13 AM   #2
Ipolit
Member
 
Registered: Nov 2003
Location: Bulgaria
Distribution: Vector Linux, Morphix
Posts: 321

Original Poster
Rep: Reputation: 33
Fixed

crontab -e doesn't work properly

I added the entry directly in /etc/crontab restarted cron and everything is fine
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
'pon' and 'poff' not working with mandrivalinux Rodolfo Medina Mandriva 10 10-12-2005 01:40 AM
Disappearing pon window alb1954 Feather 8 02-02-2005 02:56 PM
pppd question about pon and poff Sammy2ooo Linux - Networking 0 12-29-2004 05:56 PM
modem volume using pon jeff1500 Linux - Hardware 0 08-13-2004 06:38 AM
using pon and poff for regular users lobo78 Linux - Networking 1 02-27-2004 12:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:14 PM.

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