Redirecting STDERR to a file from within a bash script

I am trying to redirect the output from stderr to a log file from within a bash script. the script is to long to add

2> $logfile

to the end of each command. I have been trying to do it with the command

exec 2> $logfile

This mostly works. Unfortunately, when a read command requires that anything be typed in, the input is hidden and printed in the log file. Is there any way to fix this? Thanks in advance for any help.

Instead of adding "2> $logfile" to each line scope the output of the script by adding parens.

(
  script contents...
) 2> $logfile

Thanks. That's exactly what I was looking for.

Edit: Sorry, not quite.

I just realized something that I didn't notice before. When I removed the "-e" option from the read command, both my previous solution and the suggested solution above worked fine. It look likes "read -e" outputs everything through stderr. Is that correct? Without the "-e" option, the backspace key doesn't work in the read statement. Is there something I am missing or is "read -e" the only way to allow the user to use a simple editor to input information to the script.

Scope the output before and after each read command. Take note the second and any additional outputs need to append to your output file, by using '>>'.

(
ls anyfile
) 2>./output
read -p input:
(
echo reply=$REPLY
) 2>>./output

Thanks. That works great.