Bulk Role create using script

Hello All,

Good day,

I am trying to create Bulk roles and role assignment using CSV, where I followed below steps, But when I tried to run the ruby script, I am facing thebelow issue.

C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in initialize': Failed to open TCP connection to xxxx.api.identitynow.com:443 (getaddrinfo: No such host is known. ) (Socket::ResolutionError) from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in open’
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in block in connect' from C:/Ruby33-x64/lib/ruby/3.3.0/timeout.rb:186:in block in timeout’
from C:/Ruby33-x64/lib/ruby/3.3.0/timeout.rb:193:in timeout' from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1601:in connect’
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1580:in do_start' from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1569:in start’
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:2297:in request' from C:/Users/XXXX/Documents/Scripts/Role-Importer/roleImporter.rb:90:in create_header’
from C:/Users/XXXX/Documents/Scripts/Role-Importer/roleImporter.rb:898:in <main>' C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in initialize’: getaddrinfo: No such host is known. (Socket::ResolutionError)
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in open' from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1603:in block in connect’
from C:/Ruby33-x64/lib/ruby/3.3.0/timeout.rb:186:in block in timeout' from C:/Ruby33-x64/lib/ruby/3.3.0/timeout.rb:193:in timeout’
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1601:in connect' from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1580:in do_start’
from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:1569:in start' from C:/Ruby33-x64/lib/ruby/3.3.0/net/http.rb:2297:in request’
from C:/Users/XXXX/Documents/Scripts/Role-Importer/roleImporter.rb:90:in create_header' from C:/Users/XXXX/Documents/Scripts/Role-Importer/roleImporter.rb:898:in

https://community.sailpoint.com/t5/Professional-Services/IdentityNow-Bulk-AccessProfile-and-Role-Importer/ta-p/77382

Thanks,
Jagan.M
.

Hi Jagan, it appears that you have a connection error, nothing related with specific script. Try a telnet from there you are running your script.

Also takes my attention this line:

getaddrinfo is an operative system call, it appears that it can not resolve the hostname. Anyway, can you show the result of telneting the tenant hostname and port?

Hi,

I think also it’s the opening traffic problem

Thank you Julian Sosa,

Connection failed , when I tried do telnet.

.

Thanks,
Jagan.M

I believe for telnet you need to specify the command as such:

telnet

Example:

telnet partner1234.identitynow.com 443

You can also try curl or something similar.

1 Like

Hello Edwin, its my bad, I tried that one too, same result

Thanks,
Jagan.M

Can you try without the full url, since this is only about base level connectivity

You are doing now:

telnet https://.identitynow.com/v3 443

Please try:

telnet .identitynow.com 443

2 Likes

here it is , result is same.

@molagavallijagan remove /v3 in your last test :

telnet hostname port

example : telnet sailpoint.api.identiynow.com 443

You can asso use openssl :

openssl s_client -connect sailpoint.api.identiynow.com:443

It looks like you’re running the script from private network.

Did you try running it from your company/personal device (that has public network)?

It looks like either the DNS is not able to resolve the host or TCP 443 port is blocked for you.

It looks like your network allows http outgoing connection only via proxy which you didn’t co figure. Try to configure proxy or use postman with proxy configured to see if you can connect.

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.