Dynamic assigend IP addresses



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Dynamic assigend IP addresses

Postby Beauxti » Thu Jun 13, 2013 12:33 am

I think the answer is no - but going to ask anyway- I have a situation where IP addresses are hard-coded in JCL. Not just one or to JCL sources but thousands. It did not get this way overnight, but years of little bit at a time. Now I have to change them as we are moving Systems around (just trust me on this, we have to change them) . Is there a feature / Utility / Function in JCL that would allow me to create a Dataset of IP address and have the JCL access the data set for the correct IP address to use at run time. Just trying to figure out a way NOT to do this in the future, but allow some simple mapping to be managed in the dataset. Thanks in advance for and and all help!
Beauxti
 
Posts: 2
Joined: Thu Jun 13, 2013 12:00 am
Has thanked: 0 time
Been thanked: 0 time

Re: Dynamic assigend IP addresses

Postby Akatsukami » Thu Jun 13, 2013 12:45 am

I can't think of any case where JCL uses an IP address; it's quite possible that they are being used in control cards that are being miscalled JCL, as is so often the case. If so, a direct use of such a data set would depend on the program; you could probably write a Rexx scriptette to pick out the wanted IP address and edit the control cards.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: Dynamic assigend IP addresses

Postby Robert Sample » Thu Jun 13, 2013 1:07 am

If you are asking about dynamically changing the IP address when the job is executed, I don't think there is any way to do that -- IP addresses get passed to TCP/IP and I'm not aware of any exits to change them before use. And, after all, the whole point of using DNS entries instead of IP addresses is that if the IP address changes then the DNS entry gets updated and nothing else (such as JCL) needs to be modified.

Depending upon how many you have, either manual edit of the JCL or a program (in the language of your choice) to scan the JCL lines, find IP addresses, and change them to (hopefully DNS entries) their new values would be the best way to proceed.
Robert Sample
Global moderator
 
Posts: 3719
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: Dynamic assigend IP addresses

Postby dick scherrer » Thu Jun 13, 2013 8:50 pm

Hello and welcome to the forum,

In the forum there are some examples of editing a pds and changeing a value to some other value in all of the members.

This might save you lots of manual editing (with the assiciated risk of typos). Suggest you search in the REXX part of the forum.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Dynamic assigend IP addresses

Postby Ed Goodman » Fri Jun 14, 2013 7:55 pm

Yes, yes there is...it's called a DNS. You have your network folks add these machines as named destinations. For example, your mail server for the shipping department becomes shipping.mail.server instead of 10.4.128.9. That gets put into a DNS and and when the FTP or whatever tries to read the host name, it gets the IP address.

It's all standard stuff and it saves a ton of headaches like this.
Ed Goodman
 
Posts: 341
Joined: Thu Feb 24, 2011 12:05 am
Has thanked: 3 times
Been thanked: 17 times

Re: Dynamic assigend IP addresses

Postby dick scherrer » Fri Jun 14, 2013 8:01 pm

Hello,

If your organization can be convinced to fo to DNS (the preferred way to do this), your process would still be used for the "switch".
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Dynamic assigend IP addresses

Postby Beauxti » Wed Jun 26, 2013 9:51 pm

THANKS team for the feed back -DNS it is. Still don't like hard coding that either, even with the added abstraction feature.
Beauxti
 
Posts: 2
Joined: Thu Jun 13, 2013 12:00 am
Has thanked: 0 time
Been thanked: 0 time


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post