My Server's Continuous Uptime: 143 days, 19 hours, 9 minutes
Sep 21

I ran into an issue recently where any application would crash when printing to a network printer. Our environment is unique in that we are printing to a Windows print server (using Guest privileges), but users on the network are logging in using the Novell client.

The crash would not happen with generic Microsoft drivers that came with Windows XP, but it would happen with any HP-branded drivers. Our first workaround was just to use PCL or PostScript drivers that closely matched the printer, and hope for the best.

In the end, we found out that when printing with the HP drivers, it would write to a file in the Windows directory called hpmnwun.ini. The contents it would write were:


[NWUSERNAME]
NOVELL=1
NWUSERNAME=testuser

Fixing the issue was a two step process:

1: Erase the contents of the file
2: Change the NTFS Permissions of the file to make it read-only by all users (even Administrators)

I think this forces the HP drivers to print to the printer in the standard Windows printer sharing way. When the HP drivers detect the Novell client installed, it writes the NWUSERNAME info to the file and must try to print in an ‘NDPS friendly’ way, which causes the application to crash when printing to a standard Windows shared printer and not a NDPS printer.

written by eppler

Jul 09

After a little searching, I found out you can add printers to OS X from the command line using this syntax:

lpadmin -p Printer_Name -L "Printer Location" -E -v lpd://x.x.x.x -P /Library/Printers/PPDs/Contents/Resources/en.lproj/Printer_Driver.gz

If you don’t specify the -P option, it will not show up in your Print or Printer Setup dialogs. If you want to include the generic PPD, it is located here:

/System/Library/Frameworks/ApplicationServices.framework/Versions \ /A/Frameworks/PrintCore.framework/Versions/A/Resources/Generic.ppd

That path is all one line, with no spaces.

written by eppler

May 08

About a week ago I installed Dropbox, and I have to recommend it to anybody who needs to sync their files between machines. I have a group of Macs that I use to sync data between, and I used to use iDisk, but Dropbox is so much quicker that I can’t see myself using iDisk anymore. Also, the syncing between Linux and Mac OS X works great – I haven’t got a chance to test the Windows client yet, but I’m sure it works just as good.

If you sign up with this link, you’ll get an extra 256MB, and so will I.

written by eppler

Mar 17

With Windows XP, you can define custom paper sizes (such as 3×5 cards) by doing the following:

Start -> Printers and Faxes -> File -> Server Properties

In this dialog, you can define a 3×5 card. The problem is, with the LQ-590 and LQ-300 drivers, these paper sizes do not show up as options when you try and print. Any paper size below 4 inches in height will disappear from your printing options.

To get around this, install the LQ-570 driver (the one that is built into Windows XP). This driver will let you use a 3×5 sized form.

written by eppler

Oct 26

When connecting to AFP shares in the new Mac OS X 10.5 (Leopard), you may get a -5002 error when the server only supports clear text passwords. To resolve, either disable clear text passwords on the server side, or change the following plist:

~/Library/Preferences/com.apple.AppleShareClient.plist

You need to change the afp_cleartext_allow value to “Yes” “true” or “1″ (depending on the current values you see, either “false” or a “0″).

Here’s an excerpt from my file:


...
<key>afp_cleartext_allow</key>
<true />
<key>afp_cleartext_warn</key>
<integer>0</integer>
<key>afp_default_name</key>
<string></string>
...

written by eppler

Feb 20

When you are trying to view a QuickTime movies from a streaming server, sometimes you will get back a 400 Bad Request error.  At my network at work, we intercept all port 80 traffic and forward to our squid proxy server, which is why we get this error.  In order to fix this, just open up System Preferences, open the QuickTime pane, click the Advanced tab, and choose Custom… under the Transport Setup dropdown.  Choose HTTP as your protocol, and type in 7070 where is says Other.  Since making this modifications, we can view the QuickTime streams with no problems.

written by eppler

Jun 14

The newest version of WebTester, my online testing and quizzing software, has been released, along with a completely new site re-design. You can check out the site here:

WebTester Home

Feel free to check out the newly created forums:

WebTester Forums

Or, you can log into the demo, using the following information:

Username: admin
Password: admin

WebTester Admin
WebTester Engine

Take a look and tell me what you think.

written by eppler

Apr 17

Sometimes, Adobe InDesign will crash when trying to print on a user account with a networked home folder under Mac OS X. Here is the fix that I use:

ditto -rsrc /System/Library/Printers /Library/Printers

I send that command to all computers with the problem via ARD (Apple Remote Desktop) and it seems to resolve all of the issues.

If that doesn’t work, you need to copy or create a Printers folder in the current users Library folder. Drop into Terminal and type the following:

mkdir ~/Library/Printers

Those two methods have resolved most of our InDesign printing issues.

written by eppler

Apr 04

Here at the school district I was running into a problem where if several Mac OS X wireless clients logged into the network at once, everything slowed down to a crawl. After researching the problem, it looked like the user’s Library and Microsoft User Data folders were causing the problem. I tried turning on OS X’s home folder syncronization, but that didn’t work very well, and filled up our older computers fast. The solution I found was to locally cache the user’s Library and Microsoft User Data folder. To do this, create a symbolic link from the user’s networked ‘Library’ folder and point it to a local source. I chose /tmp/UserCache/username/Library. Here is the login script I created to automate the process:

#! /bin/bash

# Create local user caches of important directories
# Written by Steven Eppler 04/04/2006

export PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin

# Set user variable
user="$1"

# This grabs the user's home directory server
input=`dscl localhost read Search/Users/$user NFSHomeDirectory`
nethomedir=${input:18}

# Or you can hardcode it...
# nethomedir="/Network/Servers/ServerName/Volume/$user"

# Check for blank nethomedir - otherwise you will delete
# the root /Library folder!
if [ """$nethomedir""" != "" ]; then

echo $user
echo $nethomedir

# Create local caching directories
mkdir /tmp/UserCache
mkdir /tmp/UserCache/$user
mkdir /tmp/UserCache/$user/Microsoft\ User\ Data
mkdir /tmp/UserCache/$user/Library

# Give everyone rights to them...
chmod -R ugo=rwx /tmp/UserCache

# Create Documents and Desktop folder (sometimes they don't exist)
mkdir $nethomedir/Documents
mkdir $nethomedir/Desktop

# Delete old folders or links
rm -rf $nethomedir/Library
rm -rf $nethomedir/Documents/Microsoft\ User\ Data

# Create new links
ln -s /tmp/UserCache/$user/Library $nethomedir/Library
ln -s /tmp/UserCache/$user/Microsoft\ User\ Data $nethomedir/Documents/Microsoft\ User\ Data

fi

written by eppler

Mar 28

As posted previously, I have been working on porting my WebTester program from ASP to PHP. New features include:

  • Ability to randomize questions
  • Integrated HTML Editor (no more manual coding)
  • ‘Enter’ key selects Next instead of Previous
  • Ported from ASP to PHP (so it can be hosted on a Mac/Linux/Windows box, instead of limited to Windows/IIS)
  • Generates math equations on the fly, by converting LaTeX math code into a graphic, such as:
  • General UI enhancements

To give it a spin, try out the test server. Here are the addresses:

Take a test: http://webtester.epplersoft.com
Administration: http://webtester.epplersoft.com/admin

The username/password combination to use is: demo/demo

This is not the final, so bugs may exist that have already been fixed. To generate math while creating a test, use the following format:

[tex]a^2 + b^2 = c^2[/tex]

The above will generate this image:

To create your own equations, you can try out a program called MathType by Design Science. I will also list other LaTeX generating programs as I find them.

If you have any questions, just leave a comment.

written by eppler