Perl regexp to extract first and second column

Hi,

I am trying with the below Perl one-liner using regular expression to extract the first and second column of a text file:

perl -p -e "s/\s*(\w+).*/$1/"
perl -p -e "s/\s*.+\s(.+)\s*/$1\n/"

whereas the text file's data looks like:

Error: terminated 2233
Warning: reboot 3434
Warning: filledup 4322

I am not getting the expected output, but blank. Kindly correct me in the code where I am doing wrong.

 
bash-3.00$ perl -p -e 's/(.*):\s(.*)\s\w+/$1 $2/' a
Error terminated
Warning reboot
Warning filledup

Try:

perl -lane 'print $F[0],$F[1]' inputfile

Example using awk

awk -F":| " '{print $1,$3}' file