Run this within a steady screen session. You can get the approximate time when the remote server went down or other abnormal behavior.
It's useful mostly for your custom scripts, which running on specific host and tired on ssh'ing every time when you need one simple command (i use it for update remote apt repository, when new package have to be downloaded from another host). Don't forget to set up authorization by keys, for maximum comfort. Show Sample Output
Terminal is part of XFCE Desktop. This will open a tab for every node that we pass in the command line. In a single line we'll connect to nodes of our server farm.
It is an easy method unzip a file and copy it to remote machine. No unziped file on local hard drive Show Sample Output
Once it is connected to the remote server by that ssh protocol,the mentioned command will start working on that server.
Could use your ssh bash history if your known_hosts are hashed and you want to keep it hashed
The command above has been changed due to very good constructive criticism - thanks x 2! This command can be used after acquiring mac's, ip's and hostname's or any of the above from a freshly scanned LAN. User must be root, and remember to change your settings on your network managing software manually (Fedc10 NetworkManager Applet 0.7.1 is mine) instead of 'auto DHCP'. You can also substitute eth0 for wlan0 etc - be good and ENJOY!
due to bug can not comment
This command will ask for remote sudo password before executing a remote command.
for passwordless login
This is the quick and dirty alternative ;) The whole file will be emptied, this is equal to /dev/null > ~/.ssh/known_hosts
When you SSH to a server who's hostname or IP has changed since the last time a connection was recorded in the known_hosts file a warning will be displayed since this indicated a possible DNS spoofing attack. If this is a known change then this command will remove the previous entry and allow the SSH connection. The SSH client will prompt you as if it was the first time connected to the server. Replace ${LINE} with the line of the offending key in ~known_hosts. 49 in the sample output. Show Sample Output
To start X11 display only on your local machine: xeyes & Extensions to basic command: ssh -X -f user@remotehost xcalc -bg black -fg green
One time you logged in, you can prove these method just writing "firefox".
put down the joint and rtfm :)
waste the band width Show Sample Output
use .ssh file to login the server
This allows you to display the wireshark program running on remote pc to your local pc.
After seeing the command you wish to repeat, just invoke it using the ! syntax.
I have this as a file called deletekey in my ~/bin. Makes life a little easier.
Simply copies your public key to the remote system. For the first time, this will require a password for the user@remote account. From then on, ssh will ask for your private key keyphrase occasionally but you won't need to use the password. Very handy when you're moving files for testing etc.
When you have to manage lot of servers, it's boring to type ssh root@myhost for each connection. Now you can type juste "s someting" and you are connected. You can too add bash_completion script to complet with tab the name of your servers. This will be the next tips from me ;) Show Sample Output
commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for: