Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title How do I connect my QNX2 machine to my QNX4 machine?
Ref. No. QNX.000009325
Category(ies) Utilities
Issue I'm migrating to QNX 4 but need to continue using some of the programs and files on my existing QNX 2 network. How can I access these from the QNX 4 nodes that I'm setting up?
Solution With the release of QNX 4.0, we provided a migration facility that lets you use qtalk or qterm to log into a QNX 2 session from a QNX 4 session (or vice versa). You can also transfer files between the two versions of QNX. For this migration facility to work, the QNX 2 and QNX 4 nodes must reside on the same physical Arcnet network.

This facility is also available for QNX 4.1, but note that the migration utilities are version-specific: the 4.0 migration package won't work with QNX 4.1, and the 4.1 package won't work with QNX 4.0.

To establish the link between your QNX 4 and QNX 2 machines, you need to configure a "server" on each side (the QNX 2 server must be running QNX 2.15G or later). To configure these servers, you modify their sysinit files.

Configuring the QNX 2 server

Modify the sys.init.node file of the QNX 2 server as follows:

1x09To set up the QNX 2 to QNX 4 network device link, add this command:

x09netdev -c num_channels -n QNX4_node_to_talk_to &

For more on netdev, see your Migration Guide.

2x09To ensure reliable data transmission, add:

x09x09stty +hflow >$netchannel

3x09To set the terminal type to qnx4 (provided in the migration kit) so you can run full-screen programs and use function keys, add:

x09x09tset qnx4 >$netchannel

4x09To handle the increased number of nodes on the network, update your tcap entries, if necessary. Otherwise, you may encounter problems when setting terminal types. For more information, see tcap in the QNX 2 Reference Guide.

Configuring the QNX 4 server

Modify the sysinit.node file of the QNX 4 server as follows:

1x09To set up the QNX 4 to QNX 2 network device link, add this command:

x09Dev.net -c num_channels -n QNX2_node_to_talk_to &

x09Note that the number of channels (option -c) must be the same number specified to netdev on QNX 2. For more on Dev.net, see your Migration Guide.

2x09To implement qnx2 terminal emulation on all the QNX 4 netlinks, add "-c "termdef qnx2" and "-T /dev/net? /dev/net??" to the tinit line of the sysinit.node file. For example:

x09x09tinit -t /dev/con1 -T /dev/con* -c "termdef qnx2"
x09x09-T /dev/net? /dev/net?? &

Once you've added the above commands to the sysinit files on QNX 2 and QNX 4, reboot both machines.

Logging in

You're now ready to log into QNX 2 from QNX 4, or vice versa:

To log into:x09enter this command:

QNX 2 from QNX 4x09qtalk -E -m/dev/$netchannel
x09(then press <Ctrl>-<Z>)

QNX 4 from QNX 2x09qtalk +E m=$netchannel
x09(then press any key)

Copying files

To copy files between QNX 2 and QNX 4, use qcp. It will behave just as if it were running across a modem, even though the communications media is actually Arcnet.

The netdev link is designed primarily for interactive use and may lock up if a control packet is lost. If the link seems to lock up, check the settings on the port. To do so from QNX 2, you would enter:

x09stty <$netchannel

From QNX 4, you would enter:

x09stty </dev/netchannel

If you see any paged options set, clear them to unlock the session. From QNX 2, you would enter:

x09stty -paged >$netchannel

From QNX 4, you would enter:

x09stty ihpaged -ohpaged </dev/netchannel

Your QNX 4 and QNX 2 machines should now be able to communicate.