fixed invalid redirects truncating logfile, fixed script to use /etc/rc....

...d/rc.local instead of /etc/init.d/rc.local, added HOME env var definition to  setup_packages to fix erlang bug when installing from rc.local. Removed depricated commented out trap code in setup_common.