USA Linux Users Group Forum Index
Log in Register FAQ Memberlist Search USA Linux Users Group Forum Index Album

[AS400] Installing tn5250j on linux for the as400

 
Post new topic   Reply to topic   printer-friendly view    USA Linux Users Group Forum Index » Networking
View previous topic :: View next topic  
Author Message
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Wed Mar 09, 2024 4:52 pm    Post subject: [AS400] Installing tn5250j on linux for the as400 Reply with quote

For work I needed to install the tn5250j client to connect to the as400 here. I decided I'd just post the method I used in case someone else needed it. (google searches Wink )

Code:

mkdir downloads
cd downloads
wget http://umn.dl.sourceforge.net/sourceforge/tn5250j/tn5250j-install-0.5.7.jar
java -jar tn5250j-install-0.5.7.jar
cd ..
cd tn5250j
cd bin
chmod a+x tn5250j




.
.



The website for the tn5250j as400 client is http://tn5250j.sourceforge.net



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11


Last edited by crouse on Fri Sep 22, 2024 7:46 pm; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website AIM Address
Hammer
New Member


Joined: 10 Jun 2024
Posts: 44
Location: Tennesse, USA

PostPosted: Wed Mar 09, 2024 5:55 pm    Post subject: Reply with quote

Thanks crouse, I have alot of customers that have as400 and love linux but are forced to use other emulators. This should work great for them.

BTW what model as400 are you connecting to. I am employed by IBM and work on all as400 models and some of the largest main frame we make, Linux, Aix, MVS, os/400.


Back to top
View user's profile Send private message
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Thu Mar 10, 2024 12:24 am    Post subject: Reply with quote

I have no idea yet Very Happy Very Happy It should be here Friday ..... so I'll be working on getting it up and running on Friday and Saturday. I'll let you know once I have it here .... I just know it's coming Laughing



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Tue Mar 15, 2024 4:55 pm    Post subject: Reply with quote

a quick note ...... needed to have two ip addresses running on eth0 for this to work with internet and the as400 ....... here is the command I USED

Code:

ifconfig eth0:0 192.168.2.XXX netmask 255.255.255.0 up


where xxx is the local ip address needed for each machine.



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Wed Mar 16, 2024 4:25 pm    Post subject: Reply with quote

Okay..... here is the script and it is put in
/etc/sysconfig/network/if-up.d/
as
/etc/sysconfig/network/if-up.d/as400startup.sh

NOTE: the script must be executable
as root
cd /etc/sysconfig/network/if-up.d/
chmod a+x as400startup.sh

The script (mostly notes to myself lol .......
Code:

#!/bin/bash
#/etc/sysconfig/network/if-up.d/as400starup.sh
# 03-16-2005 Crouse
# Script to make the tn5250j work
# This line adds IP address to network card
# ifconfig eth0:0 192.168.2.XXX netmask 255.255.255.0 up
# where XXX is the static IP address of the card
# the normal IP address would be the dhcp setting sent by the internet router
# this config will create a second IP to allow connection automatically at boot to the AS400
# Below are the list of Fixed IP addresses for our machines
#
# The as400 is on 192.168.2.5
#
# Crouse 192.168.2.101
# Toms 192.168.2.102
# Jasons 192.168.2.103
# Randys 192.168.2.104
# Bobs 192.168.2.105
# Dons 192.168.2.106
# Counter 192.168.2.107
#
# Starting the new ip now
ifconfig eth0:0 192.168.2.101 netmask 255.255.255.0 up


This starts the as400 network ip on bootup. This in essence creates 2 IP's on 1 network card. 1 created by the dhcp from the router, and this one, used specifically for the as400's network.

Seems to work fine.
This may never help anyone .... but just in case, I decided to post it anyway. Smile



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Tue Nov 22, 2024 9:48 pm    Post subject: Reply with quote

New url and newer version

Code:
wget http://voxel.dl.sourceforge.net/sourceforge/tn5250j/tn5250j-install-0.6.0.jar



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Tue Nov 22, 2024 10:53 pm    Post subject: Reply with quote

hmmmm i keep getting these errors.......
Code:

[crouse@localhost bin]$ java tn5250j
Exception in thread "main" java.lang.NoClassDefFoundError: tn5250j


with the newer version...... going to try the old version again.....



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Mon Dec 12, 2024 8:48 pm    Post subject: Reply with quote

OK------- UPDATE

----------------------------

after some work, using the bash
shell, I can start up the client with:

nohup java -jar /home/crouse/tn5250j/lib/tn5250j.jar 2>>error.log &

I setup and alias in my .bashrc file
Code:

alias tn5250j='nohup java -jar /home/crouse/tn5250j/lib/tn5250j.jar
2>>error.log &'



This seems to work. The original bash/shell startup file, appears to be
formatted/written in a DOS enviroment.

---------------
#! /bin/sh

# Runs the tn5250j 5250 java emulator

# Sets the tn5250j home directory
TN5250J_HOME='/home/crouse/tn5250j'

# Change to the emulator's directory
cd ${TN5250J_HOME}/

# Does the effective launching
java -jar "lib/tn5250j.jar"
---------------

Changing line #1 to
#!/bin/bash

and running with sh or ./tn5250j appears to work, but doesn't but the job
in the background. Using nohup accomplishes this and appears to work fine.

Thanks jbsnake for the help in irc.



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Fri Nov 09, 2024 5:59 pm    Post subject: Reply with quote

http://superb-east.dl.sourceforge.net/sourceforge/tn5250j/tn5250j-install-0.6.0.jar



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
mmmna
. . . .


Joined: 21 Apr 2024
Posts: 7224

PostPosted: Fri Nov 09, 2024 11:14 pm    Post subject: Reply with quote

I knew you were a guru at this 5250 stuff!! Wink
In the first post, I get 'broken image' images. Did you move the images to the new photo software? If so, maybe relink the original post to the new photos?



_________________
-Kubuntu 10.04 LTS Beta2 on Celeron D desktop
-PCLinuxOS 2024 LXDE on EeePC 900A with Atom n270 (modded with 32G SATA drive and 2G ram).
Back to top
View user's profile Send private message
crouse
Site Admin


Joined: 17 Apr 2024
Posts: 11833
Location: Iowa

PostPosted: Fri Nov 09, 2024 11:19 pm    Post subject: Reply with quote

I don't think i even have the old photos...... i should fix that..... Wink Give me a few days, i might find them again.



_________________
Veronica - Arch Linux 64-bit -- Kernel 2.6.33.4-1
Archie/Jughead - Arch Linux 32-bit -- Kernel 2.6.33.4-1
Betty/Reggie - Arch Linux (VBox) 32-bit -- Kernel 2.6.33.4-1
BumbleBee - OpenSolaris-SunOS 5.11
Back to top
View user's profile Send private message Visit poster's website AIM Address
joshwilson_1
Advanced Member


Joined: 19 Jan 2024
Posts: 823

PostPosted: Tue Feb 19, 2024 9:03 pm    Post subject: Reply with quote

Thanks for the 5250 work in Linux. I have a Dell laptop and I would like to get a 5250 emulator on it as I work a lot of greenscreen at the office for our AS400.


Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    USA Linux Users Group Forum Index » Networking All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All content © 2024-2009 - Usa Linux Users Group
This forum is powered by phpBB. © 2024-2009 phpBB Group
Theme created by phpBBStyles.com and modified by Crouse