What you are trying to accomplish here is to have one resource (either a page or an entire site) redirect a visitor to a completely different page or site, and while doing so tell the visitor's browser that the redirect is either permanent (301) or temporary (302).
attempts to give you a reasonably indepth overview of what the different aspects of a standard drupal installation you will need to address for SEO are