Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Re: [Paul] nph-import.cgi fixes?

Quote Reply
Re: [Paul] nph-import.cgi fixes? In reply to
>>>The script I posted the other day to chop the content file into individual categories takes several minutes to get to the regional category <<<

My point exactly. nph-import.cgi takes about 1/2 a day to get there! I have left it running for 1 whole day before it had even started to import the World category (this is running it with content.rdf.u8, and not a sliced file). I just can't see why it is sooo much slower Unsure My script is;

Code:
#!/usr/bin/perl

$time = `date`;

print "Start: $time\n";

print "Running check...\n";

open(WRITE, "content.rdf.u8") || die "Cant write file. Reason: $!";
while (<WRITE>) {

chomp;
if ($_ =~ /<Topic r:id=\"Top\/Kids_and_Teens\/International\">/) {
print "Found: $_ \n"; last;
}

}
close(WRITE);

$end_time = `date`;


print "End: $end_time\n";

...and that produces the following;

Quote:
bash-2.05a$ perl test.cgi
Start: Wed Jun 25 18:21:27 PDT 2003

Found: <Topic r:id="Top/Kids_and_Teens/International">
End: Wed Jun 25 18:23:34 PDT 2003

..so it took 2mins and 8 seconds to get nearly to the bottom of the content.rdf.u8 file, whats going on? Unsure Oh, and thats not even running as root level user, its just a basic user with SSH permissions.

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!

Last edited by:

Andy: Jun 25, 2003, 3:25 AM
Subject Author Views Date
Thread nph-import.cgi fixes? Andy 3257 Jun 25, 2003, 2:35 AM
Thread Re: [Andy] nph-import.cgi fixes?
Paul 3165 Jun 25, 2003, 2:38 AM
Thread Re: [Paul] nph-import.cgi fixes?
Andy 3172 Jun 25, 2003, 2:50 AM
Thread Re: [Andy] nph-import.cgi fixes?
Paul 3159 Jun 25, 2003, 3:04 AM
Thread Re: [Paul] nph-import.cgi fixes?
Andy 3190 Jun 25, 2003, 3:24 AM
Thread Re: [Andy] nph-import.cgi fixes?
Paul 3157 Jun 25, 2003, 3:28 AM
Post Re: [Paul] nph-import.cgi fixes?
Andy 3146 Jun 25, 2003, 3:32 AM