Thursday, August 21, 2008

ApacheMySQLPHP - Community Ubuntu Documentation

ApacheMySQLPHP - Community Ubuntu Documentation

(Modified by LJS)

Parent page: Programming Applications

This is to help people setup and install a LAMP (Linux-Apache-MySQL-PHP) server in Ubuntu, including Apache 2, PHP 5 (optionally PHP 4 in Ubuntu 6.10 and lower), and MySQL 4.1 or 5.0.

When installing from the Ubuntu 6.06 (Dapper Drake) "Server cd", you have the option of choosing to install a LAMP setup at the inital Ubuntu installation screen. That will install apache2, php5 and mysql 5.0.

Check Requirements

As of Ubuntu 7.04 (Feisty), all PHP4 packages have been dropped from the repositories, as the PHP4 branch is not being further developed/supported by the PHP Group. Everything in this article pertaining to PHP4 can therefore only be executed in Ubuntu 6.10 and lower. If you absolutely depend on PHP4 and would like to use the current Ubuntu release, you have to compile it from source.

Some applications require php4 while others will work with php5. Be sure to install the version of php and the corresponding apache2 module for it. You cannot have both php4 and php5 modules running on the same instance of apache2 at the same time. Installing one may remove the other.

If you have both php4 and php5 installed, be aware of which version of the apache2 php module you have. If libapache2-mod-php5 is already installed, the php4 package will install libapache-mod-php4 and not libapache2-mod-php4 package.

If libapache2-mod-php5 is not installed, installing php4 will install the apache2 php module (libapache2-mod-php4). See this example.

Most web applications will use Apache2, php5 and mysql5.0. If no specific versions are mentioned in your web application's documentation, use those.

To install the default LAMP stack in Ubuntu 6.06 LTS (Dapper Drake)

If you did not use the LAMP installer option from the server cd but want to install those same packages without having to reinstall your operating system, use any method to install the following packages

apache2 php5-mysql libapache2-mod-php5 mysql-server

All of those packages are in the Ubuntu 6.06 LTS (Dapper Drake) main repository. Once LAMP is installed, you need to set a mysql root password and then, depending on your web application, create a database, user and password. That's it!

To install the default LAMP stack in Ubuntu 7.04 (Feisty Fawn) Ubuntu 7.10 (Gutsy Gibbon) and Ubuntu 8.04 LTS (Hardy Heron)

As of the 7.04 release, the Ubuntu base system includes Tasksel. You can either install LAMP using tasksel or install the LAMP packages as detailed above.

sudo tasksel install lamp-server

See Tasksel

Starting over, How to remove the LAMP stack

To remove the LAMP stack remove the following packages:

apache2 apache2-mpm-prefork apache2-utils apache2.2-common libapache2-mod-php5 libapr1 libaprutil1 libdbd-mysql-perl libdbi-perl libmysqlclient15off libnet-daemon-perl libplrpc-perl libpq5 mysql-client-5.0 mysql-common mysql-server mysql-server-5.0 php5-common php5-mysql

To also remove the debconf data, use the purge option when removing. To get rid of any configurations you may have made to apache, manually remove the /etc/apache2 directory once the packages have been removed.

Installing Apache 2

To only install the apache2 webserver, use any method to install

apache2

Troubleshooting Apache

If you get this error:

apache2: Could not determine the server's fully qualified domain name, using 127.0.0.1 for ServerName

then use a text editor such as "sudo nano" at the command line or "gksudo gedit" on the desktop to create a new file,

sudo nano /etc/apache2/conf.d/fqdn

or

gksu "gedit /etc/apache2/conf.d/fqdn"

then add

ServerName localhost

to the file and save. This can all be done in a single command with the following:

echo "ServerName localhost" | sudo tee /etc/apache2/conf.d/fqdn

Virtual Hosts

Apache2 has the concept of sites, which are separate configuration files that Apache2 will read. These are available in /etc/apache2/sites-available. By default, there is one site available called default this is what you will see when you browse to http://localhost or http://127.0.0.1. You can have many different site configurations available, and activate only those that you need.

As an example, we want the default site to be /home/user/public_html/. To do this, we must create a new site and then enable it in Apache2.

To create a new site:

  • Copy the default website as a starting point. sudo cp /etc/apache2/sites-available/default /etc/apache2/sites-available/mysite

  • Edit the new configuration file in a text editor "sudo nano" on the command line or "gksudo gedit", for example: gksudo gedit /etc/apache2/sites-available/mysite

  • Change the DocumentRoot to point to the new location. For example, /home/user/public_html/

  • Change the Directory directive, replace to

  • You can also set separate logs for each site. To do this, change the ErrorLog and CustomLog directives. This is optional, but handy if you have many sites

  • Save the file

Now, we must deactivate the old site, and activate our new one. Ubuntu provides two small utilities that take care of this: a2ensite (apache2enable site) and a2dissite (apache2disable site).

sudo a2dissite default && sudo a2ensite mysite

Finally, we restart Apache2:

sudo /etc/init.d/apache2 restart

If you have not created /home/user/public_html/, you will receive an warning message

To test the new site, create a file in /home/user/public_html/:

echo 'Hello! It is working!' > /home/user/public_html/index.html

Finally, browse to http://localhost/

Installing PHP 5

To only install PHP5. use any method to install

php5

If PHP4 is present on your system, also install

libapache2-mod-php5

Troubleshooting PHP 5

Does your browser ask if you want to download the php file instead of displaying it? If Apache is not actually parsing the php after you restarted it, install libapache2-mod-php5. It is installed when you install the php5 package, but may have been removed inadvertently by packages which need to run a different version of php.

You may also need to actually enable it, by doing sudo a2enmod php5 followed by sudo /etc/init.d/apache2 restart. If sudo a2enmod php5 returns "$ This module does not exist!", you should purge (not just remove) the libapache2-mod-php5 package and reinstall it.

Be sure to clear your browser's cache before testing your site again.

Installing PHP 4

To install PHP4, Use any method to install

php4

If PHP5 is present on your system, installing php4 will install the php module for apache (version 1.3) and not apache2. To use php4 with apache2, install

libapache2-mod-php4

Troubleshooting PHP 4

Does your browser ask if you want to download the php file instead of displaying it? If Apache is not actually parsing the php after you restarted it, install libapache2-mod-php4. It is installed when you install the php4 package, but may have been removed inadvertently by packages which need to run a different version of php.

You may also need to actually enable it, by doing sudo a2enmod php4 followed by sudo /etc/init.d/apache2 restart. If sudo a2enmod php4 returns "$ This module does not exist!", you should purge (not just remove) the libapache2-mod-php5 package and reinstall it.

Be sure to clear your browser's cache before testing your site again.

Installing MYSQL with PHP 5

Use any method to install

mysql-server libapache2-mod-auth-mysql php5-mysql

Installing MYSQL with PHP 4

First enable the universe repository since the packages are not in main

Use any method to install

mysql-server libapache2-mod-auth-mysql php4-mysql

After installing PHP

You may need to increase the memory limit that PHP imposes on a script. Edit the /etc/php5/apache2/php.ini file and increase the memory_limit value.

After installing MySQL

Set mysql bind address

Before you can access the database from other computers in your network, you have to change its bind address. Note that this can be a security problem, because your database can be accessed by others computers than your own. Skip this step if the applications which require mysql are running on the same machine.

type:

nano /etc/mysql/my.cnf

and change the line:

bind-address           = localhost

to your own internal ip address e.g. 192.168.1.20

bind-address           = 192.168.1.20

If your ip address is dynamic you can also comment out the bind-address line and it will default to your current ip.

If you try to connect without changing the bind-address you will recieve a "Can not connect to mysql error 10061".

Set mysql root password

Before accessing the database by console you need to type:

mysql -u root

At the mysql console type:

mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('yourpassword');

A successful mysql command will show:

Query OK, 0 rows affected (0.00 sec)

Mysql commands can span several lines. Do not forget to end your mysql command with a semicolon.

Note: If you have already set a password for the mysql root, you will need to use:

mysql -u root -p

(Did you forget the mysql-root password? See MysqlPasswordReset.)

Create a mysql database

mysql> CREATE DATABASE database1;

Create a mysql user

For creating a new user with all privileges (use only for troubleshooting), at mysql prompt type:

mysql> GRANT ALL PRIVILEGES ON *.* TO 'yourusername'@'localhost' IDENTIFIED BY 'yourpassword' WITH GRANT OPTION;

For creating a new user with fewer privileges (should work for most web applications) which can only use the database named "database1", at mysql prompt type:

mysql> GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES ON database1.* TO 'yourusername'@'localhost' IDENTIFIED BY 'yourpassword';

yourusername and yourpassword can be anything you like. database1 is the name of the database the user gets access to. localhost is the location which gets access to your database. You can change it to '%' (or to hostnames or ip addresses) to allow connections from every location (or only from specific locations) to the database. Note, that this can be a security problem and should only be used for testing purposes!

To exit the mysql prompt type:

mysql> \q

Since the mysql root password is now set, if you need to use mysql again (as the mysql root), you will need to use:

mysql -u root -p

and then enter the password at the prompt.

Backup-Settings

Please, let's say something in which directories MySql stores the database information and how to configure a backup

Alternatively

There is more than just one way to set the mysql root password and create a database. For example mysqladmin can be used:

mysqladmin -u root -p password yourpassword

and

mysqladmin -u root -p create database1

mysqladmin is a command-line tool provided by the default LAMP install.

Phpmyadmin and mysql-admin

All mysql tasks including setting the root password and creating databases can be done via a graphical interface using phpmyadmin or mysql-admin.

To install one or both of them, first enable the universe repository

Use any method to install

phpmyadmin

=== Troubleshooting Phpmyadmin & mysql-admin=== If you get blowfish_secret error: Choose and set a phrase for cryptography in the file /var/lib/phpmyadmin/blowfish_secret.inc.php (??? /etc/phpmyadmin/blowfish_secret.inc.php ???) and copy the line (not the php tags) into the file /etc/phpmyadmin/config.inc.php or you will receive an error.

Alternative: install phpMyAdmin from source

See the phpMyAdmin page for instructions on how to install phpmyadmin from source:

Mysql-admin

Mysql-admin runs locally, on the desktop. Use any method to install

mysql-admin

For more information

You really ought to read 2.9.3. Securing the Initial MySQL Accounts from the MySQL Reference Manual.

Edit Apache Configuration

You may want your current user to be the PHP pages administrator. To do so, edit the Apache configuration file :

$ gksudo "gedit /etc/apache2/apache2.conf"

Search both the strings starting by "User" and "Group", and change the names by the current username and groupname you are using. Then you'll need to restart Apache. (look at the next chapter concerning apache commands)

Configuration options relating specifically to user websites (accessed through localhost/~username) are in /etc/apache2/mods-enabled/userdir.conf.

Edit PHP Configuration to Work With MYSQL (Ubuntu Dapper)

In Dapper Drake, "extension=mysql.so" and "extension=mysqli.so" are enabled in the php.ini file out-of-the-box. However, sometimes php is not looking for those files in the right directory. You have then to move your files or modify the php.ini configuration.:

First solution

locate the directory where the extension files are placed:

locate mysql.so

(change mysql.so in mysqli.so if you want to install the mysqli functions)

-then modify the php.ini file to indicate the right place for the extension directory:

$ gksudo "gedit /etc/php4/apache2/php.ini"

or if you are using php5

$ gksudo "gedit /etc/php5/apache2/php.ini"

Look for the 'extension_dir' property, and set it to the directory where you found the mysql(i).so file:

  • extension_dir= "/usr/lib/php5/20051025/"

Restart apache, and test if your mysql(i) functions are working.

Second solution

-locate the directory where the extension files are placed:

locate mysql.so

(change mysql.so in mysqli.so if you want to install the mysqli functions)

Let's say that you found the file in '/usr/lib/php5/20051025/'

-then check in the php.ini file for the extension directory

$ gksudo "gedit /etc/php4/apache2/php.ini"

or if you are using php5

$ gksudo "gedit /etc/php5/apache2/php.ini"

Look for the 'extension_dir' property. It should be by default '/usr/lib/php5/ext'. If it's not, change it for this value.

-Now create the default directory for extensions:

$ sudo mkdir /usr/lib/php5/ext

-Copy the extension file to the new directory:

$ sudo cp /usr/lib/php5/20051025/mysql.so /usr/lib/php5/ext/mysql.so

Change the first path to the one you found with the locate function, and change mysql.so into mysqli.so if you want to use mysqli functions.

-Restart apache (see below), and test if your mysql(i) functions are working.

Run, Stop, Test, And Restart Apache

Use the following command to run Apache :

$ sudo /usr/sbin/apache2ctl start

To stop it, use :

$ sudo /usr/sbin/apache2ctl stop

To test configuration changes, use :

$ sudo /usr/sbin/apache2ctl configtest

Finally, to restart it, run :

$ sudo /usr/sbin/apache2ctl restart

Using Apache

You can access apache by typing 127.0.0.1 or http://localhost (by default it will be listening on port 80) in your browser address bar. By default the directory for apache server pages is /var/www . It needs root access in order to put files in. A way to do it is just starting the file browser as root in a terminal:

$ sudo nautilus

or

if you want to make /var/www your own. (Use only for non-production web servers - this is not the most secure way to do things.)

$ sudo chown -R $USER:$USER /var/www

Status

To check the status of your PHP installation:

 $ gksudo "gedit /var/www/testphp.php"

and insert the following line

 

View this page on a web browser at http://yourserveripaddress/testphp.php or http://localhost/testphp.php

Securing Apache

If you just want to run your Apache install as a development server and want to prevent it from listening for incoming connection attempts, this is easy to do.

$ gksudo "gedit /etc/apache2/ports.conf"
$ password:

Change ports.conf so that it contains:

Listen 127.0.0.1:80

Save this file, and restart Apache (see above). Now Apache will serve only to your home domain, http://127.0.0.1 or http://localhost.

Password-Protect a Directory

There are 2 ways to password-protect a specific directory. The recommended way involves editing /etc/apache2/apache2.conf . (To do this, you need root access). The other way involves editing a .htaccess file in the directory to be protected. (To do this, you need access to that directory).

Password-Protect a Directory With .htaccess

See EnablingUseOfApacheHtaccessFiles

Warning: On at least some versions of Ubuntu, .htaccess files will not work by default. See EnablingUseOfApacheHtaccessFiles for help on enabling them.

thumbnails

If you direct your web browser to a directory (rather than a specific file), and there is no "index.html" file in that directory, Apache will generate an index file on-the-fly listing all the files and folders in that directory. Each folder has a little icon of a folder next to it.

To put a thumbnail of that specific image (rather than the generic "image icon") next to each image file (.jpg, .png, etc.):

... todo: add instructions on how to do thumbnails here, perhaps using Apache::AutoIndex 0.08 or Apache::Album 0.95 ...

Known problems

Skype incompatibility

Skype uses port 80 for incoming calls, and thus, may block Apache. The solution is to change the port in one of the applications. Usually, port 81 is free and works fine. To change the port number in Skype go to menu Tools > Options, then click on the Advanced tab, then in the box of the port for incoming calls write your preference.

Other Apache Options

Further Information

Wednesday, August 20, 2008

Remote Desktop for Linux - Reloaded : lxpages.com blog

Remote Desktop for Linux - Reloaded : lxpages.com blog:

My first article on remote desktop became popluar among Linux users
and some Windows people as well. I received many comments on what I had missed from the short list I had compiled. Therefore, I’ve written this updated article that contains additional remote desktop apps that can be used for Linux to Linux / Windows to Linux and also Windows to Mac and Mac to Windows.

Linux to Linux

1) VNC (Virtual Network Computing) is a remote display system which
allows the user to view the desktop of a remote machine anywhere on
the internet. It can also be directed through SSH for security. There
are 3 types of VNC, they are:

1. http://www.realvnc.com/download.html
2. http://www.tightvnc.com/download.html
3. http://www.uvnc.com/

While you’re at it, get VNC Scan from (http://www.vncscan.com/) - a popular Network Administration tool that allows you to remotely manage all of your desktops and servers from a single location.

2) FreeNX is a system that allows you to access your desktop from
another machine over the internet. Some helpful links on how to
install:

1. https://help.ubuntu.com/community/FreeNX
2. http://ubuntuforums.org/showthread.php?t=97277&highlight=freenx
3. http://freenx.berlios.de/ (FreeNX homepage)

3) The third free application is 2X Terminal Server for Linux.

1. Download at http://www.2x.com/terminalserver/download.htm
2. Forum is at http://www.2x.com/forums

4) XDMCP. The original way of doing this on Linux. This link will
help get you started:

1. http://www.tldp.org/HOWTO/XDMCP-HOWTO/intro.html

5) CygwinX. A complete Linux emulation on Windows. You’ll find every
tool and app that you have on Linux on Cygwin.

Get it from http://www.cygwin.com/

6) XRDP. RDP server that runs on Linux, thus allowing you to use
Windows Remote Desktop Client or rdesktop to connect.

Get it from http://sourceforge.net/projects/xrdp/

7) x2vnc - great little utility that allows you to tie a linux and windows (or anything that can run the vncserver) together with a ingle keyboard/mouse, avoiding the need for a switcher box. Mousing cross screens transparently switches between machines, and cut and aste works.

Get it from http://fredrik.hubbe.net/x2vnc.html

8 ) Xming - t’s a great and lightweight implementation of X11 for
Windows that allows you to connect to a Linux box. You can read about
it at http://freedesktop.org/wiki/Xming

9) KDE Desktop Sharing (formerly krfb) - part of KDE since version 3.1. It is located in the kdenetwork package. If your distribution splits the KDE applications into separate packets, you may find the client as ‘krdc’ and the server as ‘krfb’. Also uses VNC technology.

10) X-Win32 - Top rated PC X server solutions for Windows PCs connecting to remote Unix and Linux host systems. Works well over SSH.

Get it from http://www.starnet.com/products/xwin32/

11) Single Click UltraVNC - In case you would like to remote control without any software installed on the target computer you need UltraVNC SC. The user on the to be controlled computer needs to simply click on a web page and remote controlling begins.

Get it from here http://ultravnc.sourceforge.net/addons/singleclick.html

12) CrossLoop - CrossLoop is a FREE secure screen sharing utility designed for people of all technical skill levels. CrossLoop extends the boundaries of VNC’s traditional screen sharing by enabling non-technical users to get connected from anywhere on the Internet in seconds without changing any firewall or router settings.

Get it from http://www.crossloop.com/


13) Thinstation - Although not a remote desktop app but worth mentioning here. Thin client linux distro for terminals using std. x86 hw. It can boot from network, pxe, syslinux,loadlin, CD, floppy or flash-disk and connect to servers using VNC, RDP, XDM, SSH and etc.

Get it from http://sourceforge.net/projects/thinstation/

14) rdesktop - an open source client for Windows NT Terminal Server and Windows 2000/2003 Terminal Services, capable of natively speaking Remote Desktop Protocol (RDP) in order to present the user’s NT desktop. rdesktop currently runs on most UNIX based platforms with the X Window System, and other ports should be fairly straightforward.

Download from: http://www.rdesktop.org/

While you’re at it, get grdesktop from (http://www.nongnu.org/grdesktop/). It is a GNOME frontend, for rdesktop. It can save several connections (including their options), and browse the network for available terminal servers.

15) ssh -X - You can check out this great article written by a slashdot user sometime ago.

Read it here http://slashdot.org/~Trolling4Dollars/journal/69740

Windows to Mac / Mac to Windows

1) RDP Client for Mac allows you to connect to a Windows-based computer and work with programs and files on that computer from your Macintosh computer.

Download it here

2) OSXVnc - Vine Server is a full featured VNC server for Mac OS X providing remote access to the GUI, keyboard and mouse using Vine Viewer or any other VNC client.

Download it from http://www.redstonesoftware.com/products/vine/server/vineosx/index.html

3) Chicken of the VNC - A VNC client allows one to display and interact with a remote computer screen. In other words, you can use Chicken of the VNC to interact with a remote computer as though it’s right next to you.

Download it from http://sourceforge.net/projects/cotvnc/

Unfortunately I was not able to find too many available to connect to Mac from Windows other than VNC. I think Windows need to support RDP into Mac. Many people would benefit from this.

If I am missing anything from the list, please let me know.

Monday, August 18, 2008

Visual Studio 2008 Is Pretty Damn Slow… « Williamo’s Blog.

Visual Studio 2008 Is Pretty Damn Slow… « Williamo’s Blog.

Update: The speed issues I complained about in the original version of this post have been remedied (as far as I can tell) by “Hotfix for Microsoft Visual Studio 2008 - KB946581″ which you can find here: Downloadable Hotfix: Performance and Editor fixes for Microsoft Visual Studio 2008 and Visual Web Developer Express 2008. Thanks to David and Cameron from Microsoft for helping me out with this!

If you’d like to read the original post, you can find it below, but keep in mind that most of this rant is now moot. Enjoy! ;-)


Disclaimer: I will *happily* post a retraction to this rant if *anyone* can tell me how to make Visual Studio 2008 perform like Visual Studio 2005 did, or better. My intention here is not to offend (despite the title of this post) but to pique some interest in the community as to how to speed up this beast of a program.I’m a software engineer for a web development company, developing code in C# and ASP.NET. Thus, the tool I use most in my daily work, of course, is Visual Studio. I’ve been happily using Visual Studio 2005, well, since 2005, and have enjoyed it thoroughly. Everything it does (for me), it does well, from IntelliSense to the integration with source control. So, when my company decided to upgrade all its developers’ copies of Visual Studio 2005 to Visual Studio 2008, I had no reservations. I’d heard about things like better JavaScript handling (with IntelliSense as well), split Design/Code view in Web Developer, and, well, it just looked slicker than 2005 in general.

Now, less than a couple months after our upgrade, I use a text editor (Notepad2, for what it’s worth) almost exclusively for writing and modifying code. Why? Because Visual Studio 2008 is slow, unwieldy, slow, memory hogging and *really damn slow*.

More...

Visual Studio 2008 (Not Responding)

(I see this the majority of the time Visual Studio is open.)

I have tried everything I can possibly think of to wrestle with this beast. Cleaned my hard drive, reinstalled Windows XP, installed VS2008, removed all components but Web Developer and C#/ASP.net (no C++, VB, mobile development tools, etc.). Before you ask, my development machine has the following specs:

  • Intel Centrino (Core Duo T2300) @ 1.66GHz
  • 2GB of DDR2-667 RAM
  • 80GB SATA2 Hard Drive

Not the fastest machine on the block, but it should be more than sufficient to do web development. Typically, when I’m doing web development, I have four programs open: Outlook, Visual Studio, Firefox and Internet Explorer. Even with only these four programs open and only two tabs open in each browser, I see the (Not Responding) message in Visual Studio’s title bar more often than not.

Loading the environment takes anywhere from 30 seconds (fast) to two minutes (most of the time). Closing the program takes about the same amount of time. Opening a C# source code file takes 15-20 seconds, with the hourglass spinning and most of the time the window won’t repaint at all during this time. If I make the rare mistake of attempting to click into “Design” mode when viewing an ASPX page, my whole system locks up. No response from any windows, and even Ctrl+Alt+Delete takes 5-10 seconds to slowly paint the dialog with its options.

Possibly the most disappointing part of all this is the fact that Visual Studio 2008 was touted for its speed increases.

So, to wrap this up, if you have some good tips or tricks for (drastically) speeding up the performance of Visual Studio 2008, please leave a comment on this post. I’d love to hear from you, and I’m sure a lot of other Visual Studio 2008 users would love to hear from you as well.

Posted by willwm Filed in Uncategorized

Ez-12 Parabolic Reflector Template

http://www.freeantennas.com/projects/template2/index.html

Ez-12 Parabolic Reflector Template

Implementation Image
  1. Download Template
  2. Open in MS Paint and resize as desired. Ensure that you keep the square on the diagram square.
  3. Print image on business card stock or acetate (document protector).
  4. Cut it out and open the six slots with sissors or an X-Acto knife.
  5. Glue tin foil to the back side of the reflector surface
  6. Assemble by placing the six tabs in the six slots.

Tell a friend about this idea.
Note: If printed at the download size you will see about 9 dBi of gain. If you double the size of the image before you print it you will see about 12 dBi of gain. If you place two reflectors on an AP with two antennas you will see an additional increase in performance.

Pattern Plot for Dipole Reflector Vertical Plane Plot
Six inch reflector pattern at 2.4 GHz

Revised Ez-12 Template

Friday, August 15, 2008

Grass trimmer maintain and repair

To start a cold engine:
1. Place the on/off switch in the ON position.
2. Slowly press the primer bulb seven times.
3. Rotate the choke dial clockwise to the FULL CHOKE position.
4. While squeezing both the trigger lock and throttle trigger, push in the throttle lock button.
Release the throttle trigger. This latches the trigger for starting.
5. Pull the starter grip sharply until engine attempts to run (no more than 4 pulls).
6. Rotate the choke dial to the counterclockwise HALF CHOKE position.
7. Pull the starter grip sharply until the engine runs.
8. Allow the engine to run for 10 seconds.
9. Rotate the choke dial counterclockwise to the RUN position.
10. Squeeze the trigger to disengage the throttle lock and return the engine to idle.

PREMIUM EXACT MIX (50:1) 1 gallon gas (US) / 2.6 oz oil, or 1 Liter gas /20 mL oil

Usage
You should change the gas/oil mixture and replace it with new stuff if you did not already do so. Insure the choke is set to full choke when you start a cold machine. Move the choke to full opened after the machine has warmed up. If you machine has a primer bulb, usually a small plastic type button, push it at least 8 times before you attempt to start it. Try a few pulls with choke on - then try a few with choke open, keep the throttle fully open and pull the starter cord. If it doesn't fire, spray a little starter fluid into the air inlet and repeat the above sequence. You can get the starter fluid spray at a 'box' store or auto parts store. If it starts, let it run for about 30 seconds and then gently release the throttle and and then adjust the choke to the off position, as they are very temperamental, and just need a bit of coaxing.

Repair
All these small 2 stroke engines are difficult to start if the fuel-air mix is not right and they are prone to over choking.

If the engine is not running, the cause can be poor spark, lack of fuel or air delivered to cylinder, or some sort of mechanical failure such as low compression. Check the easy stuff first, i.e. fresh fuel mix in tank; on/off switch on; air filter reasonably clean.

1. Check the fuel system to ensure it is ok and no blocked filters etc. Clean out the fuel tank and put some fresh fuel in it.
2. Air filters. Ensure they are clean and allow unrestricted airflow into the carb.
3. Spark Plugs. Take out the spark plug, clean and dry it, if you know the plug gap check that it's right, if you don't know the gap and it hasn't been altered leave it as it is, If the plug looks anything less than perfect replace it.
If the plug is wet with fuel, dry the plug and do a few pulls before reinstalling the plug (keep spark plug wire away from the open hole). Reinstall the spark plug and try the above again.
Check for spark by taking it out, putting it back in the boot and grounding the threads to the head and watch for a blue snap.
4. I will agree that clean plug and air filter are necessary for superior running condition. However, the two most common problems that I encounter in 2 cycle products is carboned up anti spark screens/exhaust ports and varnished up in tank fuel filters. If, after checking the above four items, try adjusting the high and low speed screws counter clowckwise half a turn if the carb has them. If adjustment doesn't help I rebuild the carb. If no adjustment screws are present, the diagphram pump in the carb is likely hard and not capable of pumping proper fuel.
5. If at any point in this process it fires but won't run - the carburetor is probably dirty/gummed up etc. This can be caused by using old fuel. If this is the case, spray some carb cleaner into the air intake after you removed the air filter.
6. If the above does not fix the problem adjust the jets in the carburettor. It is possible that with all this pollution stuff happening that the formulation of the fuel you are using has changed causing the unit to change tune.

Repeat above sequence.

change the plug and air cleaner don't use starting fluid in a two stroke engine their is no oil in it and you could cause piston/ring/cylinder damage.

http://forum.doityourself.com/showthread.php?t=270292
Seatech:
Hi, all. I'm looking for some help with my trimmer. I bought a Homelite String Trimmer (UT20699) at a garage sale ($5 woohoo!). The kicker is that it won't start. When I got it home, I noticed that the 2 fuel lines were out of the tank, so I got new lines and a new filter (I think I have them going to the right lines on the carb as there is fuel showing up in the primer bulb). But the trimmer won't start. It doesn't really sound like it's trying to catch. First I tried spraying a little starter fluid in the carb and then a little in the spark plug hole but it won't go. I checked the plug and it's all black on the tip (not sure if that counts as fouled or not). Also, I noticed that when I pull the throttle trigger the throttle on the carb isn't moving....seems to be stuck but I was able to movie with a screw driver. Anyway, I'm pretty much a complete newb when it comes to anything mechanical so any help or advice you can offer is definitely appreciated.

v8driver:
You need to buy a carb kit for that particular carb, tear the carb apart and soak it in carb cleaner and blow it out through any and all holes real good. Sounds like the throttle cable might be broken if you could move the butterfly on the carb with ease. And of course you could have a fouled spark plug but check for spark by taking it out, putting it back in the boot and grounding the threads to the head and watch for a blue snap. Nothing? remove the kill wire..... still nothing then a new coil...
Also you should check the cylinder and piston through either the spark plug hole or exhaust port for scoring.... any scoring, probabally will have too low of compression to even start, and a new cylinder, piston and rings will need to be bought... not really worth it either. A 2 cycle like a trimmer, under 90 psi of compression is bad, even at 90 it'll be hard to start, over is good.

Seatech:
Thanks for the response, V8.
To check for spark, when you say to ground the threads of the spark plug to the head, do you just run a wire from the threads to the engine block or to the tip of the spark plug? Also, after it's grounded properly I assume I just pull the cord and see if there is spark, right? Sorry, I'm really a complete novice when it comes to all of this, so sorry for my ignorance.
Also, I can move the butterfly but it doesn't move easily at all. When I pull the trigger, the cable does seem to be moving but the butterfly seems to be stuck, so I'm guessing it needs to be cleaned?

cheese:
It can be hard to ground a plug on some trimmers with all the plastic they have on them. Sometimes I wedge a screwdriver next to the cylinder, and lay the plug on it in such a way so that the metal on the plug is touching the metal on the screwdriver, and the screwdriver is touching metal on the engine. You can use your wire method too, or whatever it takes. Sounds like the carb does need cleaning.

Seatech:
I got it started!!!!! woohoo!
Ok, so after reading your tips on checking for spark, I went home after work and pulled the plug out and for the ground I cut the cord off an old charger for a cell phone I no longer have and taped the wire to the threads on the spark plug and then to the engine. I got spark, and it looked good and blue, so I put the plug back in and took the muffler off and cleaned the screen.

I put it all back together, closed the choke, completely and gave it 6 or 7 pulls on the cord. Switched the choke to the next step open and pulled again...and it started! (kinda scared me actually. lol)
So, thanks for all of your help. Gotta love the internet!

I do still have a problem with the throttle not moving by itself. It's basically stuck wide open. I can move it with a screw driver, but it's not easy at all. Any tips on getting that working besides liberal use of wd-40 or some other lubricant?

v8driver:
You still need to clean the carb..... sounds right now that the butterfly is stuck in place maybe by gummy gas. Or the shaft is broken on it and its rubbing (unlikely but possible).

Sunday, August 10, 2008

Install VirtualBox Additions for an Ubuntu 8.04 Guest | Tombuntu

Install VirtualBox Additions for an Ubuntu 8.04 Guest | Tombuntu

First you must install VirtualBox guest addition then you simply need to edit this file :
sudo gedit /etc/X11/xorg.conf
Then you make something equivalent to this :
Section "InputDevice"
Identifier "Configured Mouse"
Driver "vboxmouse" <-- this important for Ubuntu 8.04
Option "CorePointer"
EndSection

Section "Device"
Identifier "Configured Video Device"
Driver "vboxvideo" <-- this is important for Ubuntu 8.04
EndSection

Section "Monitor"
Identifier "Configured Monitor"
EndSection

Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
Device "Configured Video Device"
DefaultDepth 24
SubSection "Display"
Modes "1280x1024" "1024x768" "800x600" "640x480" <-- add the resolution you want
EndSubSection
EndSection

Then save and exit.
Then go in system/preference/screen resolution and select the good one.
That's all.

Have a nice day

如何发掘出更多退休的钱?

如何发掘出更多退休的钱? http://bbs.wenxuecity.com/bbs/tzlc/1328415.html 按照常规的说法,退休的收入必须得有退休前的80%,或者是4% withdrawal rule,而且每年还得要加2-3%对付通胀,这是一个很大...