I\'m having a little trouble figuring out how to get error output and store it in a variable or file in ksh. So in my script I have cp -p source.file destination
cp -p source.file destination
You can do STDERR redirects by doing:
command 2> /path/to/file.txt