Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

SiteMonitor


Jack_mcs

Recommended Posts

That error is usually not a problem with the code. Most shared servers have a time limit of 30 seconds for scripts to run. If you have too many entries in your file list, the script takes too long to run while trying to build the reference file so you need to reduce that number. To get started, just try monitoring a small directory, like tmp. Then you can add files to it and change them to see how the contribution works. Once you know it is functioning properly, go back and add other directories to the list. If the timeout problem comes back, the list is too long for your server to handle.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

The setting is correct, assuming your shop is in the catalog directory. What makes you think it is only looking at one file?

 

Jack

 

If you look at the bottom of the results it says that only 1 file being monitored...I thought I saw else where it usually has the total number of files monitored there. I added a file just to see if it picked it up and ran the script and it returned the same results.

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

I just ran the script again and here's what I get after adding a file.

 

NEW FILES:

Found a new file named

 

DELETED FILES:

Found a deleted file named ttpdocs/catalog////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

 

SIZE MISMATCH:

Size differences not checked due to deleted file(s)

 

TIME MISMATCH:

Time differences not checked due to deleted file(s)

 

PERMISSIONS MISMATCH:

Permissions not checked due to deleted file(s)

 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Sitemonitor ran on August 30, 2008, 4:19 pm

Total mismatches found were 2

Total files being monitored is 1

 

 

What's causing all the /////////////// to be put on there and not the file name? I didn't delete any files either, I actually

added a item to the catalog..it seems like it should have picked that up.

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

In your SiteMonitor configure setings, you tell the script where to start. That is usually the location of the shop and in your case that is D:/vhosts/MySite.COM/httpdocs/catalog, assuming that is a valid path. Now when you edit the list of directories to be scanned, you only list the ones within that location, like images, includes and tmp. You've got it set to catalog so it is causing a loop in the script.

 

Jack

Edited by Jack_mcs

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

"Now when you edit the list of directories to be scanned, you only list the ones within that location, like images, includes and tmp"

 

Ok, now I'm getting a little more info, where do I edit the list of directories to be scanned at? Is that in the sitemonitor.php file?

 

Thanks so much for helping me to get this figured out.

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

There is a configure section when you click on SiteMonitor in admin. You can select the directories from a dropdown list.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

There is a configure section when you click on SiteMonitor in admin. You can select the directories from a dropdown list.

 

Jack

 

I thought that list was only to exclude the direcotries you didn't want scanned, not the ones you did want scanned. Or,

am I just not understanding.

Thanks,

Steve

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

I installed this earlier this evening...very cool. Just one problem:

 

When I go to SiteMonitor>Admin and click on Execute Sitemonitor, I get errors about permission being denied on functions/sitemonitor_functions.php

 

When I click on Manually Execute Sitemonitor, it works, in so much that it gives me messages but it is not writing to the log.txt file. Here's what I got (I edited one file this evening, so that's why there is the 'mismatch' message. I did that just to see what would happen with this feature, and it works!)

 

No new files found...
No deleted files found...
No size differences found...
Time Mismatch on includes/languages/english/index.php Last Changed on Thursday, 04 Sep 2008 00:23:35 GMT
No permissions mismatches found...

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Sitemonitor ran on September 3, 2008, 5:24 pm
Total mismatches found were 1
Total files being monitored is 6510
Email sent to shop owner.

Warning: fopen(sitemonitor_log.txt) [function.fopen]: failed to open stream: Permission denied in /home/username/public_html/admin/includes/functions/sitemonitor_functions.php on line 272

 

I have the folder permissions set at 777 to the Admin folder, not its contents, though. Do I need to change file permissions on something else? It does work, I am getting the email when it's done, too. I just don't know what's going on with that error message.

 

- Andrea

Link to comment
Share on other sites

The script is trying to write to the log file. If the log file isn't present, it will try to create it. Some hosts won't allow you to one or the other, or both. You can turn off the log option in the settings. But if it is on, make sure you have a log file present (there is one in the contribution) and make sure your host will allow writing to it, you'll need to ask them.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

  • 2 weeks later...

Hi Jack,

 

After some monkeying with it...and getting nowhere, lol...I finally broke down and wrote to my webhost.

 

They informed me that the permissons on the sitemonitor_log.txt file should be set to 646. So I changed it to that, and everything went okay, except now I notice that not only is that .txt file being written to....it's also creating another file underneath it dated with whenever I run this script. Like...sitemonitor_log_13_09_2008.txt

 

It's no big deal. I'm just wondering if that's...normal, I suppose. ???

 

The other thing I want to ask is...is it normal to login to Admin and click on Sitemonitor>Configure and find all of my fields empty? In other words, it's not saving what I originally entered. Everything from the email addresses to the Start Directory. All is blank every time I open it.

 

I've opened it quite a bit as I'm having that 30-second timeout problem with the script and I'm adding folders that I don't wish to be looked at, but every time...it's like I have to start over and enter everything again as those particular fields are blank.

 

Andrea

Link to comment
Share on other sites

Hi Jack

 

Im currently running v3.04 and have to set my admin folder to 777 to run the script. Uptil now ive had no problems but I tried to run it today and received the following error message:

 

Warning: copy(sitemonitor_log_14_09_2008.txt) [function.copy]: failed to open stream: Permission denied in /home/mysite/public_html/admin/includes/functions/sitemonitor_functions.php on line 70

 

 

 

I am planning on upgrading but havent had time to do it yet. Do you think I should upgrade first and then see if I experience the same problem, or is it important that I solve this error first? (sitemonitor_functions.php has permission 777)

 

Thanks,

 

Ben

Link to comment
Share on other sites

Hi Jack,

 

After some monkeying with it...and getting nowhere, lol...I finally broke down and wrote to my webhost.

 

They informed me that the permissons on the sitemonitor_log.txt file should be set to 646. So I changed it to that, and everything went okay, except now I notice that not only is that .txt file being written to....it's also creating another file underneath it dated with whenever I run this script. Like...sitemonitor_log_13_09_2008.txt

 

It's no big deal. I'm just wondering if that's...normal, I suppose. ???

 

The other thing I want to ask is...is it normal to login to Admin and click on Sitemonitor>Configure and find all of my fields empty? In other words, it's not saving what I originally entered. Everything from the email addresses to the Start Directory. All is blank every time I open it.

 

I've opened it quite a bit as I'm having that 30-second timeout problem with the script and I'm adding folders that I don't wish to be looked at, but every time...it's like I have to start over and enter everything again as those particular fields are blank.

 

Andrea

The log is an option. If you enable that, there is also the options to control the size of the log. When that size is reached, the log file is renamed with the date added and a new log file is started. That's all controllable in the settings.

 

No, the configure settings should stay the way you set them. If they are not, something on your server is preventing that.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hi Jack

 

Im currently running v3.04 and have to set my admin folder to 777 to run the script. Uptil now ive had no problems but I tried to run it today and received the following error message:

 

Warning: copy(sitemonitor_log_14_09_2008.txt) [function.copy]: failed to open stream: Permission denied in /home/mysite/public_html/admin/includes/functions/sitemonitor_functions.php on line 70

 

 

 

I am planning on upgrading but havent had time to do it yet. Do you think I should upgrade first and then see if I experience the same problem, or is it important that I solve this error first? (sitemonitor_functions.php has permission 777)

 

Thanks,

 

Ben

I doubt that upgrading would help. See my reply above about the log file. It sounds like the permissions on your server are preventing the new file from being created.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

  • 2 weeks later...

Hey Jack and all else!

 

I installed this contrib today. Excellent work! of course I had some hiccups but for the most part all is well. I have it running on a cron job and its pretty sweet.

 

Here is what I noticed:

 

1) I had to set my admin folder to 777 in order to run the script for the first time so that it created the reference file. Then I changed my admin folder back to 755.

 

2) Is the reference file supposed to update itself? I would think it should. So that I dont keep seeing the same mismatches every day from days ago. Only new ones... Because I will make some code changes to my site pretty often. When sitemonitor.php is executed, does it update the reference file so previous changes are not shown?

 

Kind Regards,

Chris

Link to comment
Share on other sites

I think I just realised what I need to know and answered my own question by looking at the admin page for site monitor. It has the option to delete and recreate the reference file. So I assume the answer is NO, upon execution, the reference file is not updated.

 

So then, every time I want remake the reference file, I will need to log in via ftp to my site and change the permission on the admin folder to 777 and then run the command to delete and recreate the reference file via admin. This shouldnt be the case. Why cant site monitor delete the original file and make the new one? I get the folowing error:

 

Warning: unlink(sitemonitor_reference.php) [function.unlink]: Permission denied in /hsphere/local/home/myaccount/mywebsite.com/admin/sitemonitor_admin.php on line 32

 

I have a googlebase feed that is remade every day in my admin/feeds folder which is set to 755 and it has no problem overwriting the file.

 

Chris

Link to comment
Share on other sites

It does act the way you expect it to. Your server is set up not to allow it. There's no way to code for such situations. You should talk to your host about the problem.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hi Jack,

I implemented the upgrade but am getting the following error: Warning: opendir(http://www.lyonsperformance.com/catalog/) [function.opendir]: failed to open dir: not implemented in /mnt/w0207/d18/s05/b02d72b0/www/catalog/catalog/admin/includes/functions/sitemonitor_functions.php on line 102

 

Warning: readdir(): supplied argument is not a valid Directory resource in /mnt/w0207/d18/s05/b02d72b0/www/catalog/catalog/admin/includes/functions/sitemonitor_functions.php on line 104

Reference file creation failed.

 

Any ideas what caused this?

 

 

I have the same problem...

 

on line 102 and on line 104 of sitemonitor_functions.php qhen i execute the button EXECUTE for first time of "Delete Reference File".

 

I dont understood your explanation jack_mcs on your reply to lyonsperf...

 

How i solve this??

OScommerce Rocks!

Link to comment
Share on other sites

Hi Jack

 

Ive had site monitor working for a while now, but now I get these results:

 

NEW FILES:

No new files found...

 

DELETED FILES:

Found a deleted file named /var/www/html/catalog//search_enhancement.sql

Found a deleted file named /var/www/html/catalog//newsdesk_reviews_article.php

Found a deleted file named /var/www/html/catalog//product_reviews_write.php

Found a deleted file named /var/www/html/catalog//archive/CHANGELOG

Found a deleted file named /var/www/html/catalog//archive/LICENSE

Found a deleted file named /var/www/html/catalog//archive/documentation.pdf

Found a deleted file named /var/www/html/catalog//archive/update-20060817.txt

Found a deleted file named /var/www/html/catalog//archive/STANDARD

Found a deleted file named /var/www/html/catalog//archive/tep_database-pr2.2-CVS.pdf

Found a deleted file named /var/www/html/catalog//archive/extras/orders/update.php

Found a deleted file named /var/www/html/catalog//archive/extras/orders/README

 

The list goes on and on for ageas.

If I reset the site monitor, the list comes back.

 

Do you have any idea where I could begin to tackle this?

Edited by Windows
Link to comment
Share on other sites

Ok,

I'm still trying to figure this thing out...here's what I keep getting when I run the program.

 

No new files found...

No deleted files found...

No size differences found...

Time Mismatch on /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// Last Changed on Thursday, 01 Jan 1970 Eastern Standard Time

No permissions mismatches found...

 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Sitemonitor ran on September 25, 2008, 2:08 pm

Total mismatches found were 1

Total files being monitored is 1

Email sent to shop owner.

 

Why is this dang thing still doing the //////////////////////////////////// stuff? And why is it only looking at 1 file?? I've tried add just about all the files to the exclude list and only one file

to the exculde list and still get the same thing. Here is what I see in my reference.php file when it's created:

 

D:/vhosts/mdpokersupply.com/httpdocs////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////,0,0,0

I'm sure this is the issue, just how do I fix it.

 

Thanks for all your help on this Jack.

Edited by chimol

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

I have the same problem...

 

on line 102 and on line 104 of sitemonitor_functions.php qhen i execute the button EXECUTE for first time of "Delete Reference File".

 

I dont understood your explanation jack_mcs on your reply to lyonsperf...

 

How i solve this??

What did I reply?

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hi Jack

 

Ive had site monitor working for a while now, but now I get these results:

 

NEW FILES:

No new files found...

 

DELETED FILES:

Found a deleted file named /var/www/html/catalog//search_enhancement.sql

Found a deleted file named /var/www/html/catalog//newsdesk_reviews_article.php

Found a deleted file named /var/www/html/catalog//product_reviews_write.php

Found a deleted file named /var/www/html/catalog//archive/CHANGELOG

Found a deleted file named /var/www/html/catalog//archive/LICENSE

Found a deleted file named /var/www/html/catalog//archive/documentation.pdf

Found a deleted file named /var/www/html/catalog//archive/update-20060817.txt

Found a deleted file named /var/www/html/catalog//archive/STANDARD

Found a deleted file named /var/www/html/catalog//archive/tep_database-pr2.2-CVS.pdf

Found a deleted file named /var/www/html/catalog//archive/extras/orders/update.php

Found a deleted file named /var/www/html/catalog//archive/extras/orders/README

 

The list goes on and on for ageas.

If I reset the site monitor, the list comes back.

 

Do you have any idea where I could begin to tackle this?

I'm not sure what you mean by reset but if you are using the Delete button to create a new reference file, that should not happen. Try deleting the sitemonitor_reference.php file manually and running the script again to see if it works.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Ok,

I'm still trying to figure this thing out...here's what I keep getting when I run the program.

 

No new files found...

No deleted files found...

No size differences found...

Time Mismatch on //////////////////////////////// Last Changed on Thursday, 01 Jan 1970 Eastern Standard Time

No permissions mismatches found...

 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Sitemonitor ran on September 25, 2008, 2:08 pm

Total mismatches found were 1

Total files being monitored is 1

Email sent to shop owner.

If you are using the last version, try installing the one before it since some have reported problems with the last.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I just reinstalled the sitemonitor_configure.php file and think it fixed the ////////////////// problem. Hopefully this is working now.

Ok, now it's back...it's got something to do when I put in the home directory to start the search. I guess I'll have to figure out what the correct path should be. Right now it's going to

/vhosts/Mysite.COM/httpdocs

Edited by chimol

Steve

I appreciate all the help that everyone on this site has given me!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...