Yahoo Mail Forwarder

Forward Yahoo Mail to another Account

By James Toebes


Since it will be virtual, isolated, single purpose machine,  Security is minimal.

Start by building a virtual machine

  1. New Machine
  2. Name: MailForwarder
    Type: Linux
    Version: Fedora 32
  3. Use default of 768. If tight on memory for your Host server, use smaller.
  4. Create a virtual hard drive now
  5. VDI
  6. Dynamically Allocated
  7. Default of 8 GB.   If you have a very large mailbox,  increase it.
  8. tart the Virtual machine,  it should ask for Disk,   browse to and select the ISO file for Fedora LXDE.
  9. Start the machine.
  10. When it boots to desktop,  select install to hard drive.
  11. Select English, Continue (Unless you prefer another language, Klingonese?)
  12. Select Hard Drive, then done.
  13. Switch LVM to Standard Partition.  It is a vm.....
  14. Continue.  It will take the main menu a few seconds before  you can continue.
  15. Begin installation.
  16. While installing,  Go ahead and set the root password.  Don't bother with account creation.
  17. When done shutdown.
  18. From VirtualBox Manager, after shutdown,  select settings.
  19. Under Storage,  select the DVD Drive, then click the disk icon, remove disk from drive.
  20. After Applying settings,  start the Virtual Machine.

Start Machine, Add Needed Components

  1. Click Create a User Account.
  2. Name:MailForwarder
    Check: Make this user an Administrator
    Uncheck: Require a password to use this account.
  3. After completing the user configuration, click Finish Installation
  4. Click the MailForwarder user then Enter for the password.
  5. You wont be logging in often, so disable history saving.
  6. Start a terminal  (3rd icon on left at botton).
  7. sudo yum -y update
  8. sudo yum -y install thunderbird
  9. sudo cp /etc/lxdm/lxdm.conf /etc/lxdm/lxdm.conf.orig
  10. sudo vi /etc/lxdm/lxdm.conf, edit or add the line autologin=mailforwarder
  11. cp /usr/share/applications/mozilla-thunderbird.desktop ~/.config/autostart/thunderbird.desktop
  12. Edit the file ~/.config/autostart/thunderbird.desktop.  Remove  %u from end of exec line.
    I.e.  vi ~/.config/autostart/thunderbird.desktop
           cursor down and over to the space in front of %u
           press x 3 times to delete the space and %u
           type :x to exit and save

Configure Mail Account and Forwarder

  1. Application menu => Internet => Thunderbird
  2. Add your Yahoo Account (Skip and use mu existing).  Fill in your yahoo email address and password.
  3. Use IMAP and NOT SMTP for account type.
  4. When done adding,  use Alt-F => New => Existing email account.
  5. Add your second (Destination) account.   Use IMAP for account type.
  6. If you want the mail in another folder other than Inbox, create that folder under the Inbox folder in the second email account.
  7. Press Alt-T then Filters to pull up the filter list.
  8. Ensure Yahoo Mail account is selected then Click New.
  9. Name: MailForward
    Match All Messages
    Click Move to Folder.  Select DestinationAccount => Inbox => Select this folder.
    If you created a folder in step 6, select that folder for moving.
    Click OK, then Run Now.
  10. The first run may take some time as it moves the email.

Configure Auto Maintenance

  1. Launch a terminal
  2. sudo crontab -e
  3. add (i to insert)
    # * * * * * command to be executed
    # - - - - -
    # | | | | |
    # | | | | +----- day of week (0 - 6) (Sunday=0)
    # | | | +------- month (1 - 12)
    # | | +--------- day of month (1 - 31)
    # | +----------- hour (0 - 23)
    # +------------- min (0 - 59)
    #autoupdate on sunday.   Reboot at 1 am.
    0 0 * * 0 yum -y update
    0 1 * * 0 reboot
  4. save and exit.  esc to exit insert mode :x to save and exit
  5. Reboot to verify login and autostart works.
  6. Shut down when done.

Move to virtual server

  1. From VirtualBox Manager.  Select File => Export Appliance.
  2. Highlight the VM then click Next
  3. Select OVF version 2.  Note the file name and location (change if you want) then Next.
  4. Fill in any information you like then Export.
  5. When export is completed, copy file to the virtual server host.
  6. Log into PHP Virtual Box on the virtual server.
  7. Select File => Import Appliance
  8. Use the Folder Icon,  Browses and select the file you uploaded.  Select Next
  9. Review the import settings. Select Import.
  10. Wait a few minutes for the import to complete.
  11. Start The Virtual Machine

That's all. Your mail will now appear in your Destination account.  You should not have to touch the VM again except for an occasional health check.   Your a Good SysAdmin Right?  Now Enjoy!