Re: Executing a Script every hour

2003-10-01 Thread David J. Weller-Fahy
* Christof Hurschler [EMAIL PROTECTED] [2003-09-30 22:17]:
 Tha sounds like a very logical thing to do, as you can tell I'm a
 newbie.  Do you mean running the script from ip-up??

Assuming the script ip-up runs *after* the DSL connection is
established, then yes.  When it comes to dial-up/ppp connections I'm
probably newer than you are, as I've never used them in Linux.  However,
the theory is sound. ;]

 Maybe somone can tell me how to tell pppd to connect, i.e. without for
 instance running ping?

How do you connect currently?  Does your system connect whenever you try
to access a resource that's on the internet?

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: Executing a Script every hour

2003-10-01 Thread David J. Weller-Fahy
* Christof Hurschler [EMAIL PROTECTED] [2003-10-01 04:41]:
 I set the ppp option demand which like you said connects when I try
 to access the network.  It terminates the connection after 60 seconds
 of no traffic.  It takes maybe 20 seconds to connect (I haven't
 actually timed it), which isn't exactly instantaneous, but much faster
 than my old modem!

That's no kidding.  I haven't used dial-up for years, and was very glad
to get away from that!  BTW - have you checked the man page/help files
for pppd for examples on how to manually have pppd call out?  The docs
should be located in '/usr/share/doc/ppp'.

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: Executing a Script every hour

2003-09-30 Thread David J. Weller-Fahy
* Christof Hurschler [EMAIL PROTECTED] [2003-09-30 12:35]:
 Is there a simpe way to have a script execute at shorter time
 intervals. I'd like to run the swendeleter.pl script automatically
 every so often to keep my mailbox from overfiling.

I think you looked in the wrong place (took me a while, as well), from
'man 5 crontab':

#v+
Commands  are  executed  by  cron(8)  when the minute, hour, and
month of year fields match the current time, and when at least one
of the two day fields (day of month, or day of week) match the
current  time  (see  ``Note''  below).   cron(8) examines cron
entries once every minute.  The time and date fields are:

field   allowed values
-   --
minute  0-59
hour0-23
day of month1-31
month   1-12 (or names, see below)
day of week 0-7 (0 or 7 is Sun, or use names)
#v-

Hope that helps...

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: Executing a Script every hour

2003-09-30 Thread David J. Weller-Fahy
* Christof Hurschler [EMAIL PROTECTED] [2003-09-30 15:04]:
 $pop = Net::POP3-new('pop3host', Timeout = 60);

Perl, eh?  Never played around with that language, sorry.

 but I haven't been able to get it to work in swendelete, I always get
 a can't connect to mail server error when I run swendelete.pl and
 don't have an active connection (I'm usind demand in ppp).

 Any suggestions?

Although I have no experience with the language, you may want to try
approaching the problem from the other end.  If you can't get the
'Net::POP3' module to wait until the ppp daemon finishes connecting,
have the ppp daemon run your script as soon as it finishes connecting.

Then, instead of running your script every hour, have the daemon connect
every hour, then disconnect after a suitable period.

Just a thought...

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: Uppercasing filenames

2003-09-20 Thread David J. Weller-Fahy
* Jeff Elkins [EMAIL PROTECTED] [2003-09-20 13:07]:
 I need to convert a bunch of filenames to uppercase. I tried the
 script below, which does...nothing.

 #!/bin/sh
 for file in $*
  do
  if [ -f $file ]
  then
   ucfile=`echo $file | tr [a-z] [A-Z]`
   if [ $file != $ucfile ]
   then
   mv -i $file $ucfile
   fi
  fi
  done

 Any tips?

If I may, try the following:

#v+
#!/bin/sh
for file in *
do
ucfile=`echo $file | tr [:lower:] [:upper:]`
if [ -f $file ]  [ ! $ucfile -ef $file ]
then
cp $file $ucfile
fi
done
#v-

That's assuming that you want any files with all uppercase filenames to
be ignored.  The only syntactical error that I saw was the '$*' instead
of '*' on the first non-comment line.

HTH,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: problem with mutt and imap

2003-09-04 Thread David J. Weller-Fahy
* Dan Hunt [EMAIL PROTECTED] [2003-09-03 20:32]:
 * David J. Weller-Fahy [EMAIL PROTECTED] [2003-09-03 21:10]:
  * Dan Hunt [EMAIL PROTECTED] [2003-09-03 18:22]:
   * Grzesiek Sedek [EMAIL PROTECTED] [2003-09-03 18:43]:
I'm getting this weird error when trying to connect to imap server:
   
gnutls_handshake: A TLS packet with unexpected length was received
  
   Hey! I am having the same problem with a new installation, and a
   Red-Hat server. Right now I am running Sid and it used to work when I
   had Woody.
  
   What version of mutt are you using?
  
  I've just duplicated that by removing my IMAPd SSL certificate
  (imapd.pem with courier-imap) and attempting to connect to my imapd
  server.  Are you sure you've created a self-signed certificate?
  
  Oh, and I'm using mutt 1.5.4i on Debian testing.
  
  Regards,
  -- 
  dave [ please don't CC me ]
 

 I'm just having this problem with one mail server, as a user I am
 using IMAP to connect to my ISP provided mailbox with no problems. I
 just enter c to change and type in each time
 imap://username:[EMAIL PROTECTED]/

Gotcha.

 However Mutt 1.5.4i (2003-03-19) is not connecting to my work address.
 At this domain I am a user, who cannot connect using mutt, yet. Rather
 than using the provided IMP webmail, I set up Mozilla to use imap and
 it works well.

So, the problem is with one imap server that is not under your control,
correct?  What IMAP options are you using in your .muttrc?

I'm assuming (from the context) that they're running a non-ssl secured
IMAP server and are advertising STARTTLS, right?  If so, you may want to
try putting the following in your .muttrc:

#v+
set ssl_starttls=no
#v-

And try to connect.  Just a WAG, but it might help.

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: problem with mutt and imap

2003-09-04 Thread David J. Weller-Fahy
* Dan Hunt [EMAIL PROTECTED] [2003-09-04 11:22]:
  set ssl_starttls=no
 
  And try to connect.  Just a WAG, but it might help.
 
 Great guess, fixed that right up.

Excellent!  Glad I could help.

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: problem with mutt and imap

2003-09-03 Thread David J. Weller-Fahy
* Dan Hunt [EMAIL PROTECTED] [2003-09-03 18:22]:
 * Grzesiek Sedek [EMAIL PROTECTED] [2003-09-03 18:43]:
  I'm getting this weird error when trying to connect to imap server:
 
  gnutls_handshake: A TLS packet with unexpected length was received

 Hey! I am having the same problem with a new installation, and a
 Red-Hat server. Right now I am running Sid and it used to work when I
 had Woody.

 What version of mutt are you using?

I've just duplicated that by removing my IMAPd SSL certificate
(imapd.pem with courier-imap) and attempting to connect to my imapd
server.  Are you sure you've created a self-signed certificate?

Oh, and I'm using mutt 1.5.4i on Debian testing.

Regards,
-- 
dave [ please don't CC me ]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]