Thursday 22 August 2019

Ubuntu 18.04 on ThinkPad P50 (Part 3)

Repackaging Lotus Notes for 18.04

Some of our corporate Domino applications still do not work properly when accessed from a web browser, so there was a need to install the Notes client on Ubuntu 18.04. This involved updating deprecated dependencies, rebuilding the deb package and publishing it to the local package repository.


tb@castor:~$ cd /tmp
tb@castor:/tmp$ mkdir notes
tb@castor:/tmp$ apt-get download ibm-notes
Get:1 http://ocdc.hursley.xyz.com/ocdc bionic-safe/XYZ i386 ibm-notes i386 9.0.1-20131022.1138+ocdc7 [358 MB]
Fetched 358 MB in 20min 8s (296 kB/s)                                          
tb@castor:/tmp/notes$ fakeroot
root@castor:/tmp/notes# dpkg -x ../ibm-notes*.deb .
 ...
root@castor:/tmp/notes# dpkg -e ../ibm-notes*.deb ./DEBIAN
root@castor:/tmp/notes# sed -i 's/libpng12-0/libpng16-16/g' DEBIAN/control 
root@castor:/tmp/notes# sed -i 's/+ocdc7/+ocdc8/g' DEBIAN/control         
root@castor:/tmp/notes# gunzip usr/share/doc/ibm-notes/changelog.Debian.gz 
root@castor:/tmp/notes# nano usr/share/doc/ibm-notes/changelog.Debian # append to changelog

root@castor:/tmp/notes# cd ..
root@castor:/tmp# dpkg -b /tmp/notes ibm-notes_9.0.1-20131022.1138+ocdc8_i386.deb 
dpkg-deb: building package 'ibm-notes' in 'ibm-notes_9.0.1-20131022.1138+ocdc8_i386.deb'.

root@castor:/tmp# exit
exit
tb@castor:/tmp/notes$ cd /usr/local/lib/apt/amd64/
tb@castor:/usr/local/lib/apt/amd64$ sudo cp /tmp/ibm-notes_9.0.1-20131022.1138+ocdc8_i386.deb .
tb@castor:/usr/local/lib/apt/amd64$ apt-ftparchive packages . | sudo tee Packages
 ...
tb@castor:/usr/local/lib/apt/amd64$ apt-ftparchive release . | sudo tee Release
Date: Wed, 07 Aug 2019 16:16:51 +0000
MD5Sum:
 7339b2b2be699eb389665b64b062c1fe             6319 Packages
 62234bf67aa71907789bcb7df1f05e97              444 Release
SHA1:
 7df336123833077c551c0285782d10aaf9cca53f             6319 Packages
 6e0d07f80c9062661e481fa159265b9ccbce09ff              444 Release
SHA256:
 2556cbebb467e8ec5b48733ac21fcb4b124ec252ea70cdf22cf9994e1e5d9849             6319 Packages
 77264df13b76bfc355aa3a911e10a4983d8737914fb1904d9a255d9c5a58d8d2              444 Release
SHA512:
 a1808ee41b7131d1fdb93ba32c5d04a496fafb8223d7b9e3ad3e00e0bfbfd138d75743a206f9beea5f724f5c63e4304bfff277a74e1087fa3047294b9b8b6459             6319 Packages
 5498ce04b5d3562d2cd48e4105eea0135059d9ea8a6ad61f57cb1e78f49841df629a9ab7a2cd2403f247f1d29a36ad5c04c21f69c6c00a10a09b7ee69e781e7d              444 Release
tb@castor:/usr/local/lib/apt/amd64$ 

First run and the missing bit

Notes silently failed and terminated after splash screen. No error logged, no trace of any missing libraries, no indication of the root cause. I had to find out the hard way, that the EULA acceptance prompt that was triggered on the first run was implemented in a way that relied on running scripts from /tmp. Which, in my case, was mounted with nosuid,nodev,noexec. I would really have appreciated at least a line of error message.


mount | grep /tmp
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noexec,noatime)
sudo mount -o exec,remount /tmp
/opt/ibm/notes/framework/../notes0
sudo mount -o noexec,remount /tmp # can be remounted with noexec after first run and accepting license

The final step

Having fixed the EULA related issue above, I experienced that Notes would enter an infinite loop after successful login. I have just moved over the whole ~/lotus directory from my old thinkpad, and had to make changes to notes.ini to reflect my updated linux userid and home path. Once done, Notes started smoothly and did not experience any issue since

No comments:

Post a Comment