20110630

HTTP Status Codes for Beginners

Client Error
·         400 - Bad Request
a status code of 400 indicates that the server did not understand the request due to bad syntax.
·         401 - Unauthorized
A 401 status code indicates that before a resource can be accessed, the client must be authorized by the server.
·         402 - Payment Required
The 402 status code is not currently in use, being listed as "reserved for future use".
·         403 - Forbidden
A 403 status code indicates that the client cannot access the requested resource. That might mean that the wrong username and password were sent in the request, or that the permissions on the server do not allow what was being asked.
·         404 - Not found
the best known of them all, the 404 status code indicates that the requested resource was not found at the URL given, and the server has no idea how long for.
·         405 - Method Not Allowed
A 405 status code is returned when the client has tried to use a request method that the server does not allow. Request methods that are allowed should be sent with the response (common request methods are POST and GET).
·         406 - Not Acceptable
The 406 status code means that, although the server understood and processed the request, the response is of a form the client cannot understand. A client sends, as part of a request, headers indicating what types of data it can use, and a 406 error is returned when the response is of a type not i that list.
·         407 - Proxy Authentication Required
The 407 status code is very similar to the 401 status code, and means that the client must be authorized by the proxy before the request can proceed.
·         408 - Request Timeout
A 408 status code means that the client did not produce a request quickly enough. A server is set to only wait a certain amount of time for responses from clients, and a 408 status code indicates that time has passed.
·         409 - Conflict
a 409 status code indicates that the server was unable to complete the request, often because a file would need to be edited, created or deleted, and that file cannot be edited, created or deleted.
·         410 - Gone
a 410 status code is the 404's lesser known cousin. It indicates that a resource has permanently gone (a 404 status code gives no indication if a resource has give permanently or temporarily), and no new address is known for it.
·         411 - Length Required
The 411 status code occurs when a server refuses to process a request because a content length was not specified.
·         412 - Precondition Failed
A 412 status code indicates that one of the conditions the request was made under has failed.
·         413 - Request Entity Too Large
The 413 status code indicates that the request was larger than the server is able to handle, either due to physical constraints or to settings. Usually, this occurs when a file is sent using the POST method from a form, and the file is larger than the maximum size allowed in the server settings.
·         414 - Request-URI Too Long
The 414 status code indicates the URL requested by the client was longer than it can process.
·         415 - Unsupported Media Type
A 415 status code is returned by a server to indicate that part of the request was in an unsupported format.
·         416 - Requested Range Not Satisfied
A 416 status code indicates that the server was unable to fulfill the request. This may be, for example, because the client asked for the 800th-900th bytes of a document, but the document was only 200 bytes long.
·         417 - Expectation failed
The 417 status code means that the server was unable to properly complete the request. One of the headers sent to the server, the "Expect" header, indicated an expectation the server could not meet.
Server Error
·         500 - Internal Server Error
A 500 status code (all too often seen by Perl programmers) indicates that the server encountered something it didn't expect and was unable to complete the request.
·         501 - Not Implemented
The 501 status code indicates that the server does not support all that is needed for the request to be completed.
·         502 - Bad Gateway
A 502 status code indicates that a server, while acting as a proxy, received a response from a server further upstream that it judged invalid.
·         503 - Service Unavailable
A 503 status code is most often seen on extremely busy servers, and it indicates that the server was unable to complete the request due to a server overload.
·         504 - Gateway Timeout
A 504 status code is returned when a server acting as a proxy has waited too long for a response from a server further upstream.
·         505 - HTTP Version Not Supported
A 505 status code is returned when the HTTP version indicated in the request is no supported. The response should indicate which HTTP versions are supported.

HTTP Status Codes for Beginners

Informational
·         100 - Continue
A status code of 100 indicates that (usually the first) part of a request has been received without any problems, and that the rest of the request should now be sent.
·         101 - Switching Protocols
HTTP 1.1 is just one type of protocol for transferring data on the web, and a status code of 101 indicates that the server is changing to the protocol it defines in the "Upgrade" header it returns to the client. For example, when requesting a page, a browser might receive a static code of 101, followed by an "Upgrade" header showing that the server is changing to a different version of HTTP.
Successful
·         200 - OK
The 200 status code is by far the most common returned. It means, simply, that the request was received and understood and is being processed.
·         201 - Created
A 201 status code indicates that a request was successful and as a result, a resource has been created (for example a new page).
·         202 - Accepted
The status code 202 indicates that server has received and understood the request, and that it has been accepted for processing, although it may not be processed immediately.
·         203 - Non-Authoritative Information
A 203 status code means that the request was received and understood, and that information sent back about the response is from a third party, rather than the original server. This is virtually identical in meaning to a 200 status code.
·         204 - No Content
The 204 status code means that the request was received and understood, but that there is no need to send any data back.
·         205 - Reset Content
The 205 status code is a request from the server to the client to reset the document from which the original request was sent. For example, if a user fills out a form, and submits it, a status code of 205 means the server is asking the browser to clear the form.
·         206 - Partial Content
A status code of 206 is a response to a request for part of a document. This is used by advanced caching tools, when a user agent requests only a small part of a page, and just that section is returned.
Redirection
·         300 - Multiple Choices
The 300 status code indicates that a resource has moved. The response will also include a list of locations from which the user agent can select the most appropriate.
·         301 - Moved permanently
A status code of 301 tells a client that the resource they asked for has permanently moved to a new location. The response should also include this location. It tells the client to use the new URL the next time it wants to fetch the same resource.
·         302 - Found
A status code of 302 tells a client that the resource they asked for has temporarily moved to a new location. The response should also include this location. It tells the client that it should carry on using the same URL to access this resource.
·         303 - See Other
A 303 status code indicates that the response to the request can be found at the specified URL, and should be retrieved from there. It does not mean that something has moved - it is simply specifying the address at which the response to the request can be found.
·         304 - Not Modified
The 304 status code is sent in response to a request (for a document) that asked for the document only if it was newer than the one the client already had. Normally, when a document is cached, the date it was cached is stored. The next time the document is viewed, the client asks the server if the document has changed. If not, the client just reloads the document from the cache.
·         305 - Use Proxy
A 305 status code tells the client that the requested resource has to be reached through a proxy, which will be specified in the response.
·         307 - Temporary Redirect
307 is the status code that is sent when a document is temporarily available at a different URL, which is also returned. There is very little difference between a 302 status code and a 307 status code. 307 were created as another, less ambiguous, version of the 302 status code.

20110627

Linux basic commands (Vi)





All commands in vi must be preceded by pressing the “Escape” key. Most commands are case sensitive.










CURSOR MOVEMENT

All commands in vi must be preceded by pressing the “Escape” key. Most commands are case sensitive.

CURSOR MOVEMENT
  • Arrow Keys -> generally work as expected
  • Page up/down -> generally work as expected
  • nh -> Left n spaces (n indicates a number and is optional)
  • nj -> Right n spaces (n indicates a number and is optional)
  • nk -> Up n spaces (n indicates a number and is optional)
  • nl -> Down n spaces (n indicates a number and is optional)
  • ^F -> Forward one screen (^ indicates the “Control” key)
  • ^B -> Back one screen (^ indicates the “Control” key)
  • 0 -> (Zero) beginning of line
  • $ -> End of line
  • H -> Beginning of top line of screen
  • L -> Beginning of last line of screen
  • :1 -> Beginning of file
  • G -> End of file
  • INSERTING TEXT
  • i -> Insert text before cursor
  • a -> Append text after cursor (does not overwrite)
  • I -> Insert text at beginning of line
  • A -> Append text at end of line
  • r -> Replace the character under the cursor with next character typed
  • R -> Overwrite characters until end of line
  • o -> (Lowercase “o”) new line after the current line
  • O -> (Uppercase “O”) new line before the current line
  • DELETING TEXT
  • dd -> Deletes current line
  • ndd -> Deletes next n lines
  • D -> Deletes from cursor to end of line
  • x -> Deletes current character
  • X -> Deletes previous character
  • FILE MANIPULATION
  • :w file ->  Writes changes to file (file is optional, default is current file)
  • :w file -> Overwrites file (file is optional, default is current file)
  • :f -> Name renames current file to name
  • :q -> Quits edit session when no changes have been made
  • :q! -> Quits edit session and discards changes
  • :wq -> Writes changes to current file and quits edit session
  • MISCELLANEOUS
  • u -> Undo the last command made to a line
  • . -> Repeat the last command made to a line
  • nyy -> Yank n lines to buffer (n indicates a number and is optional)
  • ynw -> Yank n words to buffer (n indicates a number and is optional)
  • p -> Puts yanked or deleted text after cursor
  • P -> Puts yanked or deleted text before cursor
  • :r file -> Inserts file at current cursor position

How to configure Gmail with Lotus Notes V6.5


As we know that Gmail can be configured in many mail clients such as Outlook Express, Microsoft Outlook, Apple Mail, Thunderbird, Windows Mail, Entourage, Eudora, Foxmail, Mozilla, Netscape Mail, SnapperMail, The Bat, iPhone etc. You will find all the instructions how to configure the Gmail in these mail clients but I am sure that you will not find configuration with one of the best and oldest mailing platform, Lotus Notes. So, let me tell you the step by step procedure to configure Gmail with Lotus Notes. You just need to follow the following steps:

Settings in Gmail
·                     Open your Gmail with your username and password.
·                     Click on "Settings" at the right top.
·                     Click on "Forwarding and POP/IMAP" tab.
·                     In "POP download" section, click on "Enable POP for all mail".
·                     In "When messages accessed with POP" option, select "Keep Gmail's copy in the inbox".
·                     Similarly you can enable IMAP.
·                     Now click on "Save changes". You have done with Gmail.
Settings in Lotus Notes
·                     Open Lotus Notes with your username and password. For this you need not to connect with your Domino Server since everything you need to do in your "Local Server".
·                     Make a new database for your Gmail account by following steps:
o                  Click on File -> Database -> New.
o                  Select Server as "Local Server".
o                  Give Title as "Gmail". You can give any other title as per your convenience.
o                  File name will automatically be "Gmail.nsf". You can also change it as per your convenience.
o                  Now go to downwards and choose "Mail (R6)"(mail6.ntf).
o                  Click "OK". You new mail database will be created and show in your workspace.
·                     Now open your "Local Address Book" from left side bookmark panel. 
·                     Now you have to make a new location for your Gmail account by following steps:
o                  Click on New -> Location
o                  In "Basics" tab, choose the following:
§                Location type: Local Area Network.
§                Location name: It could be anything (say Gmail).
§                Internet mail address: Your email id (say vinoo@gmail.com).
§                Leave rest fields as it is.
o                  In "Server" tab, choose the following:
§                Home/mail server: pop.gmail.com.
§                Leave rest fields as blank.
o                  In "Ports" tab, select all ports (TCPIP, LAN0, COM1).
o                  In "Mail" tab, choose the following:
§                Mail files location: Local.
§                Mail file: Name of your mail file (here Gmail.nsf).
§                Internet domain for Notes addresses when connecting directly to the internet: gmail.com.
§                Mail addressing: Local only.
§                Send outgoing mail: Directly to internet.
§                Leave rest fields as it is.
o                  Click on "Save & Close".
·                     Now you have to make two accounts for sending (SMTP) and receiving (POP) mails from local address book itself. Make incoming account (POP) by following steps: 
o                  Click on New -> Account
o                  In "Basics" tab, choose the following:
§                Account name: It could be anything (say Incoming Gmail).
§                Account server name: pop.gmail.com.
§                Login name: Your Gmail's login name (say vinoo).
§                Password: Your Gmail's Password.
§                Protocol: POP.
§                SSL: Enable.
§                Only from location(s): Select the location your have created earlier (here Gmail).
o                  In "Protocol Configuration" tab, choose Leave mail on server: Yes.
o                  In "Advanced" tab, choose the following:
§                Port No: 995.
§                Accept SSL sites certificates: Yes.
§                Accept expired SSL certificates: Yes.
§                Send SSL certificates when asked (outbound connections only):No.
§                Verify account server name with remote server's certificate: Disabled.
§                SSL protocol version: V3.0 with V2.0 handshake. 
o                  Click "Save & Close".
·                     Now you have to make another account for outgoing (SMTP) by following steps:
o                  Click on New -> Account
o                  In "Basics" tab, choose the following:
§                Account name: It could be anything (say Outgoing Gmail).
§                Account server name: smtp.gmail.com.
§                Login name: Your Gmail's login name (say vinoo).
§                Password: Your Gmail's Password.
§                Protocol: SMTP.
§                SSL: Enable.
§                Only from location(s): Select the location your have created earlier (here Gmail).
o                  In "Advanced" tab, choose the following:
§                Port No: 465.
§                Accept SSL sites certificates: Yes.
§                Accept expired SSL certificates: Yes.
§                Send SSL certificates when asked (outbound connections only):No.
§                Verify account server name with remote server's certificate: Disabled.
§                SSL protocol version: V3.0 with V2.0 handshake. 
o                  Click "Save & Close".
·                     Now open you Gmail's mailbox (Gmail.nsf).
·                     Change your location to "Gmail" from bottom right drop down menu.
·                     Click on File -> Replication -> Replicate.
·                     Select "Replication via background replicator" and then click "OK".
·                     That's it. You will receive and send all mails from your Lotus Notes client.