esprague
Members-
Posts
17 -
Joined
-
Last visited
Everything posted by esprague
-
Vivek fixed it on Oct 7 but now we are having issues again. The problem was that our account was still residing on a shared server but the dns pointed to our dedicated box. Vivek modified the server setup to use an external (cpanel official) nameserver to fix it.
-
I just added the code near the top of average.php but it doesn't appear to tell us which function is trying to divide by 0.
-
The average.php file itself only has 16 lines of code but it does a require on a file that has 103 lines. In addition to 103 lines of code, the required file has 2 additional includes. Which php file should we modify to add the print_r($_SERVER); command? What line of code should it go on? Thanks, Eric
-
I've done some testing removing the www in certain includes. Sometimes it works fine. Other times we have problems. Here is a very simple example of a problem. http://www.flopturnriver.com/myzero.php has one line of code: ><?php include ("http://flopturnriver.com/reviews/average.php?id=37"); ?> Clicking on http://www.flopturnriver.com/myzero.php in the browser brings up the following: >Warning: Division by zero in /home/eproxim/public_html/reviews/average.php on line 46 0 However, if you just click on http://flopturnriver.com/reviews/average.php?id=37 in the browswer it works fine and shows the numeric average for id 37 which happens to be 3.747 at the time of this writing. Prior to October 5th we always got the same result with our without an include. In other words this division by zero error when using the include is new.
-
If the www problem was our only include issue then I'd say you were on to something. Unfortunately the www issue is the simplest example. In other words, some of our php includes that use parameters have stopped working as well, even when I remove the www from the path. All signs point to something changing on a global level outside the scripts. I like your idea of looking at .htaccess options though. Maybe we could put .htaccess files in each subdomain and subdirectory that has includes if we can override the changed server setting on a directory by directory level. I read about .htaccess on the http://gallery.menalto.com/node/7434 page but I'm still not sure if we should do something there. The php.ini file looks good, I compared it to the php.ini file of another site I have hosted with TotalChoice where the www includes and parameter includes still work fine. What else should we be looking at outside of php.ini and .htaccess? What security and apache settings should we look at?
-
carbonize, You're right than in a perfect world an internal include is better. We don't have the resources to go through all our scripts and change them at this time(thousands of pages, issues with global replaces on the right side, single quotes vs double etc). Also, many of our includes cross subdomains and it is complicated sorting things out with subdomains, parameters in the includes, different domains relying on this dedicated server etc. We need to find out what has changed on the server level. As I said these includes have worked fine for years but suddenly they stopped working the morning of October 5th. Obviously something changed outside the scripts and we need to identify and roll back that change.
-
Here is more info from the ticket: -------------------------------------------------------------------------------- SUPPORT -------------------------------------------------------------------------------- Hello Eric, The problem is with the occurance of "www" in it. include("http://flopturnriver.com/loop-inner.php"); works but include("http://www.flopturnriver.com/loop-inner.php"); fails without any errors. -------------------------------------------------------------------------------- Me -------------------------------------------------------------------------------- That is what I have been saying. It looks like a server permission was changed the night of October 4th such that www is no longer allowed in our php includes. We need this changed back as soon as possible on our dedicated server. We have thousands of pages with these types of includes and some of them cross subdomains. Changing our includes by removing www is not an option. Thanks, Eric
-
Here is the latest, curl was manuall reinstalled by support but our php includes are still not working. Note that the only php script that is still ok is our phpBB forum. -------------------------------------------------------------------------------- SUPPORT -------------------------------------------------------------------------------- I accidently came across this error message ------------- Untarring curl......Done ./configure [@curl-7.15.3]...(--prefix=/usr)...................................Done make [@curl-7.15.3]...(-j 1).........................................................Done make [@curl-7.15.3]...(install)....Done make[3]: *** [install-binPROGRAMS] Error 1 make[2]: *** [install-am] Error 2 make[1]: *** [install] Error 2 make: *** [install-recursive] Error 1 ------------- I have manually reinstalled curl in the server. Could you please check it out once again? It seems like the link redirects to the index.html page now. -------------------------------------------------------------------------------- ME -------------------------------------------------------------------------------- I'm glad you fixed the errors above. Unfortunately our php includes are still not working properly. I made the loop-outer.php and loop-http-outer.php files to demonstrate the problem. Both files have just one line of code, an include of the loop-inner.php file. The difference is the way in which the include is written, here is what I mean: ###################### http://www.flopturnriver.com/loop-outer.php - works properly because the include is written WITH NO www as follows: include("loop-inner.php"); ###################### http://www.flopturnriver.com/loop-http-outer.php - doesn't work, redirects to home page instead of including file because the include is written WITH www as follows: include("http://www.flopturnriver.com/loop-inner.php"); ######################
-
Andy, I was talking with Vivek on aim last night. He said the dedicated servers are not upgraded without notification. Here is what php.ini has for include_path: >include_path .:/usr/lib/php:/usr/local/lib/php .:/usr/lib/php:/usr/local/lib/php and allow_url_open: >allow_url_fopen On On The ticket is still open. I know it isn't a scripting issue, we've had these scripts in place for years and they haven't changed. Also, I have the same identical scripts on other sites hosted at TotalChoice and they're still working fine. On the server side I'm not sure what configuration settings we should be looking at outside of php.ini The only thing that has changed recently is that our designer made some email forwarding changes in cpanel the night before the includes stopped working but I don't see how email forwarding could possibly be related to this.
-
I opened a ticket this morning when the scope of the issue was broad. When we identified the issue as specific php includes I closed the old ticket and opened a new one this afternoon. I just added your questions to the ticket.
-
Andy, Thanks for pointing out the error log in cpanel. It is easier than doing tail on /usr/local/apache/logs/error_log plus the results can be copied and pasted. With the full path include issues we don't see errors in the log file. On the browser side we are just redirected to the home page. We're on 2 fully managed dedicated servers (but I'm not worried about the db server right now). As for the http server, I don't know if it has been upgraded recently. We haven't made other changes. To my knowledge our DNS has not changed in awhile. We do see some other new errors in error_log from scripts with includes where root_path for the include is defined as follows: define('root_path', ''); (these scripts worked fine last night). Here are these new errors: >[Fri Oct 6 02:18:49 2006] [error] PHP Warning: main(): Failed opening 'lang/english.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/eproxim/public_html/reviews/inc/global.php on line 101 [Fri Oct 6 02:18:49 2006] [error] PHP Warning: main(lang/english.php): failed to open stream: No such file or directory in /home/eproxim/public_html/reviews/inc/global.php on line 101 [Fri Oct 6 02:18:49 2006] [error] PHP Warning: main(lang/english.php): failed to open stream: No such file or directory in /home/eproxim/public_html/reviews/inc/global.php on line 101 Thanks, Eric
-
As of this morning our php includes only work when there is no "http://www.x.com/"'>http://www.x.com/" in the path. We need to get things working again such that we can have "http://www.x.com/" in the path. For example, if there is a file called a.php in the root directory then include("./a.php"); //still works include("http://www.x.com/a.php"); //no longer works We have too many php includes to change, instead we need to figure out why the includes with the http and the www in the path no longer work. We've had includes this way for years without any changes. We haven't made any updates or installs recently. We haven't made any coding changes recently. Everything was fine on our site last night. The php.ini file looks ok, what else should we check? Thanks, Eric
-
I changed it to run every minute while I sort things out. I got some emails with the following: /home/eproxim/public_html/monitor/convert.sh: line 4: convertoutput.txt: Permission denied Here is line 4: date > convertoutput.txt I did a chmod from ssh to fix the permission problem: chmod 777 convertoutput.txt Next I changed the scheduling to every 2 minutes. I think everything is ok now. Thanks for all your help TCH-MikeJ, I really appreciate it
-
I did this and sifted through 5 pages of junk mail going back to noon today. There were no emails from cron. Earlier when I was experimenting with the scheduling I put my personal email in cron. This goes back to my problem with the Standard Cron Job gui. It seems to ask for an email at a global level applying to all jobs. When my email was there I kept getting an email every 2 minutes due to our php job mentioned earlier but nothing for my sh job. Each email I received had the following subject: Cron <eproxim@dedicated105> /usr/bin/php /home/eproxim/public_html/phpBB2/site_map_recent_posts_cron_job.php and the following body: Content-type: text/html I'll add "> /dev/null 2>&1"(w/out the quotes) to the end of the php listings in cron and change the email to my personal again to see if we get anything for the .sh entry.
-
I'll list the contents of the convert.sh file here since the script is so short: #!/bin/bash cd /home/eproxim/www/monitor date > convertoutput.txt for x in `pgrep converter.cgi` do sleep 5 kill $x done That's it, all it does is look for runaway converter.cgi processes and kill them. It sleeps 5 seconds in between so that normal converter.cgi processes have a chance to finish without being killed(normal converter.cgi processes run in a second or less I think). The first 2 lines write to an output file so I can see the last date/time the script ran. I'm not sure how to get to the main account email but if you can help me out by listing the specifics here then I'll check it out. I don't fully understand how the email field works in the Standard Cron Manager gui. I'd like to have an email while we try to get this working but the problem is that if I put an email there then it gets overwhelmed with output from our other cron jobs(we have one that runs every 2 minutes). I wish there was an easy way to assign a different email address to different cron jobs in the gui. Thanks Again for your help, Eric
-
Using SSH, my script launches as follows from the command line and it works fine: /home/eproxim/public_html/monitor/convert.sh We want it to run every 5 minutes. In crontab I have it set as follows: 5 * * * * /bin/sh /home/eproxim/public_html/monitor/convert.sh It isn't launching. We have several php scripts that work fine from crontab, for example the entry below fires every 30 minutes: 30 * * * * /usr/bin/php /home/eproxim/public_html/phpBB2/site_map_announcements_cron_job.php Please let me know how the convert.sh entry needs to be changed in the Advanced (Unix Style) crontab gui. Thanks, Eric
-
We mainly use php but we want to get familiar with python in case we use it for the google sitemap. We've used one perl cgi script and that was simple, we just put the file in our x.com/cgi-bin directory and everything was cool. If we want to use the test.py sample file in this thread then where do we put it in our file system (and please don't say /usr/bin/python, rather tell me where to look in ftp) ? In other words, one can find the perl directory by going to www then searching for the cgi-bin subdirectory, how do we do the same thing for python? Thanks, Eric
