apt-file – Find programs inside APT/Debian-repositories

Recently I noticed on a freshly installed server that there was no command called nslookup. Luckily, Debian-like distributions have the apt-file tool.

This makes it possible to search for applications that are not yet installed but are in principle available in the APT repository. The command

apt-file search nslookup

quickly shed light on the matter and delivered the following output:

bash-completion: /usr/share/bash-completion/completions/nslookup
bind9-doc: /usr/share/doc/bind9-doc/arm/man.nslookup.html
dnsutils: /usr/bin/nslookup
dnsutils: /usr/share/man/man1/nslookup.1.gz
exim4-doc-html: /usr/share/doc/exim4-doc-html/spec_html/ch-the_dnslookup_router.html
fpc-source-3.0.4: /usr/share/fpcsrc/3.0.4/packages/fcl-net/examples/cnslookup.pp
libnet-nslookup-perl: /usr/share/doc/libnet-nslookup-perl/changelog.Debian.gz
libnet-nslookup-perl: /usr/share/doc/libnet-nslookup-perl/copyright
libnet-nslookup-perl: /usr/share/lintian/overrides/libnet-nslookup-perl
libxpa-dev: /usr/share/man/man3/xpanslookup.3.gz

So it was clear that the dnsutils package had to be installed afterwards. Calling

apt-get install dnsutils

was enough and the nslookup tool was already available on my server.

If apt-file itself is not yet installed, it can be installed beforehand using

apt-get install apt-file

It is important that the cache is set up immediately afterwards. This is done using

apt-file update

Linux administration can be so easy …

Bye firefox

Is there actually a worse web browser than Firefox-Mozilla? I hardly thought that it couldn’t get any worse and Firefox is already putting one on it with the next version.

On the one hand, the high version numbers are a sign of crooked development and, on the other hand, the browser patronizes you wherever it can, under the pretext of security.

Aside from memory consumption and profile clutter, it has numerous bugs, although it has to be admitted that it runs even worse on Microsoft Windows than on Linux.

Anyway, I’ve buried him now. I’m not fixated on any browser but Firefox doesn’t come into my house anymore.

Freshcode-Club – Your preferred software-repository

Can anyone remember Freshmeat aka Freecode? This was the ultimate site to get OpenSource or Linux software.

Unfortunately, the project was stopped in 2014 and has been standing still ever since. The state at that time was frozen and can still be reached.

Alternatively, however, the Freshcode Club project has developed, which is reminiscent of the old days of Freshmeat with a similar design. See also https://freshcode.club

Unfortunately, I only discovered the project now, although it has been available on the internet for some time.

Prevent password query for SSH access on client side

Especially with automated scripts which establish SSH connections to external systems, the request for a password within the script is undesirable or leads to the script being blocked.

It is possible to simulate such password entries with the expect tool, but this is anything but secure. The best way is authentication via RSA keys, which must be entered as a public key in the target system in order to enable password-free access.

If you administrate many systems and have forgotten to import a public key into a target system, you end up with the problem of the blocked script again because a password query is initiated as a failover.

To prevent this, the -o BatchMode=yes parameter is simply passed to the SSH client. It is generally recommended to use this parameter as soon as ssh appears in a script. As a rule, however, it is not considered and prevents many a system from running automated processes.

A typical command-line will look like this:

ssh -o BatchMode=yes www.my-sample-hostname.com

If you use SSH indirectly via Rsync, this parameter can be used as follows:

rsync -av -e "ssh -o BatchMode=yes" www.mysample.com:/src1 /dst1