全部博文(64)
分类: WINDOWS
2009-12-07 14:30:21
As I know, there are many colleagues who use 'Putty' as a SSh terminal emualtor to connect to linux or Unix machine.And there is another software named as 'Xshell' which I have used for a few years, I think, it is easier to use than 'Putty'.
So I would like recommend to you such a good softwore, I hope this would be helpful to your work.
--roro 18:36, 5 November 2009 (PST)
There are 6 functions which are very useful for me, and certainly XShell has not only these six major functions.
XShell could change fonts size and color scheme with its 'Standard Buttons'. It also could display the linux files and directory with default color as same as the ones in linux.
Below are two images,one is the picture of XShell which login
my linux computer via ssh and run 'ls' command at my home directroy,
the other is a screenshot of linux gnome terminal of my computer.
XShell supports the Session Tabs, you could open a few sessions with different machines in one windows,and you also could change the focus of Tabs with shortcut key Alt + {1,...,n}, numbers means the tabs numbers increased from left to right on Xshell window. This shortcut key is as same as the one used on the gnome-terminal of linux.
BTW, you also could duplicate an existed session easily, and
the new duplicated session is at your home directory. (gnome-terminal
of linux could also support this function,whose shutcut key is
'Ctrl+Alt+T',furthermore,the son session is at at same path as its
mother session is at.).See the below picture for details
Sometimes we need transfer some files between ssh linux server and windows machine, there is a simple way to do that on XShell
We just need install a package named as 'lrzsz' on your linux server box,before we do that.
sudo apt-get install lrzsz (for debian or ubuntu)
yum install lrzsz (for Red Hat series)
The 'rz' means that receive files from others via ZModem Protocol, on the contrary, 'sz' means that send files to others
just run 'rz' on your xshell session, and select the source files on the new pop out diaglog.
rz
See the below picture for details.
sz path/filename
See the picture below for details.
Sometimes we need copy some string from ssh login session to windows platform, or paste some ones(such as a linux command with long long parameters copied from a web browser) from windows clipboard to ssh session.
Just right-click mouce to select 'copy' or 'paste' button on the pop out menu. ('Ctrl+Insert' is the 'copy' shortcut key, and 'Shift+Insert' is for 'Paste'.)
XSheel supports save the session information as 'Putty" does, and it also support to login with the RSA pubilc key, and without username and password.
It is a little complex to do so, and the instructions are that:
Open the Xshell.
Press Open button.
Create a new session setting for first use, at 'New Session Property' dialog,
input the some setting:
Name and Ip address in 'Connection' section.
At first time, we need create a rsa pubilc key for authenticated login, the method is as below:
then select 'Authentication' section,and on the 'User key:' textbox,
click 'Browse' button to prepare to create a new rsa key for XShell.
see the picture for other settings.
On the 'User keys' diaglog, select 'generate' button to create a new rsa key for first use.
Key tpye: RSA
Key length: 1024 bits
Passphrase: NULL(recommendation, for easy use but weakened security)
At the end, copy the public key to windows clipboard,see picture below for details
Login the ssh server, edit a file which at your home directory.
vi ~/.ssh/authorized_keys
copy the public key in windows clipboard to a new line in above authorized_keys file.
You just need create a text file named as 'authorized_keys',if there is no such a file there.
then restart the ssh server to make the configure works
sudo /etc/init.d/ssh restart (for ubuntu and debian)
service sshd restart (for red hat series)
Then you could login ssh server without password.
Now it is time to show my favorite feature, as you know, we often need log the linux output on its console, or some information gotten from some device port via HyperTerminal(for windows) or minicom(for linux).
On Xshell, just need right-click session window, and select 'log', then 'start' or 'stop'.
Then xshell would store all information from this session to a local text file which you named and located, until you press 'Stop' button.