[CentOS-devel] /dev/pts/??
Dag Wieers
dag at centos.org
Tue Dec 30 04:27:16 UTC 2008
On Mon, 29 Dec 2008, Michel Donais wrote:
>> A pts device is also a tty. I have troubles understanding what you want to
>> achieve (and to be frank, none of your mails are explaining), but if the
>> problem is that your application is SCO-centric and cannot work with pts
>> devices, then you'll have to find the source code or ask your vendor.
>
> You've got it; the application is SCO-centric
> The application need to find a /dev/tty01 or more but can't work with
> dev/pts/1.
If you run the application as root, you could create a device node that is
identical to the real device as /dev/tty01 (since Linux uses /dev/tty1
they will not clash).
This can only work if you understand how the application is constructing
/dev/tty01 (I am sure this is not hardcoded, because that would not even
work on SCO).
> The developper is no more active and I don't have the sources.
> One of my last resource is to find a way to start a terminal and have Centos
> allowing me to start the application on a terminal as tty instead of a
> pseudo-terminal.
Even on SCO the application needs to figure out its own tty. So there
should be a way to influence its decision. I don't even understand why it
would go with /dev/tty01 over an SSH connection, unless it is hardcoded as
a silly fallback default if all other measures have failed.
Finding what these other measures are, may be the source of a solution ?
>> (Or simply log on to the console instead of using SSH ?)
> This haven't been tried, and I will to morrow; but our best will be to use
> it a text terminal.
You can also tru using 'conspy' to take over the real /dev/tty1 from an
SSH or screen session and then start the SCO application. However if the
SCO application expects /dev/tty01 then that would fail similarly.
Creating a device node identical to the current tty is probably the best
way forward if it really is /dev/tty01. You can do this simply by doing:
cp -aLv /proc/self/fd/0 /dev/tty01
or maybe a symlink would work as well:
cp -av /proc/self/fd/0 /dev/tty01
The advantage if a symlink is simply that you have a visual confirmation
to what tty it is linking without having to decipher the major and minor
device numbers.
>> Not sure what your application is doing to, try stracing it to find out.
> There is no possibility to trace at start-up.
Man, aren't you glad that your SCO days are (almost?) (finally?) over ? ;-)
--
-- dag wieers, dag at centos.org, http://dag.wieers.com/ --
[Any errors in spelling, tact or fact are transmission errors]
More information about the CentOS-devel
mailing list