Sponsored Content
Full Discussion: Perl Net::IP not working
Top Forums Shell Programming and Scripting Perl Net::IP not working Post 302964484 by yazu on Friday 15th of January 2016 02:41:20 AM
Old 01-15-2016
Yes it's a good one.
Code:
perl -e '
require Net::IP;
$str = "2620:0:2d0:200:0:0:0:7";
$ip = new Net::IP($str, 6);
print $ip->print, "\n";
'
2620:0:2d0:200::7/128

This User Gave Thanks to yazu For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

perl + Net::FTP::Recursive

Problem: It will not advance to the next user in the list. It always dies right after it sends the 2/2 files from the first users dir. $USERLIST="/export/home/mxdooley/perl_ftp/userlist"; $USER_DIR="/export/home/mxdooley/perl_ftp/homes";... (2 Replies)
Discussion started by: Optimus_P
2 Replies

2. Shell Programming and Scripting

Best place on the net to get Perl tutorials ?

I am looking for a full Perl course on internet (tutorial) to learn everything about Perl. I already know a bunch of programing languages. I have started Unix interests this year ever since I installed Ubuntu Linux on my PC AND I also got a job at IBM doing software distributions with... (1 Reply)
Discussion started by: Browser_ice
1 Replies

3. Shell Programming and Scripting

PERL: NET::FTP..>Debug Messages

HI All, NET::FTP->new($server, DEBUG=>1); I need to get all the Debug Messages in an array or a file.... Please suggest!! (0 Replies)
Discussion started by: angad.makkar
0 Replies

4. Shell Programming and Scripting

Corrupted Download with Net::FTP (perl)

Hello, I am trying to download several files from a remote FTP server using Net::FTP from within a perl script. The files download alright, except they appear to be corrupted. I know this because once after downloading, I use bzcat to pipe the files to a split command, and bzcat complains saying... (3 Replies)
Discussion started by: amcrisan
3 Replies

5. Shell Programming and Scripting

Net::SMTP via PERL is not working in few cases

We are getting some special scenarios where Net::SMTP is not working for some mails. we are sending a similar kind of data via mails but some of the mails are not received. After checking the Net::SMTP in debug mode we found below difference: Good One - (Mail sent properlly) --- -----... (0 Replies)
Discussion started by: NIMISH AGARWAL
0 Replies

6. Shell Programming and Scripting

Net::Ftp in perl

I am trying to execute a script in another server, i used Net::Ftp module How to execute unix command in another server by using Net::Ftp module.. #!/usr/bin.perl ### Perl script to $ftp->login($user_name,'password') or die "Cannot login ", $ftp->message;... (2 Replies)
Discussion started by: pritish.sas
2 Replies

7. Shell Programming and Scripting

Perl - Net::FTP issue

Wondering if anyone can help or advise on following issue. The below script should simply connect to a different server and retrieve certain files for me. use lib "/xxxxx/xxxxx/xxxxx/xxxx"; use Net::FTP; my $directory = "xxxxxxxx"; my $destinationDir = "xxxxxxxxx"; my $filePrefix =... (1 Reply)
Discussion started by: meevagh
1 Replies

8. Shell Programming and Scripting

Net::OpenSSH not working on Unix machine.

So, I installed the Net::OpenSSH module and I am having trouble getting it to work. It appears to be failing on this code: my $ssh = Net::OpenSSH->new('user:passwd@host.com'); $ssh->error and die "Couldn't establish SSH connection: ". $ssh->error; It's pretty simple code. I keep... (0 Replies)
Discussion started by: mrwatkin
0 Replies

9. Shell Programming and Scripting

Net::SSH::Perl slow to login.

I have some sample code that's supposed to ssh to another machine using Net::SSH::Perl, execute a command, and print the output of that command. It's very basic, and it works. However, I noticed that upon logging in: $ssh->login('username','password'); It takes roughly 10-13 seconds to... (2 Replies)
Discussion started by: mrwatkin
2 Replies

10. Web Development

Ssh authentication from .NET webpage to UNIX is not working

My .NET website invokes a perl script to perform GIT operations on Gerrit server running UBuntu. In the perl script I connect using passwordless authentication to Gerrit server as below: system ( "ssh gitadmin@gerritserver.com 'cd /xyz && git clone xxx' "); I verified that ssh authentication... (3 Replies)
Discussion started by: tkota
3 Replies
Net::DNS::Resolver::Recurse(3)				User Contributed Perl Documentation			    Net::DNS::Resolver::Recurse(3)

NAME
Net::DNS::Resolver::Recurse - Perform recursive dns lookups SYNOPSIS
use Net::DNS::Resolver::Recurse; my $res = Net::DNS::Resolver::Recurse->new; DESCRIPTION
This module is a sub class of Net::DNS::Resolver. So the methods for Net::DNS::Resolver still work for this module as well. There are just a couple methods added: hints Initialize the hint servers. Recursive queries need a starting name server to work off of. This method takes a list of IP addresses to use as the starting servers. These name servers should be authoritative for the root (.) zone. $res->hints(@ips); If no hints are passed, the default nameserver is asked for the hints. Normally these IPs can be obtained from the following location: ftp://ftp.internic.net/domain/named.root recursion_callback This method is takes a code reference, which is then invoked each time a packet is received during the recursive lookup. For example to emulate dig's "+trace" function: $res->recursion_callback(sub { my $packet = shift; $_->print for $packet->additional; printf(";; Received %d bytes from %s ", $packet->answersize, $packet->answerfrom ); }); query_dorecursion This method is much like the normal query() method except it disables the recurse flag in the packet and explicitly performs the recursion. $packet = $res->query_dorecursion( "www.netscape.com.", "A"); IPv6 transport If the appropriate IPv6 libraries are installed the recursive resolver will randomly choose between IPv6 and IPv4 addresses of the nameservers it encounters during recursion. If you want to force IPv4 transport use the force_v4() method. Also see the IPv6 transport notes in the Net::DNS::Resolver documentation. AUTHOR
Rob Brown, bbb@cpan.org SEE ALSO
Net::DNS::Resolver, COPYRIGHT
Copyright (c) 2002, Rob Brown. All rights reserved. Portions Copyright (c) 2005, Olaf M Kolkman. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. $Id: Recurse.pm 1096 2012-12-28 13:35:15Z willem $ perl v5.18.2 2014-01-16 Net::DNS::Resolver::Recurse(3)
All times are GMT -4. The time now is 05:08 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy