20140824 twm on centos 7 - plembo/onemoretech GitHub Wiki

title: twm on CentOS 7 link: https://onemoretech.wordpress.com/2014/08/24/twm-on-centos-7/ author: phil2nc description: post_id: 8294 created: 2014/08/24 21:51:11 created_gmt: 2014/08/25 01:51:11 comment_status: closed post_name: twm-on-centos-7 status: publish post_type: post

twm on CentOS 7

NOTE: An observant reader advised me that the "X Window System" is no longer available for CentOS/RHEL 7 (and might not be for CentOS/RHEL 6). A workaround is incorporated below. I've been using twm as my basic window manager for remote vnc sessions on Red Hat Linux machines for almost a decade, and saw no reason to change that even though the latest release of CentOS (following its upstream source, Red Hat Enterprise Linux 7), inexplicably omits the xorg-x11-twm package. Two important things to understand about twm: (1) it's no longer under development and so remains, perpetually, pinned to version 1.0.3; (2) it consists of a single executable dependent on libraries that ship with the standard xorg distribution of x11. As a result, it turns out that the twm binary from the latest CentOS 6 package, xorg-x11-twm-1.0.3-5.1.el6, works just fine on CentOS 7. If you're interested in running a minimal X system like mine, you'll need to install some additional packages. At a minimum you'll need the following:

xorg-x11-xinit
xorg-x11-font-utils
xorg-x11-fonts-Type1
libX11-common
xorg-x11-xauth
libX11
dbus-x11
xorg-x11-server-utils
xorg-x11-xkb-util
tigervnc-server
xterm

Mext, download and install xorg-x11-twm from your favorite CentOS 6 mirror:

rpm -ivh --nodeps xorg-x11-twm-1.0.3-5.1.el6.x86_64.rpm

For maximum flexibility you can add the following CentOS 7 packages if they're not already installed (some older apps may need these):

xorg-x11-fonts-75dpi
xorg-x11-fonts-100dpi
xorg-x11-fonts-misc

Finally, to avoid getting the font load error that is the result of modern Linux system's use of UTF-8, use this modified xstartup under .vnc (be sure to back up the original):

# Simplified vnc x session
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid '#222E45' 
vncconfig -iconic &
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
LANG=C twm &

The key here is to set "LANG=C", so that the UTF-8 intolerant code in twm won't throw a fit.

Copyright 2004-2019 Phil Lembo