Fedora Core 4 & udev

Hi all,

I am having some trouble setting some file permissions on my digi port tty. At bootime I chowm 666 /dev/ttyb00 and same for /dev/ttyb01 , I have a 2 port digi neo server, this works fine until the dgrp_daemon service is restarted and the permissions get lost for group and others. I have read a few of the posts in this forum and tried to add the MODE=“0666” in the 10-dgrp.rules and restarted the service but no luck. Could someone point me in the correct direction? I am hoping to get this working and tested on FC4 so that I can update my Red Hat Enterprice 5 box as it also has the same issue.

Heres some info.

This is output while unloading and loading the module.

udevmonitor
udevmonitor prints the received event from the kernel [UEVENT]
and the event which udev sends out after rule processing [UDEV]

UEVENT[1198036162] remove@/class/tty/tty_dgrp_b_1
UEVENT[1198036162] remove@/class/tty/cu_dgrp_b_1
UEVENT[1198036162] remove@/class/tty/pr_dgrp_b_1
UEVENT[1198036162] remove@/class/tty/tty_dgrp_b_0
UEVENT[1198036162] remove@/class/tty/cu_dgrp_b_0
UEVENT[1198036162] remove@/class/tty/pr_dgrp_b_0
UDEV [1198036162] remove@/class/tty/tty_dgrp_b_1
UDEV [1198036162] remove@/class/tty/pr_dgrp_b_1
UDEV [1198036162] remove@/class/tty/cu_dgrp_b_1
UDEV [1198036162] remove@/class/tty/tty_dgrp_b_0
UDEV [1198036162] remove@/class/tty/cu_dgrp_b_0
UDEV [1198036162] remove@/class/tty/pr_dgrp_b_0
UEVENT[1198036334] add@/class/tty/tty_dgrp_b_0
UEVENT[1198036334] add@/class/tty/cu_dgrp_b_0
UDEV [1198036334] add@/class/tty/cu_dgrp_b_0
UEVENT[1198036334] add@/class/tty/pr_dgrp_b_0
UEVENT[1198036334] add@/class/tty/tty_dgrp_b_1
UEVENT[1198036334] add@/class/tty/cu_dgrp_b_1
UEVENT[1198036334] add@/class/tty/pr_dgrp_b_1
UDEV [1198036334] add@/class/tty/tty_dgrp_b_0
UDEV [1198036334] add@/class/tty/cu_dgrp_b_1
UDEV [1198036334] add@/class/tty/tty_dgrp_b_1
UDEV [1198036334] add@/class/tty/pr_dgrp_b_0
UDEV [1198036334] add@/class/tty/pr_dgrp_b_1

cat 10-dgrp.rules
KERNEL==“tty_dgrp*”,PROGRAM=“/usr/bin/dgrp_udev %k”, NAME=“%c”, MODE=“0666”
KERNEL==“cu_dgrp*”, PROGRAM=“/usr/bin/dgrp_udev %k”, NAME=“%c”
KERNEL==“pr_dgrp*”, PROGRAM=“/usr/bin/dgrp_udev %k”, NAME=“%c”

service dgrp_daemon restart
Stopping DGRP daemons:
Daemon for id “a” (192.168.0.212): stopped.
Daemon for id “b” (192.168.0.211): stopped.
Starting DGRP daemons:
Daemon for id “a” (192.168.0.212): started.
Daemon for id “b” (192.168.0.211): started.
[root@neptune dev]# l ttyb*
crw------- 1 root root 252, 0 Dec 19 14:22 ttyb00
crw------- 1 root root 252, 1 Dec 19 14:22 ttyb01

dmesg | grep dgrp
dgrp: Digi RealPort driver version: 1.9-17

lsmod | grep dgrp
dgrp 98364 2

modinfo dgrp
filename: /lib/modules/2.6.17-1.2142_FC4smp/misc/dgrp.ko
description: RealPort driver for Digi’s ethernet-based serial connectivity product line
author: Digi International, http://www.digi.com
license: GPL
srcversion: 3972645A98C7DC703046C68
depends:
vermagic: 2.6.17-1.2142_FC4smp SMP mod_unload 686 REGPARM 4KSTACKS gcc-4.0parm: rawreadok:Bypass flip buffers on input (int)
parm: register_cudevices:Turn on/off registering legacy cu devices (int)
parm: register_prdevices:Turn on/off registering transparent print devices (int)
parm: net_debug:Turn on/off net debugging (int)
parm: mon_debug:Turn on/off mon debugging (int)
parm: comm_debug:Turn on/off comm debugging (int)
parm: tty_debug:Turn on/off tty debugging (int)
parm: ports_debug:Turn on/off debugging of /proc/dgrp/ports (int)

Try the following UDEV rule syntax:

KERNEL==“tty_dgrp*”, PROGRAM=“/usr/bin/dgrp_udev %k”, NAME=“%c”, GROUP=“root”, MODE=“0666”, OPTIONS=“last_rule”

Test the permissions:

  1. Run “udevcontrol reload_rules”
  2. /etc/init.d/dgrp_daemon restart

Thanks! that worked very well.

Geo