Forward the $term variable to debian the xshell-way

Xshell is yet another putty-like terminal client for windows that features a couple of nice extensions. See the net for a multitude of alike “top-10 terminal clients for windows” posts. Among the features, Xshell does not only provide a raw terminal pane but also runs a so called local shell that actually embeds remote shells. In other words, initially (standard configuration) you get your xshell window, running the Xshell shell and offering a number of internal commands to act in the realm of Xshell by means of simple keystrokes. If you’re addicted to the keyboard, like me, this is a very pleasent way to go. For example, see the help output, a list of available sessions (connect profiles already configured) and an open to eventually connect to the remote host:

Anything keyed and, by the way, the session name even tab-expanded after a few characters. Cool, right?

Ok, that much for the preface, important to understand what followes next, the forwarding of a dedicated environment setting, namely TERM=xterm-256color with this terminal client (see why e.g.:, see others e.g.:

The point is, based on the local shell, Xshell is able to inject/communicate code the the remote shell in an after-login but pre-(final-)prompt fashion. All you need to do is to code a snippet to call some member functions of the current local shell Screen object. Three language binding are possible so far: js, py and vbs. Examples are given in AppData\Local\NetSarang Computer\6\Xshell\Scripts\ScriptSample, documentation resides as . In order to achive the forward, the following code is sufficient (don’t ask my why a sleep is needed here):

def Main():
	xsh.Screen.Synchronous = True  # True or False
	xsh.Screen.Send("export TERM=xterm-256color\r")

The file location can be configured in the sessions connect profile dialog like so. Done!

After all, the tiled and full screen view modes are also worth a try. Like it.


Remove a user id from a pgp key along gpg4win

Gpg4win, we’re speaking Windows here, comes with Kleopatra, a Qt-App from the KDE realm, to manage keys, called certificates, encrypt/decrypt/verify files and mails and so forth. Kleopatra is a nice piece of software and supplies almost any functionality you need in the branch. However, concerning certificate user id’s, mostly names and email-adresses in this context, Kleopatra does yet only provide adding. A delete or update (delete/insert) has not yet been instrumented (*1).
Fortunately, Gpg4win does include a full distrubution of GnuPG located as c:\Program Files (x86)\GnuPG, such that we have the full toolset of the used-to gpg command line at our disposal. According to , we just need a couple of commands to delete user id #1 as follows:

C:\Windows\System32>gpg -k
pub   ??? ??? [SC]
uid        [ ultimativ ] ??? <???>
uid        [ ultimativ ] ??? <???>
sub   ??? ??? [E]

C:\Windows\System32>gpg --edit-key ???
Geheimer Schlüssel ist vorhanden.
sec ...
[ ultimativ ] (1). ??? <???>
[ ultimativ ] (2)  ??? <???>

gpg> uid 1
sec ...
[ ultimativ ] (1)* ??? <???>
[ ultimativ ] (2)  ??? <???>

gpg> deluid
Diese User-ID wirklich entfernen? (j/N) j
sec ...
[ ultimativ ] (1)  ??? <???>

gpg> save

Kleopatra will notice ad hoc, cool. Enigmail does only show the primary user id anyway, so it might change in view, depending on the level of the user id deleted.

Have fun

(*1) If you’re with key servers, you should better think of revoking user id’s because in a key server environment, key metadata will always be merged to a set union. That is, nothing will be deleted really.

Ps. If you’re also suprised to find Kleopatra running in german but by principle prefer english for efficient wording, do find the language settings NOT Settings BUT with the Help main menu item 😉

Install the Oracle OE- and SH-schemata for the OrderEntry- and SalesHistory-benchmarks

# - oe takes intermedia, sh takes partitioning and bitmap-indexes, so ee is a must
# -

# [ $ ~ ]
mkdir sample-schemas ; cd sample-schemas
cp -R db-sample-schemas-* $ORACLE_HOME/demo/schema
cd $ORACLE_HOME/demo/schema
perl -p -i.bak -e 's#__SUB__CWD__#'$(pwd)'#g' *.sql */*.sql */*.dat

# yet install
rlsqlplus system/oracle@my_db_srv
show con_name -- MY_DB_SRV
-- system_password sys_password hr_password oe_password pm_password ix_password sh_password
--   bi_password tablespace_name temp_tablespace_name log_location ez_connect_string
@mksample oracle oracle hr oe pm ix sh bi users temp /u01/app/oracle/product/12.2.0/dbhome_1/demo/schema/log/ my_db_srv

# see the oe/sh log files
less $ORACLE_HOME/demo/schema/log/oe_oc_v3.log
less $ORACLE_HOME/demo/schema/log/sh_v3.log

Very cool bind overwrite to mimic sqlplus script optional parameters

This is just a reblog of On SQL*Plus Defines directed by SQL*Plus default values for script parameters, so credits go elsewhere. However, it’s such fun to recognize this guy employing the schortcomings of a 1st/2nd generation language such as sqlplus to actually overcome another distressing deficiency which is the lack of optional, at least fixed left-to-right positional command line parameters.
So what Vlad just does is to overwrite the binding value of an unprotected intrinsic variable for command line input transfer. Namely, he knows that command line input bindings like &1 and &2 and so forth will always exist in the runtime realm of the processor and purposeful overwrites one or the other positional binding by declaring a column blabla new_value 1,2,... slots of just the same name. That’s cool stuff, really, since it provides for a default value setting on a missing input. Something, sqlplus does not deliver, according to the manuals.

Real fun, have it

OTRS Dashboard / Set up an agent statistic element (widget)

OTRS does provide agent statistics to show on the dashboard. However, this settings is not active by default, so you’ll have to enable this feature in Admin->SysConfig under the UseAgentElementInStats identifier first.
Go and search for it, using the upper left input field, as usual, then switch it on.