libssh2 version 1.2.9 or higher required for set_timeout support - windows

I am trying to use Net::SSH2 in the following the Perl code, but I am getting this error
libssh2 version 1.2.9 or higher required for set_timeout support at test.pl line 8.
1.2.566053SSH-2.0-libssh2_1.2.5
Press any key to continue . . .
use strict;
use Net::SSH2;
#use Net::SSH2::Expect;
my $Hostname = 'xxxxxxxxxx';
my $ssh = Net::SSH2->new();
print $ssh->version();
$ssh->timeout( 10 );
#$ssh->connect( "xxxxxxxx" );
I can see that my libssh2 version is old. Can somebody please help me with how to upgrade the libssh2 version?

I would highly recommend upgrading your version of Perl, using a native Windows application. If you install the most recent version of Strawberry Perl (5.24.1.1 at time of writing), it includes libssh2-1.7.0. It then allows you to successfully build, install and use Net::SSH2.
Here's the output of your code:
c:\>perl ssh.pl
1.7.067328SSH-2.0-libssh2_1.7.0
It appears as though it's been in the builds for a while, but if you're upgrading, I'd go latest and greatest.

Related

Installing gcc on s390x

I need a C compiler on my s390, which runs RHEL 7.6. When I do "yum list | grep gcc", I have the following:
libgcc.s390x 4.8.5-36.el7
compat-gcc-44.s390x 4.4.7-8.el7
compat-gcc-44-c++.s390x 4.4.7-8.el7
gcc.s390x 4.8.5-16.el7
gcc-c++.s390x 4.8.5-16.el7
gcc-gfortran.s390x 4.8.5-16.el7
gcc-objc.s390x 4.8.5-16.el7
gcc-objc++.s390x 4.8.5-16.el7
libgcc.s390 4.8.5-16.el7
I then do: yum install gcc.s390x and I obtain the following error:
Error: Package: glibc-2.17-196.el7.s390
Requires: glibc-common = 2.17-196.el7
Installed: glibc-common-2.17-260.el7_6.3.s390x (#rhel-7-for-system-z-rpms)
glibc-common = 2.17-260.el7_6.3
Available: glibc-common-2.17-196.el7.s390x
glibc-common = 2.17-196.el7
What I read from this is that s390x package is installed but the one needed is the one that does not have the s390 extension.
How can I get around this ? I pulling gcc directly from git but when I do a configure the message says that a compiler needs to be installed.
Any help would be much appreciated. Thanks - C
This output line
Available: glibc-common-2.17-196.el7.s390x
shows that the configured repositories only contain glibc versions up to RHSA-2017:1916. This means that you have configured repositories for Red Hat Enterprise Linux 7.4 (and not even Extended Update Support). However, someone at one point upgraded glibc to a package version from Red Hat Enterprise Linux 7.6.
Installing GCC needs additional glibc components, and these have to match the already-installed version. Since the 7.6 packages are not available from the configured repositories, installation fails with a dependency error.
If you need assistance with subscription management, you should file a support ticket.

Compile errors when setting up Plone development environment

I'm trying to follow the walkthrough here to produce a new theme for my Plone 5.1 server:
https://training.plone.org/5/theming/theme-package.html
I'm using MacOS 10.13.6 running clang clang-1000.11.45.5 (the one that comes with XCode) and Python 3.6.4 (installed through Anaconda). I've run into some trouble since the buildout script that is produced by mr.bob doesn't appear to contain all of the dependencies, specifically plone.recipe.zope2instance==4.2.22. When I attempt to install that dependency manually, I get the following compilation error:
src/Persistence/_Persistence.c:178:5: error: non-void function 'init_Persistence' should return a value [-Wreturn-type]
return;
^
17 warnings and 7 errors generated.
error: command 'clang' failed with exit status 1
I tried upgrading to the latest version of mr.bob and the templates, then using the plonecli to create and start the buildout, but I get the same compilation errors.
There are many like it in that module. How do I resolve this so I can finish installing that dependency and finish my buildout?
Try to use Python 2.7, it's better supported by Zope and Plone.
Plone is using Python 2.7.x until Version 5.1.
In Plone 5.2 you will have the option to run Plone under Python 3, but then you have to use the WSGI-Server instead of the ZServer. For now just use Plone 5.1 with Python 2.7 as Plone 5.2 is still not finally released.

I'm trying install rpm package but i not able to install rpm

I'm using CentOS Linux release 6.0 (Final) but unable install given package
1) rpm -ivh oracle-instantclient11.2-devel-11.2.0.1.0-1.x86_64.rpm
Whenever i install package,I got following error
error: Failed dependencies:
oracle-instantclient11.2-basic >= 11.2.0.1.0 is needed by oracle-instantclient11.2-devel-11.2.0.3.0-1.x86_64
2)rpm -ivh oracle-instantclient11.2-devel-11.2.0.1.0-1.x86_64.rpm
Whenever i install package,I got following error
error: Failed dependencies:
oracle-instantclient11.2-basic >= 11.2.0.1.0 is needed by oracle-instantclient11.2-devel-11.2.0.1.0-1.x86_64
From the instant client information page:
Installation Instructions
Installation Steps:
Download the appropriate Instant Client packages for your platform. All installations REQUIRE the Basic or Basic Lite package.
...
That is referring to the .zip version, but the same will apply to the .rpm version.
So you need to get and install the oracle-instantclient11.2-basic-11.2.0.1.0-1.x86_64.rpm or oracle-instantclient11.2-basiclite-11.2.0.1.0-1.x86_64.rpm (Basic Lite: Smaller version of the Basic, with only English error messages and Unicode, ASCII, and Western European character set support) before you can install the -devel- package on top.
Kind of curious that you're installing the 11.2.0.1 version (or 11.2.0.3 from your first error message, despite the command you showed) when more recent versions are available. I assume you're getting your .rpm files from the download site. I'd get the 11.2.0.4 version, if not the 12.0.0.1 version, unless you have a specific reason to stick to an older one. I would get the same version for basic and devel though, despite the message suggesting they don't have to match. So oracle-instantclient11.2-basic-11.2.0.3.0-1.x86_64.rpm (or basiclite) if you're sticking with oracle-instantclient11.2-devel-11.2.0.3.0-1.x86_64.rpm.

Mac OSX Perl cannot find DBD::mysql in #INC

I have installed CPAN module DBD::mysql via sudo cpan install DBD::mysql in order to run the code below, however I keep getting the error message:
Can't locate loadable object for module DBD::mysql in #INC (#INC contains:
/sw/lib/perl5/5.12.3/darwin-thread-multi-2level
/sw/lib/perl5/5.12.3
/sw/lib/perl5/darwin-thread-multi-2level
/sw/lib/perl5
/sw/lib/perl5/darwin
/Library/Perl/5.12/darwin-thread-multi-2level
/Library/Perl/5.12
/Network/Library/Perl/5.12/darwin-thread-multi-2level
/Network/Library/Perl/5.12
/Library/Perl/Updates/5.12.3/darwin-thread-multi-2level
/Library/Perl/Updates/5.12.3
/System/Library/Perl/5.12/darwin-thread-multi-2level
/System/Library/Perl/5.12
/System/Library/Perl/Extras/5.12/darwin-thread-multi-2level
/System/Library/Perl/Extras/5.12
.
)
at dbi_write.pl line 11
Compilation failed in require at dbi_write.pl line 11.
BEGIN failed--compilation aborted at dbi_write.pl line 11.
This is my code
#!/usr/bin/perl
#use lib '/usr/bin/cpan';
use strict;
use FileHandle;
use File::Spec;
use DBI;
use DBD::mysql;
Did your CPAN install succeed? If it did, then the module has been installed in the wrong place for the version of Perl you are running.
Look at the CPAN log to see where DBD::mysql has been installed. The answer lies there, and the fix depends on where it has been installed and why it isn't in your Perl's #INC.
Do you have multiple installations of Perl?
By the way, you don't have to use DBD::mysql. DBI will load it automatically when you call DBI->new specifying a MySQL source. That tidies up the code at the expense of loading the driver module at run time - a small price to pay.
I solved it by doing the following:
copy libmysqlclient.18.dylib into /usr/lib/
Also, there are two different Perls in my Mac OS X. One in /usr/local/ActivePerl5.16/ And another in /Systems/Library/Per/Perl5.12

How do I get the Haskell Platform's ghc-pkg to work on MAC OSX

I have installed the latest Haskell Platform for MAC OSX and I get the error "Setup: failed to parse output of 'ghc-pkg dump'" when I do anything with Cabal.
So I looked at my versions:
ralphtq$ ghc-pkg list Cabal
/Library/Frameworks/GHC.framework/Versions/612/usr/lib/ghc-6.12.1/package.conf.d
Cabal-1.8.0.2
ralphtq-mac-mini:cabal-install-0.6.4 ralphtq$ cabal --version
cabal-install version 0.6.2
using version 1.6.0.3 of the Cabal library
This is telling me that even though I have Cabal 1.8 the cabal-instal is at version 0.6.2. I have tried to correct that using darcs to get the latest version of cabal-install, but I cannot get passed the error:
ralphtq$ sh bootstrap.sh
Checking installed packages for ghc-6.12.1...
parsec is already installed and the version is ok.
network is already installed and the version is ok.
Cabal is already installed and the version is ok.
mtl is already installed and the version is ok.
HTTP is already installed and the version is ok.
zlib is already installed and the version is ok.
cleaning...
Linking Setup ...
Configuring cabal-install-0.9.1...
Setup: At least the following dependencies are missing:
Cabal ==1.9.*
It is expecting Cabal to be >= 1.9.
I tried to install a previous version of Cabal but got the following error:
...
...
[50 of 51] Compiling Distribution.Simple ( Distribution/Simple.hs, Distribution/Simple.o )
[51 of 51] Compiling Main ( Setup.hs, Setup.o )
Linking Setup ...
Configuring Cabal-1.6.0.2...
Setup: failed to parse output of 'ghc-pkg dump'
I am back to the same problem.
I have also tried a complete re-install of the platform.
What are my next options? Help appreciated, thx.
Either you have installed an old version of the Haskell Platform, or you have a mixed up environment where you have installed over the top of an existing, older install, and so now have a mixture of ghc-pkg versions from 6.10.x and 6.12.x
Try removing those ghc-pkg and cabal binaries, and then installing the Platform. That way you won't have those old executables lying around.

Resources