Home > Support > Knowledge Base
Knowledge Base
 
Reset Search
Search
 

 

Knowledge

HOW TO: Preserve device permissions/settings with RealPort in Linux

« Go Back

Information

 
Problem Resolution

HOW TO: Preserve device permissions/settings with RealPort in Linux

Most newer Linux distribution versions and kernels now use UDEV for device creation. This means the settings applied via dgrp_cfg_node or dgrp_gui will no longer work to preserve device permissions/ownership.  For systems using UDEV all permissions are now set by UDEV, the driver dgrp_gui/dgrp_cfg_node permission settings no longer control these settings on newer kernels/distributions.

With UDEV, you can modify the permissions by modifying the RealPort UDEV script, called "10-dgrp.rules" in /etc/udev/rules.d.

Here are the default entries found in /etc/udev/rules.d/10-dgrp.rules:


	

KERNEL="tty_dgrp*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c" KERNEL="cu_dgrp*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c" KERNEL="pr_dgrp*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c"

The cu_dgrp devices have been deprecated for several years in Linux and are not used. Placing a hash (#) in front of this line will prevent the device creation.

The pr_dgrp devices are used for transparent/pass through printing. This is where there is a printer attached to the printer port of a terminal or PC using a tty device.

To change the UDEV rule syntax on the tty_dgrp* devices to set 666 permissions (typically used for getty):


	

# this will set all digi dgrp ttys KERNEL=="tty_dgrp*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c", GROUP="root", MODE="0666", OPTIONS="last_rule"

Example for configuring printer devices on specific ports:

# set ttyaa10-ttyaa15 ports (jacks 11-16) for printers
KERNEL=="tty_dgrp_aa_1[0-5]*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c", GROUP="lp", MODE="0666", OPTIONS="last_rule"

 

When using a wildcard rule (i.e.: "tty_dgrp*"), you will need to place that rule below rules setting specific ports. For example:


	

# set ttyaa10-ttyaa15 ports (jacks 11-16) for printers KERNEL=="tty_dgrp_aa_1[0-5]*", PROGRAM="/usr/bin/dgrp_udev %k", NAME="%c", GROUP="lp", MODE="0666", OPTIONS="last_rule" # this will set all digi dgrp ttys 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


Feedback

 

Was this article helpful?


   

Feedback

Please tell us how we can make this article more useful.

Characters Remaining: 255