System administration

(solved) gpg-agent (or pinentry) + ssh (or su) not working on Linux / Unix

The case: you connect to a remote computer with ssh, or may be you just do su to become another unix user, then start something like

 gpg-agent --daemon /bin/bash

or may be you worked hard so gpg-agent is launched from your .profile or something like that.

Then, you try to decrypt a file:

 gpg -d my-file.gpg

and you expect gpg to enter into some dialog to ask you the passphrase. Furthermore, you expect that you won't have to enter the passphrase again if you decrypt the same file once more a few minutes from now.

readline() on closed filehandle FILES at /usr/sbin/popularity-contest line 104 (not solved yet, but at least we understand) and how popularity-contest works

This is bug #742017

The solution is yet to be devised, but at least we know

How popularity-contest works

popularity-contest is a script that sends a periodic report to Ubuntu (or Debian) about the installed and used packages. At the time of this writing (popularity-contest version 1.51 on Ubuntu 11 / Natty Narwhal), popularity-contest is a Perl script.

How does it work ?

At the heart of the script are two imbricated loops.

Deltacopy over ssh not working after setup

So you're trying to backup your Windows PC using deltacopy, likely using a Unix / Linux machine for the storage.

You've set the things up, created a public / private key but it's not working. The thing seems to start, and nothing happens. You're sniffing on the server side, you see the connection establishing, and some tls traffic, but nothing seems to happen. The connection stays opened, and nothing happens. What the hell ?

Remember that ssh maintains a list of known servers to detect man-in-the-middle attacks.

/etc/cron.daily/exim4-base exited with return code 123

The problem has been reported here, but I'm not sure the solution was clearly stated.

I got this under Ubuntu 9.04, exim4 4.69-9ubuntu1.

In short, the problem is caused by the following lines in /etc/cron.daily/exim4-base:

 + find /var/spool/exim4/db -maxdepth 1 -name *.lockfile \ 
    -or -type f -printf %f\0
 + su - --shell /bin/bash --command xargs -0r -n 1 \ 
    /usr/sbin/exim_tidydb /var/spool/exim4 > /dev/null Debian-exim

These two lines find files in /var/spool/exim4/db, where live various databa

Automatically forward X connections (Ubuntu)

I have the habit of having one user per function (for example customer care is a user, dev is a user and so on). So I'm continuously jumping from one Unix user to another.

The desktop, however, is one and only one, so I need to forward X authentication from user to user (I'll explain in a minute).

In the Redhat days, that wasn't such a problem, because the system was doing it for me. However, in switching to Ubuntu, I was surprised this feature didn't hold.

I give you an example to be more concrete. Let's say I've logged into the desktop as user tof. I can do this:

Modif DHCP / DNS

I think every computer in the world should run its own DNS resolver. It's a matter of performance and robustness. However office machines are DHCP clients more often than not, and DHCP clients tend to rewrite /etc/resolv.conf. So at every install there are things to do.

RH 7

pump

Debian

Ubuntu 7

Add

 prepend domain-name-servers 127.0.0.1;

to the dhclient.conf file (strangely enough in /etc/dhcp3).

NB: the line generally already exists, but is commented out.

Syndicate content