User:Knappy162

Hi. This is where I ramble on ... Note: There might be quotes or help from Phil

Useful Commands

 * Change to bash shell
 * Problem: In my new Ubuntu machine, the file name tab autocomplete doesn't work, up arrows for previous commands gives "^[[A", and .bashrc's change of prompt color doesn't do anything.
 * Check the current shell
 * Open up a new terminal and see the result!
 * Check previous command success or not
 * Result: "0" is good, "1" is bad.
 * Result: "0" is good, "1" is bad.
 * Result: "0" is good, "1" is bad.

Setting Up a LAMP Server
05-27-2010

Instructions with pictures.

Here are what I did, slightly modified from the instructions above.
 * 1) ssh-ed into my Ubuntu virtual machine with a fixed public IP address.
 * 2) * Test it at http://your-external-ip-address or or http://localhost
 * 3) ** If localhost and 127.0.0.1 works but not the extrenal-ip, then you might have to play with your router:
 * Phil: The issue is that your machine is behind an address-translating router that's acting as a firewall. This wouldn't be a problem when you have you're at school (since [your school] assigns publicly-routable IP addresses and doesn't firewall connections). At home, though, you'd need to configure your wireless router to send inbound packets to a particular translated IP address (the 10.0.0.0/8, 172.16.0.0/12, or 192.168.0.0/16 address assigned to your machine internally). You'd also probably need to choose an inbound port other than the HTTP port (80) since your home service provider is almost certainly filtering that port to make it harder for people to run servers at home.
 * 1)   and write in
 * 2) * Note: you can use another editor
 * 3) * You may get this response:
 * * Restarting web server apache2
 * apache2: Could not reliably determine the server's fully qualified domain name, using 10.82.1.18 for ServerName
 * ... waiting apache2: Could not reliably determine the server's fully qualified domain name, using 10.82.1.18 for ServerName
 * ...done.
 * If you have your own IP, i.e. your IP is not shared with other web sites, you can ignore this message, or else the web sites rely on the browser to indicate which site they're accessing by a "Hostname" header message.
 * 1) * Test it at http://your-external-ip-address/testing.php or or http://localhost/testing.php
 * 2) Configure MySQL:   and change
 * 3) * Get your internal-ip from:
 * 4) * Verifying it works:
 * (the root password was set up during the first step).
 * 1) Install phpMyAdmin:
 * 2) * Verify it here: http://your-external-ip-address/phpmyadmin
 * 3) * If you're lucky, it worked, if not (get "Not Found" error) go through the next section
 * 1) * Verify it here: http://your-external-ip-address/phpmyadmin
 * 2) * If you're lucky, it worked, if not (get "Not Found" error) go through the next section

Fixing phpmyadmin "Not Found" Issue
From this Guide Note: check after every step if http://your-external-ip-address/phpmyadmin or http://localhost/phpmyadmin works or not. If not, continue.
 * 1) In "/etc/apache2/apache2.conf" add in the line:
 * 2) Maybe you didn't select "Apache2" during installation, so reinstall:
 * 3) Writing a symbolic link from space in web site to where phpmyadmin is set up:

Giving Privilege to User
Problem: During the LAMP setup process, I created a root user and a non-root user. However, the non-root user didn't have privileges to add databases. To give the non-root user privileges: Other helpful commands:
 * 1) mysql>
 * 1) mysql>
 * Show users:
 * mysql>
 * See a user's privileges:
 * mysql>

CakePHP

 * http://bin.cakephp.org/

Setting Up
Smallest Tutorial
 * If you see on the top of your cakephp homepage:
 * Warning (512): /var/www/cakephp/app/tmp/cache/ is not writable [CORE/cake/libs/cache/file.php, line 263]
 * Warning (512): /var/www/cakephp/app/tmp/cache/persistent/ is not writable [CORE/cake/libs/cache/file.php, line 263]
 * Warning (512): /var/www/cakephp/app/tmp/cache/models/ is not writable [CORE/cake/libs/cache/file.php, line 263]
 * Solution:
 * Solution: