[1353773.415012] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[1717914.743513] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[1723402.978913] mocp[23166]: segfault at 0 ip 00007fb77d367414 sp 00007fffb13e1890 error 4 in libc-2.23.so[7fb77d32c000+1c0000]
[1723517.951390] mocp[24536]: segfault at 0 ip 00007fc0a1ba3414 sp 00007ffe36b981b0 error 4 in libc-2.23.so[7fc0a1b68000+1c0000]
[1723796.295052] mocp[26449]: segfault at 0 ip 00007fc9e2869414 sp 00007ffe62e2d6d0 error 4 in libc-2.23.so[7fc9e282e000+1c0000]
[1724374.530637] mocp[29504]: segfault at 0 ip 00007fdd72321414 sp 00007ffce40e7810 error 4 in libc-2.23.so[7fdd722e6000+1c0000]
[1724577.869046] mocp[30596]: segfault at 0 ip 00007fd33af82414 sp 00007ffe91355710 error 4 in libc-2.23.so[7fd33af47000+1c0000]
[1724597.233037] mocp[30725]: segfault at 0 ip 00007ff32f4db414 sp 00007ffd8134cd00 error 4 in libc-2.23.so[7ff32f4a0000+1c0000]
[1724611.901296] mocp[30816]: segfault at 0 ip 00007f7b285a7414 sp 00007fff9875ecb0 error 4 in libc-2.23.so[7f7b2856c000+1c0000]
[1724639.114351] mocp[30970]: segfault at 0 ip 00007fec465d2414 sp 00007ffc03ced160 error 4 in libc-2.23.so[7fec46597000+1c0000]
[1724656.178450] mocp[31068]: segfault at 0 ip 00007f3d5a85d414 sp 00007ffd9bba2eb0 error 4 in libc-2.23.so[7f3d5a822000+1c0000]
[1767912.183623] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2128531.801117] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2206519.119045] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2212439.559272] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2213906.671638] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2253510.242385] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2343792.133507] traps: calcurse[30413] general protection ip:7ff97c20fbf2 sp:7ffdb88c0d70 error:0 in libc-2.23.so[7ff97c18c000+1c0000]
[2347667.866567] test-delnull[10242]: segfault at 8 ip 0000000000400e14 sp 00007ffd2bc96250 error 4 in test-delnull[400000+2000]
[2397722.989999] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[2645607.338408] conntrack: generic helper won't handle protocol 132. Please consider loading the specific helper module.
[2653214.415785] zita-n2j[27952]: segfault at 10 ip 00000000004042b7 sp 00007fc1ebd53ca8 error 4 in zita-n2j[400000+9000]
[2653464.107565] zita-n2j[31250]: segfault at 10 ip 00000000004042b7 sp 00007f1e32669ca8 error 4 in zita-n2j[400000+9000]
[2653537.443720] zita-n2j[31965]: segfault at 10 ip 00000000004042b7 sp 00007f9145258ca8 error 4 in zita-n2j[400000+9000]
[2653579.100637] zita-n2j[32360]: segfault at 10 ip 00000000004042b7 sp 00007f36e450dca8 error 4 in zita-n2j[400000+9000]
[2654107.988611] zita-n2j[319]: segfault at 10 ip 00000000004042b7 sp 00007ff97e581ca8 error 4 in zita-n2j[400000+9000]
[2654379.273795] zita-n2j[5524]: segfault at 10 ip 00000000004042b7 sp 00007f795f498ca8 error 4 in zita-n2j[400000+9000]
[2654419.977851] zita-n2j[7740]: segfault at 10 ip 00000000004042b7 sp 00007f57eb951ca8 error 4 in zita-n2j[400000+9000]
[2655843.229255] zita-n2j[8190]: segfault at 10 ip 00000000004042b7 sp 00007f9a40f90ca8 error 4 in zita-n2j[400000+9000]
[2805201.874813] test-delnull[20960]: segfault at 8 ip 0000000000400e14 sp 00007ffee86fd560 error 4 in test-delnull[400000+2000]
[2867563.247055] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[3147249.715461] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[3186219.458841] ucc-bin[18288]: segfault at a6c ip 00000000f731a407 sp 00000000ffa37e90 error 4 in Core.so[f7299000+af000]
[3186220.503112] ucc-bin[18308]: segfault at a6c ip 00000000f73f3407 sp 00000000ffd05ed0 error 4 in Core.so[f7372000+af000]
[3186221.545644] ucc-bin[18342]: segfault at a6c ip 00000000f7360407 sp 00000000ffd9c0d0 error 4 in Core.so[f72df000+af000]
[3186222.593100] ucc-bin[18349]: segfault at a6c ip 00000000f73c3407 sp 00000000ffe1f210 error 4 in Core.so[f7342000+af000]
[3186223.639743] ucc-bin[18370]: segfault at a6c ip 00000000f730e407 sp 00000000fffa9f50 error 4 in Core.so[f728d000+af000]
[3186224.682263] ucc-bin[18391]: segfault at a6c ip 00000000f73cc407 sp 00000000ff8a5090 error 4 in Core.so[f734b000+af000]
[3186225.724623] ucc-bin[18399]: segfault at a6c ip 00000000f73a6407 sp 00000000fffd18d0 error 4 in Core.so[f7325000+af000]
[3186226.767128] ucc-bin[18433]: segfault at a6c ip 00000000f736f407 sp 00000000ff9d6bd0 error 4 in Core.so[f72ee000+af000]
[3186227.810560] ucc-bin[18440]: segfault at a6c ip 00000000f73d7407 sp 00000000ffab7c90 error 4 in Core.so[f7356000+af000]
[3186228.853257] ucc-bin[18462]: segfault at a6c ip 00000000f733d407 sp 00000000ffd8ad10 error 4 in Core.so[f72bc000+af000]
[3186229.896376] ucc-bin[18496]: segfault at a6c ip 00000000f73fd407 sp 00000000ffa18550 error 4 in Core.so[f737c000+af000]
[3186230.939045] ucc-bin[18507]: segfault at a6c ip 00000000f73df407 sp 00000000ff9e4490 error 4 in Core.so[f735e000+af000]
[3186231.981709] ucc-bin[18515]: segfault at a6c ip 00000000f73b1407 sp 00000000ffe31290 error 4 in Core.so[f7330000+af000]
[3186233.024479] ucc-bin[18563]: segfault at a6c ip 00000000f7353407 sp 00000000fffe10d0 error 4 in Core.so[f72d2000+af000]
[3186471.356999] ucc-bin[21871]: segfault at a6c ip 00000000f732d407 sp 00000000fffc2810 error 4 in Core.so[f72ac000+af000]
[3186500.075160] ucc-bin[22300]: segfault at a6c ip 00000000f73ba407 sp 00000000ffb4ac50 error 4 in Core.so[f7339000+af000]
[3186556.996819] ucc-bin[23119]: segfault at a6c ip 00000000f73a2407 sp 00000000ff9bc750 error 4 in Core.so[f7321000+af000]
[3186616.454231] ucc-bin[23972]: segfault at a6c ip 00000000f7367407 sp 00000000ff894210 error 4 in Core.so[f72e6000+af000]
[3186632.375856] ucc-bin[24251]: segfault at a6c ip 00000000f73b0407 sp 00000000ffac1f90 error 4 in Core.so[f732f000+af000]
[3186702.224654] ucc-bin[25222]: segfault at a6c ip 00000000f73f9407 sp 00000000ffe37b90 error 4 in Core.so[f7378000+af000]
[3186762.442605] ucc-bin[26154]: segfault at a6c ip 00000000f73db407 sp 00000000ffce8c50 error 4 in Core.so[f735a000+af000]
[3186779.811682] ucc-bin[26428]: segfault at a6c ip 00000000f73ac407 sp 00000000ffdaa850 error 4 in Core.so[f732b000+af000]
[3186804.883950] ucc-bin[26814]: segfault at a6c ip 00000000f7385407 sp 00000000ffebdcd0 error 4 in Core.so[f7304000+af000]
[3186826.124721] ucc-bin[27175]: segfault at a6c ip 00000000f734f407 sp 00000000ff93c550 error 4 in Core.so[f72ce000+af000]
[3186850.984788] ucc-bin[27590]: segfault at a6c ip 00000000f73c1407 sp 00000000fff16610 error 4 in Core.so[f7340000+af000]
[3186883.927370] ucc-bin[28109]: segfault at a6c ip 00000000f73cb407 sp 00000000ffde2bd0 error 4 in Core.so[f734a000+af000]
[3186897.450197] ucc-bin[28321]: segfault at a6c ip 00000000f73d5407 sp 00000000ffd93990 error 4 in Core.so[f7354000+af000]
[3186909.873250] ucc-bin[28520]: segfault at a6c ip 00000000f7304407 sp 00000000fff0b490 error 4 in Core.so[f7283000+af000]
[3187248.043862] ucc-bin[790]: segfault at a6c ip 00000000f7358407 sp 00000000ffa52fd0 error 4 in Core.so[f72d7000+af000]
[3187251.221196] ucc-bin[849]: segfault at a6c ip 00000000f73b6407 sp 00000000ffecdad0 error 4 in Core.so[f7335000+af000]
[3187252.447746] ucc-bin[859]: segfault at a6c ip 00000000f73a1407 sp 00000000ffe75450 error 4 in Core.so[f7320000+af000]
[3187253.711835] ucc-bin[895]: segfault at a6c ip 00000000f73ba407 sp 00000000ffafc4d0 error 4 in Core.so[f7339000+af000]
[3187254.977037] ucc-bin[910]: segfault at a6c ip 00000000f73ea407 sp 00000000ffe6af10 error 4 in Core.so[f7369000+af000]
[3187256.242617] ucc-bin[948]: segfault at a6c ip 00000000f7336407 sp 00000000ff991390 error 4 in Core.so[f72b5000+af000]
[3187257.507531] ucc-bin[969]: segfault at a6c ip 00000000f7358407 sp 00000000ffb8f390 error 4 in Core.so[f72d7000+af000]
[3187258.773626] ucc-bin[1009]: segfault at a6c ip 00000000f73e4407 sp 00000000ff9748d0 error 4 in Core.so[f7363000+af000]
[3187260.002233] ucc-bin[1019]: segfault at a6c ip 00000000f73e5407 sp 00000000ff81ac50 error 4 in Core.so[f7364000+af000]
[3187261.272280] ucc-bin[1057]: segfault at a6c ip 00000000f73f7407 sp 00000000ffc65510 error 4 in Core.so[f7376000+af000]
[3187313.882545] ucc-bin[1850]: segfault at a6c ip 00000000f73b1407 sp 00000000ff82fed0 error 4 in Core.so[f7330000+af000]
[3187344.476709] ucc-bin[2296]: segfault at a6c ip 00000000f7343407 sp 00000000ffd73a90 error 4 in Core.so[f72c2000+af000]
[3187377.911535] ucc-bin[2775]: segfault at a6c ip 00000000f7347407 sp 00000000ffd816d0 error 4 in Core.so[f72c6000+af000]
[3187462.274216] ucc-bin[3947]: segfault at a6c ip 00000000f73f7407 sp 00000000ffb83890 error 4 in Core.so[f7376000+af000]
[3187519.859206] ucc-bin[4792]: segfault at a6c ip 00000000f732d407 sp 00000000fff36fd0 error 4 in Core.so[f72ac000+af000]
[3187599.174741] ucc-bin[5912]: segfault at a6c ip 00000000f73d6407 sp 00000000ffcea610 error 4 in Core.so[f7355000+af000]
[3187615.430626] ucc-bin[6178]: segfault at a6c ip 00000000f730a407 sp 00000000ffb49810 error 4 in Core.so[f7289000+af000]
[3187686.101745] ucc-bin[7227]: segfault at a6c ip 00000000f7336407 sp 00000000ffbf8f10 error 4 in Core.so[f72b5000+af000]
[3187699.301827] ucc-bin[7451]: segfault at a6c ip 00000000f73a6407 sp 00000000ffad41d0 error 4 in Core.so[f7325000+af000]
[3193285.562158] ucc-bin[26895]: segfault at a6c ip 00000000f736c407 sp 00000000ffc88f80 error 4 in Core.so[f72eb000+af000]
[3193287.321397] ucc-bin[26939]: segfault at a6c ip 00000000f73ba407 sp 00000000ffb01c80 error 4 in Core.so[f7339000+af000]
[3193289.084178] ucc-bin[26953]: segfault at a6c ip 00000000f73e3407 sp 00000000ffa8dc80 error 4 in Core.so[f7362000+af000]
[3193290.848513] ucc-bin[26993]: segfault at a6c ip 00000000f730f407 sp 00000000ff8f49c0 error 4 in Core.so[f728e000+af000]
[3193525.366602] ucc-bin[30334]: segfault at a6c ip 00000000f7323407 sp 00000000ffe3a0c0 error 4 in Core.so[f72a2000+af000]
[3193531.782499] ucc-bin[30468]: segfault at a6c ip 00000000f73bc407 sp 00000000fff73300 error 4 in Core.so[f733b000+af000]
[3246233.663668] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[3322604.931484] ucc-bin[15547]: segfault at a6c ip 00000000f7380407 sp 00000000ffba3130 error 4 in Core.so[f72ff000+af000]
[3486853.852231] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[3671154.839239] ucc-bin[32066]: segfault at a6c ip 00000000f73d3407 sp 00000000ffcf8670 error 4 in Core.so[f7352000+af000]
[3862809.609859] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[3930227.759058] sd 0:0:0:0: Attached scsi generic sg0 type 0
[3930227.759139] sr 4:0:0:0: Attached scsi generic sg1 type 5
[3930227.759294] sd 8:0:0:0: Attached scsi generic sg2 type 0
[4040352.408769] ucc-bin[2548]: segfault at a6c ip 00000000f73c3407 sp 00000000ffcce230 error 4 in Core.so[f7342000+af000]
[4045993.449418] ucc-bin[16323]: segfault at a6c ip 00000000f7382407 sp 00000000fffdd7b0 error 4 in Core.so[f7301000+af000]
[4192978.837166] ucc-bin[12127]: segfault at a6c ip 00000000f73b2407 sp 00000000ffa51cf0 error 4 in Core.so[f7331000+af000]
[4225828.292016] calcurse[3184]: segfault at 7fee9728d0f0 ip 00007fee93e6d58b sp 00007fff2137b6a0 error 4 in libc-2.23.so[7fee93def000+1c0000]
[4264697.685901] ucc-bin[7594]: segfault at a6c ip 00000000f73d7407 sp 00000000ff9987f0 error 4 in Core.so[f7356000+af000]
[4294191.337598] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
[4341659.716899] test-delnull[21889]: segfault at 8 ip 0000000000400e14 sp 00007ffc40ceff90 error 4 in test-delnull[400000+2000]

RANDOM FORTUNE:

Gosh that takes me back... or is it forward? That's the trouble with time travel, you never can tell."
          -- Doctor Who "Androids of Tara"

Relaying Sendmail via SSL

This howto will hopefully get sendmail relaying to the new smtp.virginmedia.com SSL enabled server, but the same technique should work with other servers too.

A little info:

The new virginmedia SMTP server uses SSL on port 465. Nothing wrong with that for most email clients like Thunderbird and the like. With mutt though we need to get sendmail to relay to it, and that's where the problem is, because sendmail will hang waiting for the client greeting and the mail never gets sent.

You may notice if you just try to telnet to smtp.virginmedia.com port 465 you will get disconnected just by issuing a EHLO.

To bypass this problem we need to create an SSL tunnel to the server and have sendmail relay through it. The application that I will use to do that is stunnel which is installed by default in Slack - it just needs some setting up.

Stunnel

Stunnel has two modes - server and client. We will use it as a client and create what is in effect a proxy to VM's SMTP server. I am still quite new to using stunnel so there may well be better/other ways to do this. Drop me a mail if you have suggestions.

We will create a simple config file for stunnel:

david@Junius(~)% cat /etc/stunnel/stunnel.conf
sslVersion = SSLv3

[ req ]
client = yes
accept = 2525
connect = smtp.virginmedia.com:465

relay-domain is going to be our stunnel hostname, defined in /etc/hosts. I'm just running it locally so I use 127.0.0.1 for the IP, but you can have it running on a different box. 2525 will be the port that it runs on. My hosts file now looks like this:

david@Junius(~)% cat /etc/hosts
.. snip ..
127.0.0.1 localhost
127.0.0.1 relay-domain
.. snip ..

I've read that relay-domain must come after localhost (I'm not sure how that works when it's running on a different box).

Now run stunnel with some flags:

stunnel /etc/stunnel/stunnel.conf -c -d relay-domain:2525

You should now be able to telnet in via stunnel and get the proper SMTP response:

david@Junius(~)% telnet relay-domain 2525
Trying 127.0.0.1...
Connected to relay-domain.
Escape character is '^]'.
220 mx.google.com ESMTP 15sm258258pxi.4
EHLO junius
250-mx.google.com at your service, [62.254.26.97]
250-SIZE 35651584
250-8BITMIME
250-AUTH LOGIN PLAIN
250-ENHANCEDSTATUSCODES
250 PIPELINING
quit
221 2.0.0 closing connection 15sm258258pxi.4
Connection closed by foreign host.

Success :-)

You will notice that smtp.virginmedia.com actually reroutes to mx.google.com. I have tried connecting directly to google but it doesn't work. Google picks up that the connection was routed through VM, I guess.

Sendmail

Before playing with sendmail settings backup sendmail.cf and submit.cf in /etc/mail

First we need to make an authinfo.db with our Virgin login info for relay-domain:

cd /etc/mail
mkdir auth
chmod 700 auth
cd auth

Now make a file 'authinfo' and edit it with some credentials. This is what mine looks like:

AuthInfo:relay-domain.thebigvoid.org "I: user@blueyonder.co.uk" "U:root" "P:password" "M:PLAIN"
AuthInfo:relay-domain.thebigvoid.org:2525 "I: user@blueyonder.co.uk" "U:root" "P:password" "M:PLAIN"

Change 'password' to your SMTP login password. Notice I have used the full hostname.domain (relay-domain.thebigvoid.org) here. This is also set in my hosts file, so you need to set that to whatever you have set for domain name.

makemap hash authinfo < authinfo
chmod 600 authinfo*

The permissions will ensure that the login info isn't world readable. Put yourself in /usr/share/sendmail/cf/cf and backup sendmail.mc and submit.mc. Edit submit.mc and sendmail.mc. These are the settings we need in both:

FEATURE(`authinfo',`hash -o /etc/mail/auth/authinfo.db')
define(`SMART_HOST',`relay-domain')
define(`RELAY_MAILER_ARGS', `TCP $h 2525')
define(`ESMTP_MAILER_ARGS', `TCP $h 2525')

You may need to play with the order and where these settings are in the actual files. The Build script will moan if they are in the wrong order.

Now:

./Build sendmail.mc
./Build submit.mc
cp sendmail.cf /etc/mail
cp submit.cf /etc/mail
/etc/rc.d/rc.sendmail restart
Testing
echo "This is a test" | mailx -s "TEST" me@myemail.com

If all went well you should have recieved it without any problems.