greping ip address

I have this line

BTSRTRGRP-448-1-1 10.162.141.118/255.255.255.254 -

I need to print only the IPADDRESS and not the subnet mask. If i use cut -c30-43 I get the ipaddress, where as in some cases if the last octet is of single digit (10.162.141.8/255.255.255.254) it prints "10.162.141.8/2"

Basically I want to omit /255.255.*.*

cut -c30- | cut -d/ -f1

or with a regex

sed 's%.* \([0-9.]*\)/.*%\1/p'

If you already have this information in a variable INPUT, it's more efficient to use a variable substitution.

temp=${INPUT#* }
IPADDRESS=${temp%/*}

perfect ERA....

cut -c30- | cut -d/ -f1 works good.... thanks a lot......