INSTALL MYSQL SERVER Ubuntu

Here it is a basic command to install MySQL on your server. First thing first, if you disabled root login following our previous guide, then execute this command first. Otherwise you don’t need to..
1. sudo su
You may also need to update and upgrade apt if you didn’t do it yet.
1. apt-get update
2. apt-get upgrade
Then here it is the main command to install MySQL:
1. apt-get install mysql-server

install mysql

If you are using Apache2 and PHP5, you can also use following command instead of default one above:
1. apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql
If you are using another webserver you can also try to also install MySQL Tuner mod but obviously you’ll need to adjust some settings.
1. apt-get install mysql-server mysqltuner
Once you’ve executed one of above commands, you’ll be asked to enter / define password for user root. Enter the password twice.

If MySQL didn’t ask to enter password. What should I do?
A: You can run another command to enter new password


1. mysqladmin -u root password new_password

change “new_password” with your own password.

Step-by-Step guide for Installing MySQL on Windows

You can download the MySQL database from the MySQL website http://www.mysql.com by clicking on the downloads tab. Scroll down to the MySQL database server & standard clients section and select the latest production release of MySQL, 5.1.35 at the time of writing. 

Installation of MySQL Server


Unzip the setup file and execute the downloaded MSI file. Follow the instructions below exactly when installing MySQL Server:
 

 
Click on the "setup" 




Perform a typical installation







 



Check box to configure MySQL Server 

If you checked the Configure the MySQL Server now check box on the final dialog of the MySQL
Server installation, then the MySQL Server Instance Configuration Wizard will automatically start.
Follow the instructions below carefully to configure your MySQL Server to run correctly with
EventSentry. 



Select Detailed Configuration


 
I was installing it on my local machine where other applications & tools are running I decided to opt "developer machine" but it is recommended that you use a Dedicated MySQL Server Machine for your MySQL database, if this is not an option then select "Server Machine". 

If you selected Dedicated MySQL Server Machine and your MySQL service does not start after the wizard completes, then try to re-run the wizard (or re-install) MySQL, but this time select the Server Machine option. 


 
I have checked "Multifunctional databases" as I wanted MyISAM as default storage engine but if you want you can select "Transactional Database Only", this will make sure that InnoDB is the main storage engine. If you have checked 3rd option then only myISAM engine would be available 



Select the drive where the database files will be stored.
Select the drive on the fastest drive(s) on your server







It is recommended that you leave the default port 3306 in place, however
EventSentry will also work with non-standard ports if necessary.







It is highly recommended that you run the MySQL Server as a Windows
service(you can disable this if you want to start it manually whenever required) and include the binary directory in the search path.


Specify a secure root password, you may want to check the box Enable root access
from remote machines if you plan on administering your MySQL server
from your workstation or other servers.
If you are getting an error message after clicking the Next button, then please enable port 3306
in the Windows XP Firewall Settings 



 


vi Editor Commands

General Startup
To use vi: vi filename
To exit vi and save changes: ZZ   or  :wq
To exit vi without saving changes: :q!
To enter vi command mode: [esc]


Counts
        A number preceding any vi command tells vi to repeat
that command that many times.




Cursor Movement

h       move left (backspace)

j       move down

k       move up

l       move right (spacebar)

[return]   move to the beginning of the next line

$       last column on the current line

0       move cursor to the first column on the 
current line

^       move cursor to first nonblank column on the
current line

w       move to the beginning of the next word or 
punctuation mark

W       move past the next space

b       move to the beginning of the previous word 
or punctuation mark

B       move to the beginning of the previous word,
ignores punctuation

        e       end of next word or punctuation mark

        E       end of next word, ignoring punctuation

        H       move cursor to the top of the screen 

        M       move cursor to the middle of the screen

        L       move cursor to the bottom of the screen 


Screen Movement

       G        move to the last line in the file

       xG       move to line x

       z+       move current line to top of screen

       z        move current line to the middle of screen

       z-       move current line to the bottom of screen

       ^F       move forward one screen

       ^B       move backward one line

       ^D       move forward one half screen

       ^U       move backward one half screen

       ^R       redraw screen 
( does not work with VT100 type terminals )

       ^L       redraw screen 
( does not work with Televideo terminals )

Inserting

       r        replace character under cursor with next 
character typed

       R        keep replacing character until [esc] is hit

       i        insert before cursor

       a        append after cursor

       A        append at end of line

       O        open line above cursor and enter append mode

Deleting

x       delete character under cursor

dd      delete line under cursor

        dw      delete word under cursor

        db      delete word before cursor


Copying Code

        yy      (yank)'copies' line which may then be put by
the p(put) command. Precede with a count for
multiple lines.


Put Command
        brings back previous deletion or yank of lines,
words, or characters

        P       bring back before cursor

        p       bring back after cursor


 Find Commands

?       finds a word going backwards

/       finds a word going forwards

        f       finds a character on the line under the
cursor going forward

        F       finds a character on the line under the
cursor going backwards

        t       find a character on the current line going
forward and stop one character before it

T       find a character on the current line going
backward and stop one character before it

; repeat last f, F, t, T


Miscellaneous Commands

. repeat last command

u undoes last command issued

U undoes all commands on one line

xp deletes first character and inserts after
second (swap)

J join current line with the next line

^G display current line number

% if at one parenthesis, will jump to its mate

mx mark current line with character x

'x find line marked with character x

NOTE: Marks are internal and not written to the file.


Line Editor Mode
Any commands form the line editor ex can be issued 
upon entering line mode.

To enter: type ':'

To exit: press[return] or [esc]


ex Commands
For a complete list consult the 
UNIX Programmer's Manual


READING FILES
copies (reads) filename after cursor in file 
currently editing

:r filename


WRITE FILE

:w saves the current file without quitting


MOVING

:# move to line #

:$ move to last line of file


SHELL ESCAPE
executes 'cmd' as a shell command.

:!'cmd'

Useful Shortcut Keys In Ubuntu

Here is a long list of keyboard shortcuts for Ubuntu. 

General keyboard shortcuts


Ctrl + A = Select all
Ctrl + C = Copy the highlighted content to clipboard
Ctrl + V = Paste the clipboard content
Ctrl + N = New (Create a new document, not in terminal)
Ctrl + O = Open a document
Ctrl + S = Save the current document
Ctrl + P = Print the current document
Ctrl + W = Close the close document
Ctrl + Q = Quit the current application

Keyboard shortcuts for GNOME desktop


Ctrl + Alt + F1 = Switch to the first virtual terminal
Ctrl + Alt + F2(F3)(F4)(F5)(F6) = Select the different virtual terminals
Ctrl + Alt + F7 = Restore back to the current terminal session with X
Ctrl + Alt + Backspace = Restart GNOME
Alt + Tab = Switch between open programs
Ctrl + Alt + L = Lock the screen.
Alt + F1 = opens the Applications menu
Alt + F2 = opens the Run Application dialog box.
Alt + F3 = opens the Deskbar Applet
Alt + F4 = closes the current window.
Alt + F5 = unmaximizes the current window.
Alt + F7 = move the current window
Alt + F8 = resizes the current window.
Alt + F9 = minimizes the current window.
Alt + F10 =  maximizes the current window.
Alt + Space = opens the window menu.
Ctrl + Alt + + = Switch to next X resolution
Ctrl + Alt + - = Switch to previous X resolution
Ctrl + Alt + Left/Right = move to the next/previous workspace

Keyboard shortcuts for Terminal


Ctrl + A = Move cursor to beginning of line
Ctrl + E = Move cursor to end of line
Ctrl + C = kills the current process.
Ctrl + Z = sends the current process to the background.
Ctrl + D = logs you out.
Ctrl + R = finds the last command matching the entered letters.
Enter a letter, followed by Tab + Tab = lists the available commands beginning with those letters.
Ctrl + U = deletes the current line.
Ctrl + K = deletes the command from the cursor right.
Ctrl + W = deletes the word before the cursor.
Ctrl + L = clears the terminal output
Shift + Ctrl + C = copy the highlighted command to the clipboard.
Shift + Ctrl + V (or Shift + Insert) = pastes the contents of the clipboard.
Alt + F = moves forward one word.
Alt + B = moves backward one word.
Arrow Up/Down = browse command history
Shift + PageUp / PageDown = Scroll terminal output

Keyboard shortcuts for Compiz


Alt + Tab = switch between open windows
Win + Tab = switch between open windows with Shift Switcher or Ring Switcher effect
Win + E = Expo, show all workspace
Ctrl + Alt + Down = Film Effect
Ctrl + Alt + Left mouse button = Rotate Desktop Cube
Alt + Shift + Up = Scale Windows
Ctrl + Alt + D = Show Desktop
Win + Left mouse button = take screenshot on selected area
Win + Mousewheel = Zoom In/Out
Alt + Mousewheel = Transparent Window
Alt + F8 = Resize Window
Alt + F7 = Move Window
Win + P = Add Helper
F9 = show widget layer
Shift + F9 = show water effects
Win + Shift + Left mouse button = Fire Effects
Win + Shift + C = Clear Fire Effects
Win + Left mouse button = Annotate: Draw
Win + 1 = Start annotation
Win + 3 = End annotation
Win + S = selects windows for grouping
Win + T = Group Windows together
Win + U = Ungroup Windows
Win + Left/Right = Flip Windows

Keyboard shortcut for Nautilus


Shift + Ctrl + N = Create New Folder
Ctrl + T = Delete selected file(s) to trash
Alt + ENTER = Show File/Folder Properties
Ctrl + 1 = Toggle View As Icons
Ctrl + 2 = Toggle View As List
Shift + Right = Open Directory (Only in List View)
Shift + Left = Close Directory (Only in List View)
Ctrl + S = Select Pattern
F2 = Rename File
Ctrl + A = Select all files and folders
Ctrl + W = Close Window
Ctrl + Shift + W = Close All Nautilus Windows
Ctrl + R = Reload Nautilus Window
Alt + Up = Open parent directory
Alt + Left = Back
Alt + Right = Forward
Alt + Home = go to Home folder
Ctrl + L = go to location bar
F9 = Show sidepane
Ctrl + H = Show Hidden Files
Ctrl + + = Zoom In
Ctrl + - = Zoom Out
Ctrl + 0 = Normal Size

How to move the mouse cursor with the keyboard in Windows

Shortcut in all versions of Windows


Press Left Alt + Left Shift + Num Lock on your keyboard at the same time. When the window appears, press Spacebar or Enter. Same process to turn Mouse Keys off.


Windows 7


If the shortcut key combination listed above did not work, you may enable or disable Mouse Keys, using the following steps. If your mouse isn't working, use the Tab key and Spacebar to navigate through menus.
While viewing the Desktop, press the Windows Key or Click Start.
Select Control Panel. Within the Control Panel, open Ease of Access.
Under Ease of Access Center, select Change how your mouse works.
Check the box next to Turn on Mouse Keys.
Select Apply then OK.

Windows 8 and 8.1


If the shortcut key combination listed above did not work, you may enable or disable Mouse Keys, using the following steps. 

Use the Tab key and Space bar to navigate through menus. 
Type the word "Mouse" anywhere on the Start Screen. 
Arrow down to Ease of Access mouse settings and press Enter. 
Toggle the switch under Mouse Keys to On.

Press Alt + F4 to exit this menu.


How to use Mouse Keys


The following table shows each of the keys on the Numeric Keypad and how they interact with the mouse cursor. Make sure you're only using the Keypad to execute these actions.


Desired Action and Key Combination



Move down and to the left Press 1

Move down Press 2

Move down and to the right Press 3

Click With the left button selected, press 5

Move up and to the left Press 7

Move up Press 8

Move up and to the right Press 9

Move left Press 4

Move right Press 6

Select the left mouse button Press /

Select both of the mouse buttons Press *

Select the right mouse button Press -

Right-click With the right button selected, press 5

Double-click With the left button selected, press +

Drag an item Point to the item, and then press 0

Drop the item you are dragging Press .(dot)

Keyboard shortcuts for chrome, Firefox, IE, Safari

There are hundreds of keyboard shortcuts out there, but these 7 are the ones you'll definitely want to remember. I use them every day, and you should too.

Tab Domination

Numbered Tabs

If you have multiple tabs, you can access the one you want to open using the numbers on the keyboard. In all the major browsers (Internet Explorer, Firefox, Chrome, and Safari), simply press:

Ctrl + (1-9) on a Windows PC
Command + (1-9) on a Mac

This is particularly useful for going back and forth between a few specific tabs. One minor issue I did notice is that switching between tabs 1-8 works flawlessly, but Control/Command + 9 automatically takes you to the last tab, regardless of the tabs actual number. If you have more than 8 tabs, you won't be able to access some of them using this shortcut.


Tab Your Tabs

Ctrl + Tab on Mac or Windows PC
So, if you have 5 tabs open and are currently viewing tab 3, this shortcut will take you to tab 4, and so on. You can also use the following shortcuts, which do the same thing.

Control + Page Up/Page Down on a Windows PC
FN + Control + Up/Down Arrows on a Mac
These work in all the major browsers except for IE.


Close Tabs

There have been so many times when I have enough tabs open that they're tightly bunched together, and I end up closing the wrong one. Doesn't sound like that big a deal, but when it keeps happening over and over, it's insanely annoying. Here's a shortcut I wish I'd found sooner.


Just select the tab you want to close, then press:

Control + W on a Windows PC
Command + W on a Mac
It's that simple.


Reopen Closed Tabs


Now, what about those accidentally closed tabs? Instead of retyping the website address or going through your history, you can use a quick shortcut to reopen recently closed tabs. Just press:

Control + Shift + T on a Windows PC
Command + Shift + T on a Mac
You don't even have to open a new tab—it will reopen in a new tab on its own. This shortcut works for all the majors browsers and allows you to reopen your last 10 closed tabs. Money, I know.


Jump to Browse

Anything that can save me from using my mouse or track pad is a plus. My track pad is just wretched, and using a mouse for too long really starts to hurt my wrist, so the more keyboard shortcuts the merrier.

Pressing Control/Command + L in Chrome, Firefox, Safari, and IE will automatically highlight the address bar, allowing you to enter in either a search query or a web address.

To automatically highlight the address bar in Chrome, Firefox, Safari, and IE, press:

Control + L or Alt + D on a Windows PC
Command + L on a Mac
This allows you to enter in either a search query or a web address.


Magnify


Control and the +/- key on a Windows PC
Command and the +/- key on a Mac
This is useful for websites with very fine print, or for those who have poor eyesight. Check out the before and after of our homepage:



Once you've zoomed in to whatever percentage is good for you, how do you get back to normal size? You can always zoom out until you think it's back to normal.

If you want to get the size right every time, just hit:

Control + 0 on a Windows PC
Command + 0 on a Mac
This will take you back to the standard size no matter how many times you've zoomed in and out.


Cache Override


If you're using Windows:

Firefox: Control + Shift + R
Chrome: Control + F5 or Shift + F5
Internet Explorer: Control + F5
Safari: Hold the Shift key and click the Refresh button on your toolbar

If you're using Mac:

Firefox: Command + Shift + R
Chrome: Command + R
Internet Explorer: FN + F5
Safari: Hold the Shift key and click the Refresh button on your toolbar

How to Use Windows 7 Without Activation

Using windows 7 using with out activation. 

Step-1: Go to Start Menu Right click on the “Command Prompt” and select “Run as Administrator“. If you are not the administrator, then you are prompted to enter the password.

Step-2: Now type the following command 

slmgr -rearm


Step-3: You will be prompted to restart the computer. Once restarted, the trial period will once again be reset to 30 days. You can use the above command for up to 3 times by which you can extend the trial period to 120 days without activation.

Step-4: You can extend the trial period for another 240 days. To do this, open the Registry Editor (type regedit in “Run” and hit Enter) and navigate to the following location:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform


Step-5: In the right-side, change value of SkipRearm to 1.

Step-6: Now, you should be able to use the slmgr -rearm command for another 8 times so that you can skip the activation process for another 240 days. So you will get 120 + 240 = 360 days of free Windows 7 usage.

120 days using “slmgr -rearm” command before registry edit

+

240 days using “slmgr -rearm” command after registry edit

=      360 Days