2014-12-21 ~ Ilmu Tanpa Sempadan

Open Source, Delay Tolerant Network, Internet of Things

The Most Popular Traffic Exchange - Your Free Traffic Exchange - 1:1 Exchange Ratio, FREE Advertising!

Share Your Web Link Here

Saturday, December 27, 2014

5.4.6 Process of Database Synchronization

5.4.6 Process of Database Synchronization

 The related email data that need to be synchronized located in offline server computer, online server computer and infomediary device. The database synchronization performed by comparing the email data reside in server computer and infomediary device. Database synchronization application on server computer will check if the email data path on the server computer and email data path on infomediary device availability. When infomediary device connected in the server computer local network, the networking path of the email data on infomediary device will be discovered by database synchronization application. Database synchronization application will start comparing the email data between server computer and infomediary device. If there is no change of email data between server computer and infomediary device, the synchronization process is finished. When there is new email data found, the database synchronization application will start retrieve the new email data from infomediary device and transfer new email data to the infomediary device. Figure 5.3 shows the flowchart of the database synchronization.

Process of database synchronization
Process of database synchronization

Figure 5.3: Process of database synchronization

5.4.5 Mail Client

5.4.5 Mail Client

         Roundcubemail version 0.7.2 served as Mail Client application for an offline mail client and an online mail client. Mail Client is a mail user agent (MUA). It is a web application used to access and manage the email. The application file extracted into respective location and the folder renamed into “pemail”. In this thesis work, the location is:


         Mail Client installation performed by entering the URL: http://localhost/pemail/installer into the web browser. The configuration for both offline mail client and online mail client should be the same for the database synchronization purpose where the product_name, syslog_id and the database name is pemail, the database server is localhost and the database username and password configured accordingly for administrator access. IMAP Settings for offline mail client configured where the IP address of the offline server computer which is was used as a default host address. This IP address is accessible only in LAN. IMAP common port which is 143 was set for default port with username domain is “” which is used for email address. SMTP settings for offline mail client configured where the IP address of the offline server computer also used for the SMTP Server address. SMTP common port is 25.  The current IMAP username and password was used for SMTP authentication. This option can be configured under SMTP settings.

         SMTP settings for online mail client configured where the domain name of the online server computer which is “” was used for the SMTP Server address. This domain is accessible through internet. SMTP common port is 25. The current IMAP username and password also used for SMTP authentication and configured under SMTP settings.

         When the configuration is completely configured, this mail client configuration is saved through “create config” button where it will create two configuration files which are “” and “”. This configuration files transferred into a mail client application folder such as: 


         The configuration can be tested through “Test config” button. The configuration is correct and working when everything was remark with “OK”. Then the “installer” folder can be removed from mail client application folder.

         The files “.htaccess” in temp, logs and config folder which located in mail client folder “C:\PEmailOffline\UniServer\www\pemail” need to be configured to enable access of this Mail Client. This can be done by commenting next two lines in “. htaccess” files as shown in Table 5.8 by adding “#”.

#Order allow,deny
#Deny from all

Table 5.8: Enable Mail Client External Access Script

         New user registration page only required on online mail server to avoid database synchronization conflict between offline mail system and online mail system. Configuration for online mail client is the same as for the offline mail client except that online mail client includes the “new user registration” page. Plugins “roundcube-0.7.2-bundle-v.1.0” required for enabling “new user registration” page. The plugins can be found at The required plugin files which are bundle register, taskbar and captcha plugins were transferred into email plugins folder which is located at “C:\PEmailOnline\UniServer\www\pemail\plugins”. New plugins were enabled in an active plugins configuration file at “C:\PEmailOnline\UniServer\www\pemail\config” by editing “/config/” file and append new plugin names into configuration directive as shown in Table 5.9.

// ----------------------------------
// ----------------------------------
// List of active plugins (in plugins/ directory)
$rcmail_config['plugins'] = array('taskbar','register','captcha');

Table 5.9: Enable New User Registration Page Script

Then, taskbar plugin “/plugins/taskbar/” file can be activated by renaming into “/plugins/taskbar/”, captcha plugin “/plugins/captcha/” file can be activated by renaming into “/plugins/captcha/” and register plugin “/plugins/register/” file can be activated by renaming into “/plugins/register/”. HMailServer SQL database driver name to be used in registering new users is “'hmail_sql_db_4402” and need to be set by editing file “/plugins/register/” as shown in Table 5.10.

/* driver */
$rcmail_config['register_driver'] = 'hmail_sql_db_4402';

Table 5.10: hMailServer SQL Database driver name setting

Default domain name and other domains are “” and set up as shown in Table 5.11.

$rcmail_config['webadddoms']['default'][] = "";

Table 5.11: Domain name setting

Thursday, December 25, 2014

Top MOOC websites to gain extra knowledges

There are countless websites out there that are geared to make you more brilliant for free. Here are top websites that makes you smarter.

1. Udemy


Udemy is the world's largest destination for online courses. You can discover a lot of online course on and start learning a new skill today. All of the courses offers a Statement of Accomplishment cerftificate. A great deal to add in your resume.

2. Coursera


Coursera is a not for-profit educational technology company founded by computer science professors Andrew Ng and Daphne Koller from Stanford University that offers massive open online courses.
Some of the courses offer a free Statement of Accomplishment certificate. Start your courses today and learn new skills.

3. edX


EdX is a not-for-profit joint venture between Harvard University and the Massachusetts Institute of Technology to offer online versions of their classes and those of other universities.

EdX offers interactive online classes and MOOCs (massive open online course) from the world’s best universities, colleges and organizations. Online courses from MITx, HarvardX, BerkeleyX, UTx and many other universities. Topics include biology, business, chemistry, computer science, economics, finance, electronics, engineering, pabulum and alimentation, history, humanities, law, literature, math, medicine, music, philosophy, physics, science, statistics and more.

EdX was engendered for students and institutions that seek to transform themselves through cutting-edge technologies, innovative pedagogy, and rigorous courses.

Through our institutional partners, the xConsortium, along with other leading ecumenical members, we present the best of higher inculcation online, offering opportunity to anyone who wants to achieve, thrive, and grow. You also can grab a free Statement of Accomplishment certificate upon completion of the courses.

4. Stanford Online

Stanford Online
Stanford Online

Stanford Online offers a variety of professional education opportunities in conjunction with many of the University’s schools and departments. We also offer an array of free online courses taught by Stanford faculty to lifelong learners worldwide.
A lot of the courses offered is self paced mode. It is great deal if you are busy person that cannot keep up with a deadline. You can complete it at any time. Yes, you also given a free Statement of Accomplishment certificate upon completion of the courses. Start learning today.

5. Canvas


Canvas Network offers open, online courses taught by educators everywhere. It provides a place and platform where teachers, students, and institutions worldwide can connect and chart their own course for personal growth, professional development, and academic inquiry. Canvas Network is developed and supported by Instructure, a technology company that partners with educators, institutions, and technologists to break down barriers to learning. They also given free Statement of Completion certificate upon completion of the courses.

6. MIT OpenCourseWare

MIT OpenCourseWare
MIT OpenCourseWare

MIT OpenCourseWare (MIT OCW) is an initiative of the Massachusetts Institute of Technology (MIT) to put all of the educational materials from its undergraduate- and graduate-level courses online, partly free and openly available to anyone, anywhere. MIT OpenCourseWare is a large-scale, web-based publication of MIT course materials.

It makes the materials utilized in the edification of virtually all of MIT’s subjects available on the Web, free of charge. With more than 2,200 courses available, OCW is distributing on the promise of open sharing of erudition.

“The idea is simple: to publish all of our course materials online and make them widely available to everyone.” – Dick K.P. Yue, Professor, MIT School of Engineering

Through OCW, educators amend courses and curricula, making their schools more efficacious; students find adscititious resources to avail them prosper; and independent learners enrich their lives and utilize the content to tackle some of our world’s most arduous challenges, including sustainable development, climate change, and cancer eradication.

This MOOCs did not offers any certificate of completion and you can start learning without the need of registration.

7. Code Academy

Code Academy
Code Acedemy

Codecademy is an inculcation company. But not one in the way you might cerebrate. They’re committed to building the best learning experience inside and out, making Codecademy the best place for our team to learn, edify, and engender the online learning experience of the future.

Edification is old. The current public school system in the US dates back to the 19th century and wasn’t designed to scale the way it has. Lots of companies are working to “disrupt” edification by transmuting the way things work in the classroom and by bringing the classroom online.

This MOOCs also did not give any certificate upon completion of the courses.

Tuesday, December 23, 2014

5.4.4 Mail Server

            Offline mail server and online mail server should use the same configuration. This is to enable mail data synchronization where both mail servers should share the same content and configuration for data synchronization purposes. HMailServer version 4.4.4 being used as mail server application. HMailServer installed to respective location as “Full installation” with Server and Administrative tool component included. A database server is an external database which is a new hMailServer database created on MySQL Server and running on Uniserver. The database server address is “localhost” and TCP Port is 3306. The database name for this offline email system is “pemail” and should be the same for both offline server computer and online server computer. HMailServer security password configured accordingly. The created database location is:

The domain name for this offline email system is which can be configured accordingly at hMailServer Administrator welcome pages. A public host name also configured as “” under Settings -> Protocols -> SMTP, Delivery of e-mail tab. SMTP relayer setting depends on ISP either port 25 is open or not. If port 25 is open, a free SMTP relayer can be used such as “ 25”. Since 03 November 2008, TM Streamyx was blocking outgoing port 25 [28]. TM had suggested using the configuration for SMTP relayer as “”.

The port can be tested by running the command: telnet 25 and the result should a success connection as in Figure 5.2. The offline mail server is not needed to use suggested SMTP relayer setting, but it is recommended to use the same configuration since whenever the offline mail server connected to the internet, the offline email system can communicate directly without the need of infomediary device.

Figure 5.2: TMnet SMTP relayer.

Monday, December 22, 2014

5.4.3 External IP Address

            The Uniform Server setup for online web server is the same as for offline server. The IP address used is The difference is that the online server is connected to the internet. The Internet Service Provider being used in this research is TM Streamyx Dynamic 1 MBps. This ISP provides an internet with dynamic IP address connection. The external IP address will change periodically depending on the ISP. This leads to an access problem to existing setup to act as a server. To solve that problem, DtDNS service is used. DtDNS is a complete provider of DNS hosting and DNS management services with a focus on dynamic DNS and dynamic IP address management. There is a free domain name provided and tracking software to automatically update IP address as it changes. This free service enables a dynamic IP address to host a service just as it had a static IP address. The DtDNS service hostname details for this offline email system configured where the hostname is pemail and domain is
Cron is used to integrate DtDNS with Uniform Server. Cron originated from a UNIX environment. It is a job scheduler allowing scripts to be run automatically at a certain time or date. Cron has been integrated into Uniform Server 7.1.4. The script has been pre-configured to run the three scripts which are Drupal Cron, Moodle Cron and DtDNS automatic IP updater. Only script for DtDNS automatic IP updater used for this offline email system. Cron automatic update default period is every ten minutes. DtDNS automatic IP updater has been pre-configured, but it is disabled by default on Uniserver. To enable DtDNS automatic IP updater, Cron configuration file in C:\PEmailOffline\UniServer\unicon\main\run_cron.php edited by changing lines in the section list of scripts to be run as shown in Table 5.5 (A). Then those lines uncomment as shown in Table 5.5 (B).
  // $cmd = 'start ..\..\usr\local\php\php-win.exe ..\..\plugins\dtdns_updater\dtdns_updater.php';
  // pclose(popen($cmd,'r'));        // Start detatched process
  $cmd = 'start ..\..\usr\local\php\php-win.exe ..\..\plugins\dtdns_updater\dtdns_updater.php';
pclose(popen($cmd,'r'));             // Start detatched process
Table 5.5: Enable Cron
DtDNS account details where the hostname is and password configured in a Cron script configuration file located in:
Uniserver uses binary code 1 which means perform the function while 0 means ignore and do nothing. Default value "7" is a total of 1+2+4 which will run the Apache, MySQL and Index page processes. Cron Binary code is "16".Total binary code value for Apache, MySQL and Cron is 19. Figure 5.1 shows the binary codes have been assigned.
Figure 5.1: Uniform Server Binary Codes
To enable automatic Cron on Uniserver, file in “C:\PEmailOffline\UniServer\unicon\main\includes\” edited as shown in Table 5.6. This binary code value will enable the Apache, MySQL, Index page processes and Cron run when the Uniserver program started.
  $server_standard = 19;
  $server_service  = 19;
Table 5.6: Enable Cron automatic update on Uniserver
Apache, MySQL and Cron need to be configured to start up all at once. Cron can be configured to run automatically when the servers are started by editing file in C:\PEmailOnline\UniServer\unicon\tray_menu\UniTray1.ini. Under “LEFT MENU” there are lines to control Server Start and Stop. Programs or batch files that run either of the control scripts start_servers.php or stop_servers.php must include a single binary coded parameter. If this parameter is missing defaults value 7 are used. A parameter overrides any default settings this allows independent control of a particular function. Then, default binary code should be changed from 7 to 19 for these lines "%PHP%\php.exe"; Parameters: " -n %ServerConMain%\start_servers.php 19"; as per Table 5.7 below:
;=== LEFT MENU ============
Type: item; Caption: "Start UniServer (Apache MySQL)"; Action: shellexecute; FileName: "%PHP%\php.exe"; Parameters: " -n %ServerConMain%\start_servers.php 19"; ShowCmd: hidden; Glyph: 9
Type: item; Caption: "Stop  UniServer (Apache MySQL)"; Action: shellexecute; FileName: "%PHP%\php.exe"; Parameters: " -n %ServerConMain%\stop_servers.php 19";ShowCmd: hidden; Glyph: 11

Table 5.7: Apache. MySQL and Cron startup script configuration

Sunday, December 21, 2014

5.4.2 Web server Application

            Web server application running on the server computer to deliver webmail page access to the client. Web server application for this system is Uniserver 7.1.4. Web server application file extracted to respective location which is C:\PEmailOffline\UniServer for offline environment server computer. Starting Uniserver will open a Server Administrator page in a default Web Browser. The Server Administrator page only accessible by the server computer admin. Admin of the server computer used this page to configure the username and password for the admin panel configuration, private server configuration and private secure server configuration (SSL) and MySQL server configuration. MySQL is a relational database management system (RDBMS) used by the web server application. Files C:\PEmailOffline\UniServer\www\.htaccess edited with text editor and next four lines commented by adding “#” to allow external access as per Table 5.4 below:
#Order Deny,Allow
#Deny from all
#Allow from
#Allow from ::1
Table 5.4: Enable Web server External Access Script
This will disable server security limitation access from localhost only and enable access using the server IP address. The PHP value for maximum message size located in “. htaccess” file in "...UniServer\www\pemail" and “php.ini” file in "...UniServer\usr\local\php" also configured to upload maximum file size is 10MB, post maximum size is 50MB and memory limit is 64MB. This value is to give a size limit of attachment file.
This offline email system uses MIME standards and do not specify any file size limits for maximum upload size to be allowed [25].  Limits for maximum upload size can be configured in web server setting file “php.ini”, where the maximum attachment size is 2147483647 MB which is a maximum value for a 32-bit signed integer supported by a SQL database. The maximum message size is unlimited by setting the value to zero. The maximum disk space that the account may use is limited to the server computer hard disk storage available space. If the hard disk is full, the limit is reached and the account will not be able to receive any more email. If a maximum message size is specified, the mail server will reject messages larger than that size. It is recommended to set a maximum message size limit to prevent the server from any types of attack. As an example, attackers could send a big size message and fills the server hard disk which will cause a problem to the server computer.
This offline email system maximum message size is set to 50MB. The mail server will reject messages larger than this size. Email content size is small and usually 1MB or less. This offline email system maximum message size is set to 10MB. Limiting maximum attachment size default value 10MB is acceptable to ensure the mail server network performance is not dropping when multiple users uploading a very big file at the same time to the mail server. Limiting the size of email attachments to 10MB is also a safe setting for the maximum size of an email since other email services commonly used 10MB as a maximum size of an email attachment. If the maximum size of an email attachment is 30MB or greater than 10MB and this offline email system is successfully send the email to the receiver, there is no guarantee that the receiver can receive the email since there is a different maximum size limitation of email attachment on every email service. Gmail limiting the size of email attachments to 25MB with no specified limit to the number of attachment as long the total size is 25MB [26]. Yahoo Mail allows user to upload up to 50 files to an email message as long as the total message size remains under 25MB [27].

Every email account has total allocated maximum size storage. If an email is sent to this account when the quota has been used, the mail server will deliver a notification to the sender containing the information that the quota for the recipient had been reached. After that, the email message will be dropped. Each email in this offline email system allocated size is set to 250MB.