Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Fingering autoturn
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Plusnet Community
- :
- Forum
- :
- Help with my Plusnet services
- :
- Broadband
- :
- Fingering autoturn
Fingering autoturn
16-10-2007 9:49 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
I had a recurring problem with dequeueing mail from the autoturn server.
Initially, I had a cron job which periodically issued:
"finger postmaster@autoturn.plus.net"
Now, most of the time, this worked absolutely fine. However, sometimes the command simply seems to hang indefinitely.
Every morning, I had to run a 'killall -9 finger' to get rid of the excess processes, which isn't very elegant.
So, I decided to expand my simplistic mail dequeueing command with a bash script to do the same, except it will now wait for a specified amount of time, then kill the finger process if it's still hanging around.
For anyone else having similar problems dequeueing mail using autoturn, here is the script. Feel free to use as you require.
Hope it's of some use to someone.
B.
Initially, I had a cron job which periodically issued:
"finger postmaster@autoturn.plus.net"
Now, most of the time, this worked absolutely fine. However, sometimes the command simply seems to hang indefinitely.
Every morning, I had to run a 'killall -9 finger' to get rid of the excess processes, which isn't very elegant.
So, I decided to expand my simplistic mail dequeueing command with a bash script to do the same, except it will now wait for a specified amount of time, then kill the finger process if it's still hanging around.
For anyone else having similar problems dequeueing mail using autoturn, here is the script. Feel free to use as you require.
#!/bin/bash
# Author: Barry Zubel
# You are free to use this script any way you wish.
TIMEOUT=60
FINGER=/usr/bin/finger
DEST=postmaster@autoturn.plus.net
# Run the finger command.
$FINGER $DEST &
# grab the PID of the finger command
pid=$!
# sleep for a specified amount of time
sleep $TIMEOUT
# kill the finger command, if it's still running. Redirect all output
# to /dev/null
kill -s SIGTERM $pid > /dev/null 2>&1
Hope it's of some use to someone.
B.
Message 1 of 2
(1,399 Views)
1 REPLY 1
Re: Fingering autoturn
16-10-2007 9:56 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
neat little script
Message 2 of 2
(307 Views)
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page