This is total eye candy but I like the OSD that often shows up when you use the special keys on computers and laptops. There is a program called TPB that you can use to get OSD working on a Thinkpad, so when you startup TPB it will add a green OSD towards the bottom of your screen, and the OSD shows up whenever you use the special keys. For example when I hit the volume +/-i or the Mute button for example. So, first things first, we need to install it.
Once it’s installed you can configure it using the file /etc/tpbrc. The default font kinda sucked so I changed it to lucidatypewriter.
# Defines the font for the on-screen display. You may use "xfontsel" to choose
# one. Default is the default font of the xosd library.
# Original font setting
#OSDFONT -*-luxi sans-*-r-*-*-17-*-*-*-*-*-*-*
# New font setting
Original font example
TPB using original font
New font example
TPB using new font
To make tpb start up between reboots you can add it to /etc/rc.local
# start tpb during boot in daemon mode
Recently I started to get a strange error with one of my OpenVZ VE nodes. This VE is the one that maintains my MySQL database for my WordPress blog. Here’s the error I was getting.
# inside the OpenVZ VE
% yum update
Loading "fastestmirror" plugin
Loading mirror speeds from cached hostfile
* atrpms: dl.atrpms.net
* extras: mirror.anl.gov
* rpmforge: ftp-stud.fht-esslingen.de
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
File "/usr/share/yum-cli/yummain.py", line 105, in main
result, resultmsgs = base.doCommands()
File "/usr/share/yum-cli/cli.py", line 289, in doCommands
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 85, in _getTs
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 91, in _getTsInfo
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 537, in <lambda>
pkgSack = property(fget=lambda self: self._getSacks(),
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 392, in _getSacks
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 214, in populateSack
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 66, in doSetup
File "/usr/lib/python2.4/site-packages/yum/plugins.py", line 169, in run
func(conduitcls(self, self.base, conf, **kwargs))
File "/usr/lib/yum-plugins/fastestmirror.py", line 90, in postreposetup_hook
repomirrors[str(repo)] = FastestMirror(repo.urls).get_mirrorlist()
File "/usr/lib/yum-plugins/fastestmirror.py", line 142, in get_mirrorlist
File "/usr/lib/yum-plugins/fastestmirror.py", line 155, in _poll_mirrors
File "/usr/lib/python2.4/threading.py", line 416, in start
thread.error: can't start new thread
Yup, it made a lot of sense to me as well. Seemed to be something with yum’s fastermirror plugin, or so I thought, so I just disabled it and was able to get a little further like this:
…. Continue reading → Increasing RAM in a OpenVZ Virtual Environment »»
I always forget to do this every time I setup a new client in my network so I’m writing it down here. I have a print server in my intranet and use CUPS to share my printers out to my linux and windows machines. The mis-config shows up like this to start:
lpq: error - no default destination available.
It usually takes a couple of minutes to remember/figure out what I’m doing wrong here. Then it dawns on me that I need to modify the client.conf file. In order to get a client machine running CUPS to know about a print server I have to modify its client.conf file.
Add this to the file, /etc/cups/client.conf which is usually empty to start:
Restart cups and you should be all set.
As part of the aftermath of my Fedora Core 6 laptop getting dropped, I needed to do several re-installs of key apps. One of the more critical ones was VMware Server 1.08. I’m not a big fan of the 2.x version of this product so I’d rather just continue using the 1.x version.
In what has pretty much become the norm with VMware, every kernel upgrade, invariably breaks VMware. Since I had previously been using Fedora Core 6, a deprecated release, I hadn’t had a kernel update in a while, so I didn’t really have to deal with kernel churn. Now back on the bleeding edge with Fedora 10 I’m once again having to keep VMware Server working everytime a new kernel comes out.
So to start, I made sure I had the latest and greatest version of the 1.x VMware Server branch. I prefer to work with RPMs, so I grabbed the RPM version of the package. Upon installing it I ran into the following.
1st install attempt
## install vmware rpm
% rpm -ivh VMware-server-1.0.8-126538.i386.rpm
Preparing... ########################################### [100%]
1:VMware-server ########################################### [100%]
# configure vmware
Using 2.6.x kernel build system.
make: Entering directory `/tmp/vmware-config10/vmmon-only'
make -C /lib/modules/220.127.116.11-170.2.35.fc10.i686/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. modules
make: Entering directory `/usr/src/kernels/18.104.22.168-170.2.35.fc10.i686'
CC [M] /tmp/vmware-config10/vmmon-only/linux/driver.o
In file included from /tmp/vmware-config10/vmmon-only/./include/machine.h:24,
/tmp/vmware-config10/vmmon-only/./include/x86.h:830:1: warning: "PTE_PFN_MASK" redefined
In file included from include/asm/paravirt.h:7,
include/asm/page.h:22:1: warning: this is the location of the previous definition
In file included from /tmp/vmware-config10/vmmon-only/linux/vmhost.h:13,
/tmp/vmware-config10/vmmon-only/./include/compat_semaphore.h:5:27: error: asm/semaphore.h: No such file or directory
/tmp/vmware-config10/vmmon-only/linux/driver.c:146: error: unknown field ‘nopage’ specified in initializer
/tmp/vmware-config10/vmmon-only/linux/driver.c:147: warning: initialization from incompatible pointer type
/tmp/vmware-config10/vmmon-only/linux/driver.c:150: error: unknown field ‘nopage’ specified in initializer
/tmp/vmware-config10/vmmon-only/linux/driver.c:151: warning: initialization from incompatible pointer type
/tmp/vmware-config10/vmmon-only/linux/driver.c: In function ‘LinuxDriver_Ioctl’:
/tmp/vmware-config10/vmmon-only/linux/driver.c:1670: error: too many arguments to function ‘smp_call_function’
make: *** [/tmp/vmware-config10/vmmon-only/linux/driver.o] Error 1
make: *** [_module_/tmp/vmware-config10/vmmon-only] Error 2
make: Leaving directory `/usr/src/kernels/22.214.171.124-170.2.35.fc10.i686'
make: *** [vmmon.ko] Error 2
make: Leaving directory `/tmp/vmware-config10/vmmon-only'
Unable to build the vmmon module.
For more information on how to troubleshoot module-related problems, please
visit our Web site at "http://www.vmware.com/download/modules/modules.html" and
Googling a bit produced this blog post and this wiki post. According to the blog post you need to apply the following patch set to VMware 1.08 to get it to work with the newer 2.6.27 kernels. Here’s a link to the original tarball of the patchset, as well as a link to a local copy I have cached on my site.
…. Continue reading → Getting VMware 1.x Server Running on Fedora 10 »»
Recently one of my kids knocked my Fedora Core 6 laptop off of a counter and sent the hard drive for a loop. This rendered the drive inaccessible. So I threw spinrite at it and after ~6 hours several sectors that were damaged were repaired/pulled out and the data moved to a different location on the drive.
Please be alright … Please be alright …
When I rebooted my EXT3 partition weighed in and had all kinds of fits about the drive being dropped as well too. I was able to get onto the system and copy most everything that I wanted off of it using scp to another system. Mind you I did have to go into the dreaded /lost+found directory to recover the data but by in large it was all there.
Light at the end of the tunnel
So I wiped the drive clean and took the opportunity to upgrade to Fedora 10. Now way back when I setup Fedora Core 6 on my Thinkpad T42 I had to do a lot of hacking and customizing to get the lappy to work optimally with FC6. For example, sleep mode when I closed the lid and the special keys to actually work, among other things.
All I can say is WOW. Everything that I had to manually monkey around with just works now! The only thing missing was a package I found out about from thinkwiki to get the nifty OSD when I hit the mute & volume keys.
Problem #1, didn’t take long
One thing that I just do even though it’s considered bad practice is to just run as root on a laptop. It’s just easier and I don’t have to fight with it too much otherwise.
So when I tried to login as root at the GDM prompt I was presented with an annoying although somewhat expected problem where it wouldn’t let me login as root to GNOME. I knew it had something to do with security and most likely PAM or some such, so I googled for “fedora 10 login as root desktop” and the first hit was a page over on cyberciti.biz that said you could disable this “feature” by commenting out a line in the /etc/pam.d/gdm file.
auth [success=done ignore=ignore default=bad] pam_selinux_permit.so
#auth required pam_succeed_if.so user != root quiet
auth required pam_env.so
auth substack system-auth
auth optional pam_gnome_keyring.so
account required pam_nologin.so
account include system-auth
password include system-auth
session required pam_selinux.so close
session required pam_loginuid.so
session optional pam_console.so
session required pam_selinux.so open
session optional pam_keyinit.so force revoke
session required pam_namespace.so
session optional pam_gnome_keyring.so auto_start
session include system-auth
Doing this did the trick!
Recently I was trying to get one of my OpenVZ instances to host a CUPS service for my entire domain. In order to do this the VE instance needs to know about the device files under /dev that relate to the printers I wanted to share. The device files I needed to share were for 2 USB printers. So I put the script below together to figure out what the current files are for the 2 USB printers on the HN and then create the necessary files within the VE and update the VE instance through the vzctl –details switch to reflect the devices for the printers.
NOTE: Some of the info on the OpenVZ wiki here offered some helpful guidance.
Bus 004 Device 008: ID 04f9:000d Brother Industries, Ltd HL-1440 Laser Printer
Bus 004 Device 004: ID 04a9:1069 Canon, Inc. S820
I was interested in adding these 2 devices so I used their ID …. strings to uniquely identify them from reboot to reboot. They’re identified in the $filterDevices variable in the add_usb_devices_to_ve.sh script below.
…. Continue reading → Getting CUPS and OpenVZ to Play Nice on CentOS 5 »»