Sponsored Content
Top Forums Shell Programming and Scripting Wget takes a long time to complete Post 302889905 by mohtashims on Monday 24th of February 2014 11:48:25 AM
Old 02-24-2014
Quote:
Originally Posted by ahamed101
why don't you ping it if you want to check the reachability?

--ahamed
Becoz, I need to check the complete URL not just the hostname portnumber
 

10 More Discussions You Might Find Interesting

1. Programming

fwrite takes extremely long time

After my previous thread, I think I found out what causes the long delays. I run this program on several Linux computers, and the sometimes (after the file with the arrays becomes big) the fwrite takes between 100 ms to 900 ms. This is very bad for me, as I want a timer to halt each 30 ms.... ... (5 Replies)
Discussion started by: inna
5 Replies

2. Shell Programming and Scripting

shell script takes long time to complete

Hi all, I wrote this shell script to validate filed numbers for input file. But it take forever to complete validation on a file. The average speed is like 9mins/MB. Can anyone tell me how to improve the performance of a shell script? Thanks (12 Replies)
Discussion started by: ozzman
12 Replies

3. Linux

it takes long time to login on server

Hi, I am trying to login using ssh on Red Hat Linux 5 server, The password appears immediately but after I enter the password it takes about 90 seconds to login completely. Please suggest what changes require? Regards, Manoj (4 Replies)
Discussion started by: manoj.solaris
4 Replies

4. UNIX for Dummies Questions & Answers

time how long it takes to load a module

Hello, like the title says, how can i measure the time it takes to load a module in Linux, and how how can i measure the time it takes to load a statically compiled module. /Best Regards Olle ---------- Post updated at 01:13 PM ---------- Previous update was at 11:54 AM ---------- For... (0 Replies)
Discussion started by: ollebanan
0 Replies

5. UNIX for Dummies Questions & Answers

Changing Password process takes a long time

We are running unix. After a reboot of the server we have found that changing password takes a long time. if type in passwd "username" you can type in the 1st instance of the password , press enter , then it will wait for about 3 minutes before bringing up the confirm password line typing it in... (4 Replies)
Discussion started by: AIXlewis
4 Replies

6. Shell Programming and Scripting

sort takes a long time

Dear experts I have a 200MG text file in this format: text \tab number I try to sort using options -fd and it takes very long! is that normal or I can speed it up in some ways? I dont want to split the file since this one is already splitted. I use this command: sort -fd file >... (12 Replies)
Discussion started by: voolek
12 Replies

7. UNIX and Linux Applications

database takes long time to process

Hi, we currently having a issue where when we send jobs to the server for the application lawson, it is taking a very long time to complete. here are the last few lines of the database log. 2012-09-18-10.35.55.707279-240 E244403536A576 LEVEL: Warning PID : 950492 ... (1 Reply)
Discussion started by: techy1
1 Replies

8. UNIX for Advanced & Expert Users

Find command takes too long to complete

Hi, Below is my find command find /opt/app/websphere -name myfolder -perm -600 | wc -l At time it even takes 20 mins to complete. my OS is : SunOS mypc 5.10 Generic_150400-09 sun4v sparc SUNW,T5440 (10 Replies)
Discussion started by: mohtashims
10 Replies

9. Shell Programming and Scripting

Script takes too long to complete

Hi, I have a lengthy script which i have trimmed down for a test case as below. more run.sh #!/bin/bash paths="allpath.txt" while IFS= read -r loc do echo "Working on $loc" startdir=$loc find "$startdir" -type f \( ! -name "*.log*" ! -name "*.class*" \) -print | while read file do... (8 Replies)
Discussion started by: mohtashims
8 Replies

10. Shell Programming and Scripting

Checking for substring in a loop takes too long to complete.

I need to check if the files returned by ls command in the below script is a sub-string of the argument passed to the script i.e $1 The below script works fine but is too slow. If the ls command take 12 secs to complete printing all files with while loop then; using posix substring check... (6 Replies)
Discussion started by: mohtashims
6 Replies
CPAN::Mirrors(3pm)					 Perl Programmers Reference Guide					CPAN::Mirrors(3pm)

NAME
CPAN::Mirrors - Get CPAN miror information and select a fast one SYNOPSIS
use CPAN::Mirrors; my $mirrors = CPAN::Mirrors->new; $mirrors->parse_from_file( $mirrored_by_file ); my $seen = {}; my $best_continent = $mirrors->find_best_continents( { seen => $seen } ); my @mirrors = $mirrors->get_mirrors_by_continents( $best_continent ); my $callback = sub { my( $m ) = @_; printf "%s = %s ", $m->hostname, $m->rtt }; $mirrors->get_mirrors_timings( @mirrors, $seen, $callback ); @mirrors = sort { $a->rtt <=> $b->rtt } @mirrors; print "Best mirrors are ", map( { $_->rtt } @mirrors[0..3] ), " "; DESCRIPTION
new( LOCAL_FILE_NAME ) continents() Return a list of continents based on those defined in MIRRORED.BY. countries( [CONTINENTS] ) Return a list of countries based on those defined in MIRRORED.BY. It only returns countries for the continents you specify (as defined in "continents"). If you don't specify any continents, it returns all of the countries listed in MIRRORED.BY. mirrors( [COUNTRIES] ) Return a list of mirrors based on those defined in MIRRORED.BY. It only returns mirrors for the countries you specify (as defined in "countries"). If you don't specify any countries, it returns all of the mirrors listed in MIRRORED.BY. get_mirrors_by_countries( [COUNTRIES] ) A more sensible synonym for mirrors. get_mirrors_by_continents( [CONTINENTS] ) Return a list of mirrors for all of continents you specify. If you don't specify any continents, it returns all of the mirrors. get_countries_by_continents( [CONTINENTS] ) A more sensible synonym for countries. best_mirrors "best_mirrors" checks for the best mirrors based on the list of continents you pass, or, without that, all continents, as defined by "CPAN::Mirrored::By". It pings each mirror, up to the value of "how_many". In list context, it returns up to "how_many" mirror. In scalar context, it returns the single best mirror. Arguments how_many - the number of mirrors to return. Default: 1 callback - a callback for find_best_continents verbose - true or false on all the whining and moaning. Default: false continents - an array ref of the continents to check If you don't specify the continents, "best_mirrors" calls "find_best_continents" to get the list of continents to check. get_n_random_mirrors_by_continents( N, [CONTINENTS] Returns up to N random mirrors for the specified continents. Specify the continents as an array reference. get_mirrors_timings( MIRROR_LIST, SEEN, CALLBACK ); Pings the listed mirrors and returns a list of mirrors sorted in ascending ping times. find_best_continents( HASH_REF ); "find_best_continents" goes through each continent and pings "N" random mirrors on that continent. It then orders the continents by ascending median ping time. In list context, it returns the ordered list of continent. In scalar context, it returns the same list as an anonymous array. Arguments: n - the number of hosts to ping for each continent. Default: 3 seen - a hashref of cached hostname ping times verbose - true or false for noisy or quiet. Default: false callback - a subroutine to run after each ping. ping_cache_limit - how long, in seconds, to reuse previous ping times. Default: 1 day The "seen" hash has hostnames as keys and anonymous arrays as values. The anonymous array is a triplet of a "CPAN::Mirrored::By" object, a ping time, and the epoch time for the measurement. The callback subroutine gets the "CPAN::Mirrored::By" object, the ping time, and measurement time (the same things in the "seen" hashref) as arguments. "find_best_continents" doesn't care what the callback does and ignores the return value. AUTHOR
Andreas Koenig "<andk@cpan.org>", David Golden "<dagolden@cpan.org>", brian d foy "<bdfoy@cpan.org>" LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See <http://www.perl.com/perl/misc/Artistic.html> perl v5.18.2 2014-01-06 CPAN::Mirrors(3pm)
All times are GMT -4. The time now is 08:28 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy