Re: Booting a PPP session

Edward S. Marshall (emarshal@common.net)
Sat, 14 Dec 1996 14:29:57 -0600 (CST)

On Sat, 14 Dec 1996, Administrator wrote:
> 1st off, Thanks Jason and Edward. I grabbed pmwho & pmcom and I am _really_
> close now. I think it is simply a matter of syntax now.

[...]

> # ./pmcom -c pm1 'reset `./pmwho |grep "luser"|cut -b0-2`'
> Error: Usage: reset Port_Name|all|console

Hmmm...my guess is that your shell is not liking the pipes mixed up in
there...try this:

#!/bin/sh
PMCOM=/path/to/pmcom
PMWHO=/path/to/pmwho
USER="luser"

PORT="`$PMWHO | grep $USER | cut -b0-2`"
$PMCOM -c pm1 "reset $PORT"

Just give it the right paths to PMCOM and PMWHO, and fill in a correct
value for the user you want to reset, and everything _should_ work,
although I haven't tested it; there's probably a typo there somewhere.

Hope this helps!

--
.-----------------------------------------------------------------------------.
| Edward S. Marshall <emarshal@common.net> | CII Technical Administrator,     |
| http://www.common.net/~emarshal/         | Vice-President, Common Internet  |
| Finger for PGP public key.               | Inc, and Linux & LPmud (ab)user. |
`-----------------------------------------------------------------------------'