If you commonly ssh from your OS X computer to a remote server such as a web server it makes sense to set up passwordless ssh login so you can have a secure connection without having to always enter your password. Setting up passwordless login also allows you to run automated scripts to help with managing things like offsite backups. Scripts can’t be automated if they require someone to be present at your machine typing in passwords every time they run.
It’s worth noting that you may first want to check if you already have existing ssh keys on your computer. This can be done by entering cd ~/.ssh [enter] at your terminal. If you get a response back stating “No such file or directory” then you need to proceed with the following steps.
To set up passwordless login between a remote unix/linux server and your OS X machine fire up terminal and…
1. generate an RSA private key
ssh-keygen -t rsa -C “email@example.com”
2. copy the key to your clipboard
pbcopy < ~/.ssh/id_rsa.pub
3. ssh into the webserver
ssh firstname.lastname@example.org (login with your password for the last time)
4. make a .ssh directory, if it doesn’t already exist
5. create an authorized_keys file and paste in the key from mac that you just copied to your clipboard
vi .ssh/authorized_keys (paste in key from clipboard, save)
6. set permissions for necessary files and directories on webserver
I periodically come across the “Bad Request Error 400” problem when using Gmail on Google Chrome. I’m not the only one as you can see from a Google search on the topic. One minute all is well and the next, reload after reload all you see is a blank page and this error message. You haven’t changed anything but things just don’t work anymore. If you try accessing Gmail on a different browser like Firefox, everything seems good, so it’s not Gmail itself; it’s the combination of Gmail and Chrome.
It seems quite ridiculous really that this issue should happen on Chrome. Shouldn’t Gmail on Chrome be essentially bulletproof? Google on Google. C’mon.
When looking for answers the most common suggestion you’ll find is to clear all of your browsing data; history, cache, cookies, etc. I happen to like my browsing data. Among other things, it helps me find things and allows me to stay logged in on various sites. Deleting it all causes me pain.
After searching through various sites and the Gmail and Chrome forums I finally found a great solution. It turns out deleting all of your browsing data is not necessary. This problem comes down to one solitary cookie. Delete this cookie and life is good again.
How to resolve the Bad Request Error 400 in Gmail
Here are the exact instructions.
– Right click on the page with the error
– Select “Inspect Element” from the right click menu
– Select the “Resources” tab at the top of the Developer Tools pane or window that opens up
– Expand the “Cookies” section on the left side navigation by clicking on the little triangle next to “Cookies”
– Select the “mail.google.com” cookie
– Right click on “GMAIL_IMP”
– Select “Delete”
– Refresh the error page