...
Request | Command |
---|---|
To quit without saving | Press ‘:’ then enter ‘q!’ |
To quit with saving | Press ‘:’ then enter ‘x’ or ‘wq’ |
Go to top of file | Press ‘:’ then enter ‘0’ |
Go to last line | Press ‘G’ |
Search pattern | Press ‘/’ then enter your search text. Press then ‘n’ for next (forward) or ‘N’ for backward |
Remove current character | Press ‘x’ |
Insert text | Press ‘i’ (press ESC once text completed) |
Insert line | Press ‘o’ for a line below cursor, ‘O’ for a line above cursor (press ESC once text completed) |
Delete a line | Press ‘dd’ |
'vim' has also a graphical version named 'gvim'. If not installed, you can run: # yum -y install gvim
‘gedit’ graphical editor
‘gedit’ is a graphical text editor, users familiar with Windows notepad should not encounter difficulties to use it.
...
How to setup ‘ssh’ trusts between Linux and HP-UX
...
Please note:
- The prompts will tell you where to execute the commands, "
HPUX#
" (root user) or "Linux#
" (root user) - Remember Linux/Unix is case sensitive
- If hosts are not known by each other, fill the
/etc/hosts
file for example (usingvi
for example) - linuxhost represents the name of your Charon server (can be any name you want)
- hpuxhost represents the hostname of your HP-UX virtual machine
On the HP-UX system, enter the following commands if the folder does not already exist:
|
On the Linux server, enter:
→ Do not specify any passphrase.
→ Enter the password for the copy operation to complete |
On the HP-UX system, add the Linux server key to the authorized keys:
|
Perform a simple test on the Linux server:
|
If trying to execute a remote command on the HP-UX system, a message telling "no matching cipher found" is displayed, the cipher has to be setup on the Linux server side in the /root/.ssh/config
file:
|
|
Div | ||
---|---|---|
| ||
How to install 'rsh' on RHEL 8
To setup 'rsh' on RHEL8, use the following commands:
# dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm # ARCH=$( /bin/arch ) # subscription-manager repos --enable "codeready-builder-for-rhel-8-${ARCH}-rpms" # dnf -y install rsh |
More information in this article: rsh and rsh-server packages missing in RHEL 8
How to setup ‘rsh’ trusts between Linux and HP-UX
...
Please note:
- The prompts will tell you where to execute the commands, "
HPUX#
" (root user) or "Linux#
" (root user) - Remember Linux/Unix is case sensitive
- If hosts are not known by each other, fill the
/etc/hosts
file for example (usingvi
for example) - linuxhost represents the name of your Charon server (can be any name you want)
- hpuxhost represents the hostname of your HP-UX virtual machine
Introduction
RSH executes commands on a remote host. It can be used to issue a shutdown on the Charon Tru64 virtual machine.
...
To facilitate use of "expect"
for shutdown, an example is provided in the "guest_shutdown.exp
" script located in the /opt/charon/utils
folder. If you plan to customize the script, you'll have to create a copy and not use it directly as it will be overwritten in case of Toolkit upgrade.
Please note:
'telnet
' and 'expect
' packages must be installed in order to use this feature.
The following error message can be returned when stopping the virtual machine when trying to use the expect script example:
- if expect package is not installed: "
Stop script returned error code 126
". - if telnet is not installed: "
%EXPECT-F-NOSRM, Cannot continue, 'telnet' is not installed
" then "Stop script returned error code 4
"
Caution: the virtual machine process will be however killed by service management process
...
.
If console is locked:
Any active session to the console must be killed before the "expect
" script is executed.
For example, if you are connected via "telnet
" on the localhost/port (the kill is not done inside the expect
script). Using the "/opt/charon/utils/charon_gstart_expect
" script file the necessary operations will be performed.
If the console is locked from another host (if you use putty
for example), you will have to cancel the connection by yourself otherwise the shutdown will not be performed cleanly.
Div | ||
---|---|---|
| ||
Script usage
...
Parameter | Description |
---|---|
<port> | telnet port number (example: 30001) |
<user> | username for login (must be able to perform shutdown) |
<password> | password |
<prompt> | shell prompt (including end space) or last characters of the prompt |
<opsys> | HPUX or MPEIX (case sensitive) |
Example for HP-UX:
# /opt/charon/utils/guest_shutdown.exp 30001 root 12345 "# " HPUX |
Example for MPEIX:
# /opt/charon/utils/guest_shutdown.exp 30001 X X X MPEIX |
How to restart CHARON-PAR on Linux automatically on failure
...