Trouble installing Mechanize with Strawberry (portable) Perl (for Windows 7) - windows

I've seen posts elsewhere on Stack Overflow suggesting that the sort of problem I have installing Mechanize for use with Strawberry Perl occur due to corporate firewalls, but I am not behind a corporate firewall. I do use an ISP modem and I have anti-virus software installed on my desktop. How should I configure cpan to avoid this problem?
----------------------------------------------
Welcome to Strawberry Perl Portable Edition!
* URL - http://www.strawberryperl.com/
* see README.TXT for more info
----------------------------------------------
Perl executable: C:\portableperl\perl\bin\perl.exe
Perl version : 5.18.2 / MSWin32-x64-multi-thread
C:\portableperl>cpan WWW:Mechanize
CPAN: CPAN::SQLite loaded ok (v0.203)
CPAN: LWP::UserAgent loaded ok (v6.05)
CPAN: Time::HiRes loaded ok (v1.9726)
Fetching with LWP:
http://cpan.strawberryperl.com/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to cpan.strawberryperl.com:80 (B
ad hostname)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to www.cpan.org:80 (Bad hostname
)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to www.cpan.org:80 (Bad hostname
)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
No external ftp command available
Fetching with LWP:
http://cpan.strawberryperl.com/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to cpan.strawberryperl.com:80 (B
ad hostname)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to www.cpan.org:80 (Bad hostname
)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to www.cpan.org:80 (Bad hostname
)]
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
Warning: no success downloading 'C:\portableperl\cpan\sources\authors\01mailrc.t
xt.gz.tmp2828'. Giving up on it.
No external ftp command available
CPAN: YAML::XS loaded ok (v0.41)
Please check, if the URLs I found in your configuration file
(http://cpan.strawberryperl.com/, http://www.cpan.org/,
http://www.cpan.org/) are valid. The urllist can be edited. E.g. with 'o
conf urllist push ftp://myurl/'
Could not fetch authors/01mailrc.txt.gz
C:\portableperl>

Given the list of error messages:
LWP failed with code[500] message[Can't connect to cpan.strawberryperl.com:80 (Bad hostname)]
LWP failed with code[500] message[Can't connect to www.cpan.org:80 (Bad hostname)]
I would suggest that it's either a problem with your internet connection, your firewall, or permissions that you're giving cpan.
I suspect that you can probably reach either of the two above urls via a web browser.
Try running cmd prompt as administrator, and try again.

Problem solved. It was the damn anti-virus software running on my machine!!!!

Related

Building Kraken2 Databases Errors

Currently running a metagenomic analysis of transcriptome reads using kraken2. Currently running into issues installing the required databases
Buildind kraken2 database code:
kraken2-build --download-library archaea --db archaea_DB
kraken2-build --download-library viral --db viral_DB
kraken2-build --download-library bacteria --db bacteria_DB
kraken2-build --download-library human --db human_DB
kraken2-build --download-library fungi --db fungi_DB
kraken2-build --download-library protozoa --db protozoa_DB
Errors:
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for archaea, exiting.
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for viral, exiting.
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for bacteria, exiting.
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for human, exiting.
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for fungi, exiting.
rsync: getaddrinfo: ftp.ncbi.nlm.nih.gov 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(138) [Receiver=3.2.6]
Error downloading assembly summary file for protozoa, exiting.
Ok so some adjustments I made was that I had to manually change the source code files of kraken2 through my anaconda environment.
I don't recall exactly what the changes were (you can look them up yourselves), but to access the files you can run the conda info -a command to find the directory where your conda environments are located. For example: find $(conda info -a) -name "rsync_from_ncbi.pl".
Once Files are edited then we can do the kraken2 process. The Errors I had was actually issues with the connection with the server (don't know why, but that's how it worked). Just wait for like 10 minutes or more and run the code and it should work.
Step 1: create a directory for the database
mkdir database
Step 2: Download taxonomy data to the database
kraken2-build --download-taxonomy --db database
Step 3: Download microbial data for the database
kraken2-build --download-library bacteria --db database
Step 4: Once the data is loaded to the library, build the database
kraken2-build --build --db database
These should be all the commands needed for kraken2

Tarantool module installation failed searching manifest

I am trying to install tarantool module. Tatrantool run in docker container with image tarantool/tarantool:2.3.
/opt/tarantool # tarantoolctl rocks install prometheus
Warning: Failed searching manifest: Failed fetching manifest for http://rocks.tarantool.org/ - Failed downloading http://rocks.tarantool.org/manifest - /root/.cache/luarocks/http___rocks.tarantool.org_/manifest
prometheus not found for Lua 5.1.
Checking if available for other Lua versions...
Checking for Lua 5.2...
Warning: Failed searching manifest: Failed fetching manifest for http://rocks.tarantool.org/ - Failed downloading http://rocks.tarantool.org/manifest - /root/.cache/luarocks/http___rocks.tarantool.org_/manifest
Checking for Lua 5.3...
Warning: Failed searching manifest: Failed fetching manifest for http://rocks.tarantool.org/ - Failed downloading http://rocks.tarantool.org/manifest - /root/.cache/luarocks/http___rocks.tarantool.org_/manifest
Checking for Lua 5.4...
Warning: Failed searching manifest: Failed fetching manifest for http://rocks.tarantool.org/ - Failed downloading http://rocks.tarantool.org/manifest - /root/.cache/luarocks/http___rocks.tarantool.org_/manifest
Error: No results matching query were found for Lua 5.1.
prometheus rock is deprecated
It's recomended to use more recent tarantool/metrics and here is an example how to use it with prometheus https://github.com/tarantool/metrics/blob/master/example/prometheus_export.lua

Laravel Composer stopped work

My composer stopped working I have no idea why. I tried to undo the changes at my application and still not working. So I tried to reinstall laravel, but now I can not use composer install. I get this message:
[Composer\Downloader\TransportException]
The "https://packagist.org/packages.json" file could not be downloaded:
failed to open stream: Connection timed out
If I run composer diagnose I get this:
Checking composer.json: OK
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: WARNING
[Composer\Downloader\TransportException] The "http://packagist.org
/packages.json" file could not be downloaded: failed to open stream:
Connection timed out
Checking https connectivity to packagist: WARNING
[Composer\Downloader\TransportException] The "https://packagist.org
/packages.json" file could not be downloaded: failed to open stream:
Connection timed out
Checking github.com rate limit: OK
Checking disk free space: OK
Checking pubkeys:
Tags Public Key Fingerprint: 57815BA2 7E54DC31 7ECC7CC5 573090D0
87719BA6 8F3BB723 4E5D42D0 84A14642
Dev Public Key Fingerprint: 4AC45767 E5EC2265 2F0C1167 CBBB8A2B 0C708369
153E328C AD90147D AFE50952
OK
Checking composer version:
[Composer\Downloader
\TransportException]
The "https://getcomposer.org/versions" file could not be downloaded:
failed
to open stream: Connection timed out
I think you may have a connectivity issue. Try resetting your internet connection and try again.

How see what exactly cookbook were uploaded fail?

I try to upload cookbook with dependencies, here is a log:
[root#redhat cookbooks]# knife cookbook upload reference-app --include-dependencies
Uploading my-cookbook [0.1.0]
Uploading maven [1.2.0]
Uploading hipsnip-jetty [0.9.0]
Uploading ark [0.9.0]
Uploading java [1.29.0]
Uploading windows [1.34.8]
Uploading 7-zip [1.0.2]
Uploading chef_handler [1.1.6]
WARNING: Uploaded 8 cookbooks ok but 2 cookbooks upload failed.
It is all log. Is there a way to sse what cookbook were failed exactly?
Using the verbose flag will show you why it didn't upload correctly.
For instance I added some bad code to the apt cookbook...
[scarman#coldlight cookbooks]$ knife cookbook upload apt --include-dependencies -n -V
Uploading apt [2.6.0]
INFO: Validating ruby files
FATAL: Cookbook file recipes/default.rb has a ruby syntax error:
FATAL: /home/scarman/DevOps/cookbooks/apt/recipes/default.rb:29: `##' is not allowed as an instance variable name
FATAL: /home/scarman/DevOps/cookbooks/apt/recipes/default.rb:29: syntax error, unexpected end-of-input, expecting '('
FATAL: uha897*#S::##!!
FATAL: ^
And also turned my internet off for a moment...
[scarman#coldlight cookbooks]$ knife cookbook upload apt --include-dependencies -n -V
ERROR: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all, retry 1/5
ERROR: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all, retry 2/5
ERROR: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all, retry 3/5
ERROR: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all, retry 4/5
ERROR: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all, retry 5/5
ERROR: Network Error: Error connecting to https://api.opscode.com/organizations/cls-chef/cookbooks?num_versions=all - getaddrinfo: Name or service not known
Check your knife configuration and network settings
That should hopefully provide you with more insight as to why it's failing.

/usr/bin/perl install-module.pl DateTime

While installing bugzilla on RHEL, it checks for required modules:
./checksetup.pl --check-modules
It showed some unavailable modules.
While trying to install one of them, I encountered following error:
[root#localhost bugzilla-4.2.3]# /usr/bin/perl install-module.pl DateTime
Checking for CPAN (v1.81) ok: found v1.94
**Checking for YAML (any) not found**
Checking for ExtUtils-MakeMaker (v6.31) ok: found v6.55_02
CPAN: Storable loaded ok (v2.20)
CPAN: LWP::UserAgent loaded ok (v5.833)
CPAN: Time::HiRes loaded ok (v1.9721)
Warning: no success downloading '/root/.cpan/source/authors/01mailrc.txt.gz.tmp19575'.
Giving up on it. at `/usr/share/perl5/CPAN/Index.pm line 225`
Fetching with LWP:
http://www.perl.org/CPAN/authors/01mailrc.txt.gz
LWP failed with code[500] message[Can't connect to www.perl.org:80 (Bad hostname 'www.perl.org')]
Trying with "/usr/bin/curl -L -f -s -S --netrc-optional" to get "http://www.perl.org/CPAN/authors/01mailrc.txt.gz" :
curl: (6) Couldn't resolve host 'www.perl.org'
Function system("/usr/bin/curl -L -f -s -S --netrc-optional "http://www.perl.org/CPAN/authors/01mailrc.txt.gz" > /root/.cpan/source/authors/01mailrc.txt.tmp19575")returned status 6 (wstat 1536)
Warning: expected file [/root/.cpan/source/authors/01mailrc.txt.gz.tmp19575] doesn't exist
Trying with "/usr/bin/wget -O /root/.cpan/source/authors/01mailrc.txt.tmp19575" to get<some URL>
--2012-09-24 17:29:33-- <some URL>
Resolving www.perl.org... failed: Name or service not known.
wget: unable to resolve host address “www.perl.org”
Function system("/usr/bin/wget -O /root/.cpan/source/authors/01mailrc.txt.tmp19575 "some URL ")
returned status 4 (wstat 1024)
Warning: expected file [/root/.cpan/source/authors/01mailrc.txt.gz.tmp19575] doesn't exist
Warning: no success downloading '/root/.cpan/source/authors/01mailrc.txt.gz.tmp19575'.
Giving up on it. at /usr/share/perl5/CPAN/Index.pm line 225
Can anyone help me out?
thanks a ton!
It looks like it cannot resolve hostnames, can you ping www.google.co.uk from that machine?
If thats the problem you can temporary edit your DNS settings, I don't now how it works in Red Hat, but here is the Ubuntu way:
sudo nano /etc/resolv.conf
Add DNS server manual:
#Google nameserver 1:
nameserver 8.8.8.8
#Google nameserver 2:
nameserver 8.8.4.4
Save the file and restart the network interface:
sudo /etc/init.d/networking restart

Resources