dgrp not creating devices

Our company purchases many portservers. Our customers use them mainly for printing and modems. We mainly use PortserverII. Our servers are installed w/ RedHat EL5 for 64bit.
Our kernel version is 2.6.18-164. Our dgrp software version is dgrp-1.9-17.

The problem is that we have multiple facilities just converted from Sco Unix to Redhat Linux where none of the devices are getting created on install or when /usr/bin/dgrp/dgrp_cfg_node is run. I have tracked down the problem and it is in /usr/bin/dgrp/dgrp_mk_specs:


if [ -f /proc/dgrp/info ]
then
        register_with_sysfs=`cat /proc/dgrp/info | grep register_with_sysfs | awk '{print $2}'`
        if [ $register_with_sysfs -eq 1 ]
        then
                pid=`ps -ef | grep udevd | grep -v grep | awk '{print $2}'`
                # There could be many udevd daemons running,
                # just grab the first pid, if any.
                pid=`echo $pid | awk '{print $1}'`
                if [ ! -z $pid ]
                then
                        exit 0
                fi
        fi
fi

It appears that script is trying to make sure that udev is running but, then exit’s if it is. WHY???
In the script the section is preceded by this:

# SYSFS/UDEV check.
#
# If SYSFS exists, and the driver is set up to
# register its ttys through it, then we do not
# need to create the devices here.
#
# SYSFS/UDEV will do it automatically.
#
# So check to see if the driver is going to register
# its ttys with SYSFS or not, then check to make sure
# the system is running a UDEV daemon or some sort.

I have fixed our problem by removing the ! from this line:

if [ ! -z $pid ]

If this happens the script continues and creates the devices.
It seems like it is trying to find a udev daemon and make sure it’s not running.
My question is, Is this bad? Is there a reason we want to exit out if udev is running.? Why is this not happening at other facilities with the same script and the same set-up? This has only started popping up recently.

I found this thread
http://www.digi.com/support/forum/viewthread_thread,3846
that details a similar problem and userid0 explained using the newer driver would resolve it. We updated to the newer driver and it did not resolve the issue. The dgrp_mk_specs script is exactly the same in that source. Any help would be greatly appreciated.

The issue here is not related to the Debian/Ubuntu thread (the new driver specifically addressed the Debian and Ubuntu distributions).

This sounds like a UDEV issue on this host. Can you post a typescript of the driver compilation/installation?

Are any errors seen in /var/log/messages?

If you run udevmonitor while starting the RealPort daemon are there any errors seen?

Found it. Thanks for all the help. We have found that an inadvertent ‘awk’ went out on some of our systems. udevtest was helpful in finding the problem. It seems to be that /usr/bin/dgrp_udev on line 27,28, and 29 pipes into an awk command. I am assuming that the direct PATH of awk is found in the rpmbuild and placed in the dgrp_udev script. It was pointing to the wrong awk in the $PATH. I corrected the script and it is correctly making the tty’s now. Thanks for the help.