Kompx.com or Compmiscellanea.com

Imapsync IMAP migration under Windows

Operating systems : Windows

Migrating an IMAP e-mail box from one IMAP server to another under Windows [ 1 ] [ 2 ] by means of imapsync:

  • Copying an e-mail box with all its contents and keeping its folder structure;
  • The e-mail box is hosted at a web hosting company's server and transfered to a common Yandex Mail (not Yandex Mail for Domain);
  • Both IMAP servers support SSL.
  • The process is done in three steps: test run, migrating folder structure, migrating e-mails.

Test run

Content of imapsync-test.bat:


.\imapsync.exe ^
	--host1 imap.domain.ru --user1 email1@domain.ru --password1 "password1" ^
	--host2 imap.yandex.ru --user2 email2@yandex.ru --password2 "password2" ^
	--ssl1 --ssl2 --sslargs1 SSL_verify_mode=0 --sslargs2 SSL_verify_mode=1 ^
	--skipheader "^(?!Message-Id)" ^
	--automap ^
	--regextrans2 "s/^INBOX\.(.+)/$1/" ^
	--addheader ^
	--justfolders ^
	--dry
@PAUSE

Note: the caret character ( ^ ) at the end of line means "this command continues on the next line". It allows to break long command with many options into several parts to put them in several lines for better readability.

This step is meant for testing if imapsync may be run at all, if it can connect to both e-mail boxes and can read the basic structure of the first one. Imapsync runs without actually doing anything, just printing what would have been done without the --dry option. Adding --justfolders is to make testing faster, as imapsync does its job only for folders then.

A log file with full details for each run is placed into the LOG_imapsync folder.

Migrating folder structure

Content of imapsync-folders.bat:


.\imapsync.exe ^
	--host1 imap.domain.ru --user1 email1@domain.ru --password1 "password1" ^
	--host2 imap.yandex.ru --user2 email2@yandex.ru --password2 "password2" ^
	--ssl1 --ssl2 --sslargs1 SSL_verify_mode=0 --sslargs2 SSL_verify_mode=1 ^
	--skipheader "^(?!Message-Id)" ^
	--automap ^
	--regextrans2 "s/^INBOX\.(.+)/$1/" ^
	--addheader ^
	--justfolders
@PAUSE

This step reproduces the folder structure of the e-mail box being migrated in the one it is being migrated to.

Migrating e-mails

Content of imapsync-emails.bat:


.\imapsync.exe ^
	--host1 imap.domain.ru --user1 email1@domain.ru --password1 "password1" ^
	--host2 imap.yandex.ru --user2 email2@yandex.ru --password2 "password2" ^
	--ssl1 --ssl2 --sslargs1 SSL_verify_mode=0 --sslargs2 SSL_verify_mode=1 ^
	--skipheader "^(?!Message-Id)" ^
	--automap ^
	--regextrans2 "s/^INBOX\.(.+)/$1/" ^
	--addheader
@PAUSE

Now e-mails are being copied. If the size of an e-mail with attachment(s) is larger than it is allowed (for Yandex Mail it is not more than 30 megabytes - source), then this particular message is not going to be migrated and there is to be an error mentioned in the log file.


[ 1 ]

Tested under Windows 7.

[ 2 ]

Imapsync IMAP migration under Linux: Imapsync. IMAP migration.


Aliosque subditos et thema

 

Windows console applications. File managers

 

FAR Manager : DOS Navigator : File Commander The concept and requirements to file manager had formed itself back in the DOS epoch. With the spread of operating systems with graphical user interface, other applications facilitating files handling emerged. But for many tasks and for many users orthodox file managers remain the most convenient option. There are file managers with graphical user interface here for a long time already, however console file managers still hold on not only their proper niche, but as well a part of the space belonging in theory to file managers with a GUI. Nowadays file managers can, all in all, the same and in general the same way, but text-based file managers are more responsive to user actions. Also, even if it is not topical enough now, console file managers require less system resources, than GUI file managers of comparable functionality. FAR Manager - / home page / Console file manager for Windows. Among the built-in functions: FTP, Windows network, extensible archive files support, print manager, text editor. Other plugins are available: SFTP/SCP, image viewer, hex editor, syntax highlighting and auto-completion for text editor, some others. FAR Manager 2.0: Console file manager FAR Manager 2.0: FTP, downloading files FAR Manager 2.0: A submenu FAR Manager 2.0: System settings FAR Manager 2.0: Text editor FAR Manager 2.0: MPlayer, playing .mp3 DOS Navigator - / open source project / Console file manager for Windows. A variation of the DOS file manager. There is also a version for OS/2. Archive files support, text editor with syntax highlighting, disk editor, spreadsheet, calculator, calendar, etc.

JavaScript rollover. Image swap

 

Example n.1 ( For modern web browsers: Internet Explorer 4.0+, Firefox 1.0+, Google Chrome, Opera 4.0+, Safari 3.1+, SeaMonkey 1.0+, [ 3 ] ): HTML / XHTML. Code: <a href="javascript-rollover-image-swap.htm" onmouseover="image_over();" onmouseout="image_out();"><img src="out.gif" class="image" id="imageout" width="728" height="67" alt="JavaScript rollover. Image swap" /></a> CSS. Code: .image {border: 0px;} JavaScript. Code: imageout=new Image(); imageout.src="out.gif"; imageover=new Image(); imageover.src="over.gif"; function image_out(){ document.images['imageout'].src='out.gif'; }; function image_over(){ document.images['imageout'].src='over.gif'; }; Swap image 1 ( out.gif ): Swap image 2 ( over.gif ): Example n.2 ( For older web browsers: Internet Explorer 4.0+, Netscape 3.04+, Opera 3.21+ ): HTML / XHTML. Code: <a href="javascript-rollover-image-swap.htm" onmouseover="image_over();" onmouseout="image_out();"><img src="out.gif" class="image" id="imageout" name="imageout" width="728" height="67" border="0" alt="JavaScript rollover. Image swap"></a> JavaScript.