## Sunday, January 31, 2010

### How to make a Yin-Yang symbol, both basic and bordered.

Yin Yang is a symbol often associated with Daoism (Taoism), the Yin Yang symbol represents a unity of correlating opposites. This is often a slightly hard concept for the western mind to comprehend straight off the bat.

We tend to think of opposites as opposing each other and being diametric in that opposition; good and evil, black and white, order and chaos.

Yin Yang is more subtle though, well at least in my interpretation, it represents the whole of a given phenomena, and that inside the whole their exists two forces that are distinct from one another in nature, though are balanced by each other.

These two forces flow into each other, and are also contained by the whole. There is a duality between the forces, but it is a complimentary one.

The black and white Yin Yang symbol, is perhaps a little misleading and leads us into absolute thinking, which is not the nature of the Dao, but then again perhaps it is.

So, whilst holding to the idea that to explain the Dao is not to understand the Dao, I will move on from this position of ignorance to just explain how to create the Yin Yang shape.

This tute is in two parts. I will show how to make a standard yin-yang symbol like the one below, then I will show how to make the bordered version in the second image. The underlying shape of the Yin Yang symbol is that of a circle, the circle is divided into two even halves, instead of a straight line making the divide, the divide is curved. I hesitate to call it a sine curve, because I will probably have to back that up with some equation. Instead I will just describe it as a curve that is the result of including two more circles that are aligned centrally, and are each half the size of the outer circle. This description turns out to be more useful when constructing the shape as well.

When designing the Yin Yang shape, in the strict interpretation, there is a further outer ring (the whole), I will keep with tradition here, but you will often see the symbol designed without it.

When I design I prefer to use digital criteria, as opposed to the more analog style of positioning, the Yin Yang shape is actually quite good a demonstration of this style. Aesthetics come in when you wish to show that the forces are in fact not pure elements, and instead contain a number of similar elements.

So, the steps I will show will make use of the dialogs as much as possible and reduce the need to position stuff using your eyes.

Image

2. Create two new transparent layers.
3.Drag guides out from the top and the bottom to create a cross hair in the center of the canvas at 400, 400 (since Gimp numbers the pixels starting at 0,0, this is actually at 401,401).
4.Drag two more guides out from the top. Place one at 250 from the top and one at 550 from the top. Each guide is positioned so that you can drag out a circle that is half the diameter of your large circle. Basically the proportions seem to be 3:2:1 for main circle, half circle, eye. Dunno if there is an "official" standard for how these are supposed to be proportioned.

5.We are going to make our symbol 600 pixels in diameter. Using the elliptical/Circular select tool, place your cursor close to the center of your cross hair. Drag out a selection, with your selection begun and while still holding down the left mouse button, press <ctrl> and <shift> simultaneously. This will center a perfectly circular selection centered on 400,400. Drag out a selection that is 600x600.

6.Do Select>Save to Channel.
7.Do Select>None.
8.Put your cursor on the upper cross hair at 400,250. Using <ctrl-shift> drag out a selection that is 300x300. Save that selection to a channel and then do Select>None.

9.Do the same thing with the lower cross hair at 400, 550. You should now have three saved selections, a larger 600 circle centered in your canvas, and two smaller 300 size selections, one located with it's upper edge just touching the “top” of the 600x600 selection, and one just touching the “bottom.”
10.Go to your channels tab and pick the the saved 600x600 selection. Do Channel to Selection.
11. Now go to the channel that has your “upper” 300x selection. Do Subtract from selection. You should have a sort of “fat crescent moon” shape.

13. Now go to your selections tab and pick the lower 300x saved selection. Do Add to Selection. You should now have half a yin-yang symbol. Save this selection to a channel.

[highlight]EDIT[/highlight]

If I had a brain, I'd be dangerous....There is a better way to create the second half of the symbol, though I will leave the rest of the tute as it stands. You have your original circle saved to a channel, and you have the half yang you just saved. So, go to the channels tab, pick the original circle. Do channel to selection. Now go to your half yang and do subtract from selection. You will have the other half of your symbol, just save that to a new channel. No need to follow the rest of the tut with the second 300x circle (you don't even need to make it in the first place), just jump to step 17.

[highlight]END OF EDIT[/highlight]

14. You may be tempted to try copying and flipping this to do the other half. Don't. The two halves will not quite line up. Instead repeat steps 10-13, but reverse the order you use the two 300x selections in. When you drag out the rectangular selection to "erase" the other half of the circle, do it to the left rather than the right. When you get done, you should have two saved selections, each as half of your yin yang symbol. Below is a screenshot of my channels tab at this point, you might want to rename each layer, especially if you want to do the bordered yin-yang symbol, the one below has all the channel layers, plus the ones for the bordered version.

You can also do all your selections by using your shift and control keys to add or subtract from your selection. I like to use the channels because it is less hassle if you screw up, and it is handy to have the pre-saved selections for doing the more “advanced” bordered yin-yang symbol.

15. To create the “eye” in each half, center your cursor on either the upper or lower crosshair and drag out a perfectly centered round selection that is 1/3 the diameter of half of your larger circle. In other words, if your whole yin-yang symbol is 600 pixels in diameter, and half of that is 300, then 1/3 of that would be 100. Create an upper and a lower saved selection for each eye.

16.Use the eye selections to subtract from the larger Yin/Yang shapes.

17. Bucket fill the Yin/Yang sections with your color of choice. I prefer to do each half on it's own layer.
18. Save your file as a native Gimp .xcf file if you plan to attempt the “bordered” yin-yang symbol.

source: GimpTalk

## Tuesday, January 26, 2010

### Mahara is an open source e-portfolio system with a flexible display framework

Mahara is an open source e-portfolio system with a flexible display framework. Mahara, meaning 'think' or 'thought' in Te Reo Māori, is user centred environment with a permissions framework that enables different views of an e-portfolio to be easily managed. Mahara also features a weblog, resume builder and social networking system, connecting users and creating online learner communities.

Mahara supports the LEAP2A standard for importing and exporting data, allowing a user to take their content with them from one Mahara installation and import it into another[1]. Limited interoperability exists between Mahara and other systems supporting the LEAP2A standard also

Installing Mahara
This is a guide to installing Mahara. It's mainly targeted at the main platform on which people will install it (Linux with Apache), though Mahara can be installed on other platforms.

Mahara is a web application. This means it's not just an executable file you can download and run. You need a server to put it on (you can use your desktop as a server if you're just trialling it). You'll need to install other software for it to run too - such as the Apache web server and PostgreSQL database system. Another alternative is to use shared hosting - but this isn't as good as having a machine where you can have administrator access.

If you're running Debian/Ubuntu, a lot of the required software (and even Mahara itself) can be installed using apt-get. If you're using some other linux distribution, you may be able to use your distribution specific install tool also.

Dependencies

Mahara is mainly designed for use on Linux, using the Apache web server, PostgreSQL database server and PHP. We also support its use with the MySQL database server.

In addition, members of the community have successfully got Mahara running on Mac OSX and Windows, and have also managed to use nginx instead of Apache. The Mahara developers fix bugs found that prevent running on these platforms, but don't explicitly test them from day to day, so you may have less luck than using a Linux box with Apache.

Hardware

• CPU: any modern CPU produced in the last few years is fine, the faster the better naturally. PHP pages are CPU limited, so faster CPUs mean quicker response times.
• Memory: 256MB at an absolute minimum. 1G or more is recommended.
• Disk: This will depend largely on how much disk quota you want each user to have. For a site of 1000 users, each with a 250M quota, you might need 50G to start with.

See the scalability article for more information on the hardware required, and how you can calculate how much you need. One modern entry-level server will handle an average school or college quite sufficiently. In many cases, you can get away with a virtual environment such as a VPS.

Software

• Linux - any distribution should be fine, Debian or Ubuntu are recommended as they're most regularly tested on, and even have debian packages.
• PHP - 5.1.3 or greater. You'll need these PHP extensions also.
• PostgreSQL - 8.1+ (recommended), or MySQL 5.0.25+ with InnoDB table support.
• Apache - 1.3 or higher, version 2 or higher recommended

More details about the Software Requirements are available, including what you can substitute for any of them.

Get the code, and put on your webserver

In order for your Mahara to run, you need to put a copy of the code on your own server. You can either download a standard build of Mahara, or check out the project from the git repository if you know how git works (this option is mainly for developers).

Once you have the code, copy the contents of the htdocs/ directory to your webserver. It is best if you either:

• Copy the entire directory, then rename it to something like 'mahara' - so you will see your site at example.org/mahara/; or

• Copy the contents of the htdocs/ directory to the top level public directory (often called htdocs or public_html) of your webserver, so you can see your site at example.org.

If you are unfamiliar with Ubuntu and need an in more detailed explanation about how to install the files and configure Apache, go to the step-by-step guide.

Create the Database

You need to create a database for Mahara and ensure that the webserver is able to connect to it. Instructions for the command line follow, if you have access to a CPanel or similar software you can create the database using it instead.

Your database must be UTF8 encoded. The commands below create a UTF8 encoded database, if you use CPanel etc., then you will have to make sure it creates you a UTF8 database.

Command line instructions for Postgres:

# Run these commands while su'd to the 'postgres' user# If you need to create a database user:createuser -SRDP (username)# Actual database creationcreatedb -O (username who will be connecting) -EUTF8 (databasename)

Command line instructions for MySQL:

mysql -Uroot<br />[enter password]<br />create database (databasename) character set UTF8;<br />grant all on (databasename).* to 'username'@'localhost' identified by 'password';

By the way, if possible, try to use PostgreSQL for your database if you can.

Create the Dataroot Directory

This is a directory where Mahara will write files that are uploaded to it, as well as some other files it needs to run. The main point about this directory is that it is one that the web server can write to. The other main point is that it cannot be inside the directory where your Mahara code is! In fact, if you have a public_html directory, it should not be inside that at all.

On your webserver, you will need to make this directory. If you have a public_html directory, make the directory alongside it. You can give it a name like 'maharadata'. Once you are done, you should have this directory structure (ignoring files):

<code>.../yourusername/public_html</code><br /><code>.../yourusername/maharadata</code>

You will need to make the maharadata directory writable by the web server user. You can either change its owner to be the web server user, or you can chmod it to 777. The latter isn't recommended, but if you're on shared hosting it's what you'll probably have to do. FTP programs will allow you to chmod the directory.

Create Mahara's config.php

In the Mahara htdocs directory is config-dist.php. You need to make a copy of this called config.php. You then need to go through the file and make changes where appropriate. The file is commented, and there are not many settings to change. However, take special note of the following settings:

• database connection details — ensure you include the database connection details by inserting the proper values for $cfg->dbname,$cfg->dbuser, $cfg->dbpass,$cfg->dbprefix.
• Note: You do not need to set dbprefix, unlike Moodle. Try not using it first, and see if it works. If you find you do need it, you may find it best to leave dbprefix empty and add the prefix directly to $cfg->dbname,$cfg->dbuser values.

• dataroot - set this to the filesystem path to the directory you made that the web server user can write to. Please note this is a filesystem path, which on linux will look like /path/to/your/directory and on windows will look like C:\path\to\your\directory. This is NOT a web address such as http://example.org/maharadata!

• directorypermissions - if you're on a server where you do not have root access, you should change this from 0700 to 0777 or similar, so that you can download your dataroot later for backup purposes, and install language packs.

Apache Configuration

Note: If you're on shared hosting, you probably are not able to change this, so you can ignore this section.

The simplest of Apache VirtualHost configurations will be sufficient:

<VirtualHost *:80><br />        ServerName example.org<br />        DocumentRoot /path/to/mahara/htdocs<br /><br />        ErrorLog /var/log/apache2/mahara.error.log<br />        CustomLog /var/log/apache2/mahara.access.log combined<br /><br />        <Directory /path/to/mahara/htdocs><br />                AllowOverride All<br />        </Directory><br /></VirtualHost>

Please note that your apache configuration should contain no ServerAliases. Mahara expects to be accessed through ONE URL. This gives certainty that cookies are set for the right domain, and also means that SSL certificates for the networking functionality can be generated for this one URL. If you use a server alias, you should expect to see problems like having to log in twice, and potentially SSO between your site and others breaking.

However, you can still make both example.org and www.example.org work for your site, if you use a second VirtualHost directive as well as the one above:

<VirtualHost *:80><br />    ServerName www.example.org<br />    # You _can_ add ServerAliases here if you want more than one URL to<br />    # redirect to your main site<br />    # ServerAlias foo.example.org<br /><br />    Redirect Permanent / http://example.org/<br /></VirtualHost><br />

Run the Web Based Installer

What if the installation process breaks with an error?

Sometimes this can happen. Normally this is because of some misconfiguration in your system - for example, you haven't granted your database user permission to create tables, or you aren't using a high enough version of your database (see the dependencies). Sometimes, it's because of a bug in the Mahara installer. In order to find out, you will need to check the error log for your webserver. Mahara dumps detailed information in there where a bug occurs.

The message might show you that the problem is with your configuration, but if it looks like a problem with Mahara, you should make a bug report with the information from your logs, so we can fix it.

If you were able to fix the problem, you might need to drop and re-create your database again, so you're starting the installation again without any of the previously installed tables in the way.

Final Task (don't forget!): Cron Job

You will need to set up a cron job to hit htdocs/lib/cron.php every minute. Mahara implements its own cron internally, so hitting cron every minute is sufficient to make everything work.

If you don't set up the cron job, you will find that RSS feeds will not update, and some email notifications won't be sent out, such as forum post notifications.

You can set it up using the command line 'php' command to run the cron script, or by using a command line web browser such as lynx or w3m.

Something like the following in a crontab file will be sufficient:

* * * * * curl http://your-mahara-site.org/lib/cron.php

If you run cron using curl, the cron output will be logged in your apache error log. If you wish to separate where it's logged to away from your apache logs (which is a particularly good idea, though slightly harder to set up), read the separate article about Mahara's cron.

### Yaws is a HTTP high perfomance 1.1 webserver particularly well suited for dynamic-content webapplications

Yaws (Yet another web server) is a web server written in Erlang by Claes (klacke) Wikström.

Yaws can be embedded into other Erlang-based applications or run as a regular standalone web server.

Because Yaws uses Erlang's lightweight threading system, it performs well under high concurrency.

A load test conducted in 2002 comparing Yaws and Apache found that with the hardware tested, Apache 2.0.39 with the worker MPM failed at 4,000 concurrent connections, while Yaws continued functioning with over 80,000 concurrent connections.

Last stable relase: 1.87 (2010-01-05)

Two separate modes of operations are supported.

* Standalone mode where Yaws runs as a regular webserver daemon. This is the default mode.
* Embedded mode where Yaws runs as an embedded webserver in another erlang application.

* websocket support (davide and wde)
* conditional compile of websockets, only use if the chosen erl supports it (klacke/steve)
* patch by Andrei Soroker to strip the port part in #redir_self records - this patch may break some code, users that use redir_self() and unconditionally strip off their optional port number are affected
* support some extra status codes in code_to_phrase (steve)
* drop spaces before parsing ints - patch by Colm Dougan
* proper handling of "/" appmod with excluded paths (patch from wde)
* Added new unit tests for appmods, with both / and non-/ tests. The / tests include exclude_paths testing. (steve)
* patch from wde solving a problem with appmod exclude paths and verify_upgrade
* yaws_server: fixed the test for whether to close the socket. The yaws:outh_get_doclose() doesn't return a boolean and it requires the outh dicionary entry to be set (sometimes it isn't). (davide)
* do not pass the --id option if the default id is used (steve)

Let us not forget the famous comparison between Yaws and Apache. In a denial of service attack, the number of parallel connections needed to crash the Erlang web server was about 20 times as many as an Apache web server running on the same hardware. Apache (blue and green) dies when subject to a load of concurrent 4,000 parallel requests. Yaws (red) works till 80,000 concurrent requests.

I will try to give you a simple example about how to create a simple dynamic web page with Yaws.

This a simple Hello world to Yaws.

<html>
<h1> Title</h1>
<erl>
out(Arg) -> {html, “Hello World"}.
</erl>
<h1> Something</h1>
</html>

Thanks to Yariv Sadan’s effort to involve Erlang in the web development community using ErlyWeb which is a web framework that helps you easily build database-driven applications using the MVC architecture. It's similar to Ruby on Rails, except that it's written in Erlang. There is also ErlyDB a database abstraction layer generator. ErlyDB taps into Erlang’s runtime metaprogramming powers to generate an abstraction layer for your database on the fly.

I am going to propose an architecture for web development using Erlang. It will consists of five layers:

* Hardware/ Operating System: This layer represents the physical layer of the system. It can be a Linux system running on a network file system(NFS) to make use of the concurrency and distribution features in Erlang.
* DBMS: This layer represents the persistence layer of the system. It can be either Mnesia or MySQL.
* Data Base Abstraction Layer.
* Erlang/Open Telecom Platform: It is the standard libraries of the Erlang language.
* Presentation Layer: This layer consists of two components. Yaws as a web server and ErlyWeb as rapid development framework.

## Saturday, January 23, 2010

### The Apache HTTP Server Project is an effort to develop and maintain an open-source HTTP server for modern operating systems including UNIX

The Apache HTTP Server Project is an effort to develop and maintain an open-source HTTP server for modern operating systems including UNIX and Windows NT. The goal of this project is to provide a secure, efficient and extensible server that provides HTTP services in sync with the current HTTP standards.

Apache has been the most popular web server on the Internet since April 1996.

The Apache HTTP Server is a project of The Apache Software Foundation.

Last Stable Version: Apache 2.2.14

The Apache HTTP Server Project is a collaborative software development effort aimed at creating a robust, commercial-grade, featureful, and freely-available source code implementation of an HTTP (Web) server. The project is jointly managed by a group of volunteers located around the world, using the Internet and the Web to communicate, plan, and develop the server and its related documentation. This project is part of the Apache Software Foundation. In addition, hundreds of users have contributed ideas, code, and documentation to the project. This file is intended to briefly describe the history of the Apache HTTP Server and recognize the many contributors.

In February of 1995, the most popular server software on the Web was the public domain HTTP daemon developed by Rob McCool at the National Center for Supercomputing Applications, University of Illinois, Urbana-Champaign. However, development of that httpd had stalled after Rob left NCSA in mid-1994, and many webmasters had developed their own extensions and bug fixes that were in need of a common distribution. A small group of these webmasters, contacted via private e-mail, gathered together for the purpose of coordinating their changes (in the form of "patches"). Brian Behlendorf and Cliff Skolnick put together a mailing list, shared information space, and logins for the core developers on a machine in the California Bay Area, with bandwidth donated by HotWired. By the end of February, eight core contributors formed the foundation of the original Apache Group:

Brian Behlendorf Roy T. Fielding Rob Hartill
David Robinson Cliff Skolnick Randy Terbush
Robert S. Thau Andrew Wilson

Eric Hagberg Frank Peters Nicolas Pioch

Using NCSA httpd 1.3 as a base, we added all of the published bug fixes and worthwhile enhancements we could find, tested the result on our own servers, and made the first official public release (0.6.2) of the Apache server in April 1995. By coincidence, NCSA restarted their own development during the same period, and Brandon Long and Beth Frank of the NCSA Server Development Team joined the list in March as honorary members so that the two projects could share ideas and fixes.

The early Apache server was a big hit, but we all knew that the codebase needed a general overhaul and redesign. During May-June 1995, while Rob Hartill and the rest of the group focused on implementing new features for 0.7.x (like pre-forked child processes) and supporting the rapidly growing Apache user community, Robert Thau designed a new server architecture (code-named Shambhala) which included a modular structure and API for better extensibility, pool-based memory allocation, and an adaptive pre-forking process model. The group switched to this new server base in July and added the features from 0.7.x, resulting in Apache 0.8.8 (and its brethren) in August.

After extensive beta testing, many ports to obscure platforms, a new set of documentation (by David Robinson), and the addition of many features in the form of our standard modules, Apache 1.0 was released on December 1, 1995.

Less than a year after the group was formed, the Apache server passed NCSA's httpd as the #1 server on the Internet and according to the survey by Netcraft, it retains that position today.

In 1999, members of the Apache Group formed the Apache Software Foundation to provide organizational, legal, and financial support for the Apache HTTP Server. The foundation has placed the software on a solid footing for future development, and greatly expanded the number of Open Source software projects, which fall under this Foundation's umbrella.

There is a core group of contributors, formed initially of the project founders, and augmented from time to time by other outstanding contributors. There are 'committers', who are granted access to the source code control respositories to help maintain the project or docs, and the core group now managing the project, which is called the Apache HTTP Project Management Committee (PMC, for short). In fact, each Apache Software Foundation project has its own PMC, to determine committers, project direction and overall management. The terms "The Apache Group" or "Apache Core" are no longer used.

The project is a meritocracy -- the more work you have done, the more you will be allowed to do. The group founders set the original rules, but they can be changed by vote of the active PMC members. There is a group of people who have logins on our server and access to the source code repositories. Everyone has read-only access to the repositories. Changes to the code are proposed on the mailing list and usually voted on by active members -- three +1 ('yes' votes) and no -1 ('no' votes, or vetoes) are needed to commit a code change during a release cycle; docs are usually committed first and then changed as needed, with conflicts resolved by majority vote.

Our primary method of communication is our mailing list. Approximately 40 messages a day flow over the list, and are typically very conversational in tone. We discuss new features to add, bug fixes, user problems, developments in the web server community, release dates, etc.

The actual code development takes place on the developers' local machines, with proposed changes communicated using a patch (output of a unified "diff -u oldfile newfile" command), and then applied to the source code control repositories by one of the committers. Anyone on the mailing list can vote on a particular issue, but only those made by active members or people who are known to be experts on that part of the server are counted towards the requirements for committing. Vetoes must be accompanied by a convincing technical justification.

New members of the Apache HTTP Project Management Committee are added when a frequent contributor is nominated by one member and unanimously approved by the voting members. In most cases, this "new" member has been actively contributing to the group's work for over six months, so it's usually an easy decision.

The project guidelines continously evolve under the oversight of the PMC, as the membership of the group changes and our development/coordination tools improve.

Apache Software exists to provide robust and commercial-grade reference implementations of many types of software. It must remain a platform upon which individuals and institutions can build reliable systems, both for experimental purposes and for mission-critical purposes. We believe that the tools of online publishing should be in the hands of everyone, and that software companies should make their money by providing value-added services such as specialized modules and support, amongst other things. We realize that it is often seen as an economic advantage for one company to "own" a market - in the software industry, that means to control tightly a particular conduit such that all others must pay for its use. This is typically done by "owning" the protocols through which companies conduct business, at the expense of all those other companies. To the extent that the protocols of the World Wide Web remain "unowned" by a single company, the Web will remain a level playing field for companies large and small. Thus, "ownership" of the protocols must be prevented. To this end, the existence of robust reference implementations of various protocols and application programming interfaces, available free to all companies and individuals, is a tremendously good thing.

Furthermore, the Apache Software Foundation is an organic entity; those who benefit from this software by using it, often contribute back to it by providing feature enhancements, bug fixes, and support for others in public lists and newsgroups. The effort expended by any particular individual is usually fairly light, but the resulting product is made very strong. These kinds of communities can only happen with freely available software -- when someone has paid for software, they usually aren't willing to fix its bugs for free. One can argue, then, that Apache's strength comes from the fact that it's free, and if it were made "not free" it would suffer tremendously, even if that money were spent on a real development team.

We want to see Apache Software used very widely -- by large companies, small companies, research institutions, schools, individuals, in the intranet environment, everywhere -- even though this may mean that companies who could afford commercial software, and would pay for it without blinking, might get a "free ride" by using Apache.

We are even happy when some commercial software companies completely drop their own HTTP server development plans and use Apache as a base, with the proper attributions as described in the LICENSE. That is to say, the Apache HTTP Sever only comes from the Apache Software Foundation, but many vendors ship their own product "based on the Apache {Project}". There is no "{Vendor} Apache {Product}", this is an abuse of the Apache Software Foundation's marks.

## My Blog List

• - ** *source: World Images* *If you liked this article, subscribe to the feed by clicking the image below to keep informed about new conte...
• - The *Czech Republic* is a landlocked country in Central Europe. The country is bordered by Germany to the west, Austria to the south, Slovakia to the eas...
• - [image: Murraya_paniculata2]The Orange Jessamine is a material that is widely used for bonsai in the warmer areas of Southeast Asia. The plant is in the ci...
• - *Install Dorian Dark Theme In Ubuntu 13.04 Or Older And Linux Mint* To install *Dorian theme* in Ubuntu/Linux Mint open Terminal (Press * Ctrl+Alt+T*) ...
• - *source: Images Photo Gallery* [image: www.zanox.com] * * *If you liked this article, subscribe to the feed by clicking the image below to keep...