Can't Get Moodle 1.9.9+ to Install

Can't Get Moodle 1.9.9+ to Install

by Daniel Conley -
Number of replies: 11
I've spent the last three days trying to get past the first three installations screens to get Moodle 1.9.9+ installed. The best I've been able to get is a blank screen showing http://localhost/moodle/install.php after it asks for the information as to the name of the database, root, etc.

I'm running Windows 7, Apache 2.2, php 5.3.2 and mysql 5.1.48. I've tried every configuration of php.ini files hpconf, etc. that I can find on the internet and these forums with no luck.

I also did try commenting out the upgrade_RPC_functions("$CFG->wwwroot/$CFG->admin/index.php"); // Return here afterwards entry, with no success.

Apache, php and mysql are all running fine. I have no problems pulling up the php status screen and mysql is shown to be running ok using the Command Line client. Apache is also running good and I can load my other websites on localhost with no problems.

Has anyone else had these problems who is running Windows 7? I'm suspecting that it might be the version of Windows (Windows 7) that is causing the problems regarding file permissions, but I can't find a fix.
Average of ratings: -
In reply to Daniel Conley

Re: Can't Get Moodle 1.9.9+ to Install

by Daniel Conley -
Here are is a segment of my Apache Error log, if it would help someone diagnose the problem:

**********************************************

[Thu Jul 22 11:56:44 2010] [warn] pid file C:/Program Files/Apache Software Foundation/Apache2.2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\php\\ext\\php_pdo.dll' - The specified module could not be found.\r\n in Unknown on line 0
[Thu Jul 22 11:56:45 2010] [notice] Apache/2.2.15 (Win32) PHP/5.3.2 configured -- resuming normal operations
[Thu Jul 22 11:56:45 2010] [notice] Server built: Mar 4 2010 11:27:46
[Thu Jul 22 11:56:45 2010] [notice] Parent: Created child process 516
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\php\\ext\\php_pdo.dll' - The specified module could not be found.\r\n in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'C:\php\ext\php_pdo.dll' - The specified module could not be found.
in Unknown on line 0

[Thu Jul 22 11:56:47 2010] [notice] Child 516: Child process is running
[Thu Jul 22 11:56:47 2010] [notice] Child 516: Acquired the start mutex.
[Thu Jul 22 11:56:47 2010] [notice] Child 516: Starting 64 worker threads.
[Thu Jul 22 11:56:47 2010] [notice] Child 516: Starting thread to listen on port 80.
[Thu Jul 22 11:58:14 2010] [error] [client 127.0.0.1] File does not exist: C:/htdocs/moodle
[Thu Jul 22 11:58:41 2010] [error] [client 127.0.0.1] File does not exist: C:/htdocs/moodle


*************************************

I'm also thinking that Moodle 1.9.9+ may not be compatible with the latest version of php that I'm using. It is true, as the error log indicates, that php_pdo.dll is not in the php file extensions, but I think that it may not be used anymore by php.
In reply to Daniel Conley

Re: Can't Get Moodle 1.9.9+ to Install

by Daniel Conley -
Success!

Finally, I stumbled on to a post by Mr. Daniel Del Rio that solved my problem.

Quoting from Mr. Del Rio:

I ran into this same problem with version 1.8. I found that if you edit your install.php file in the root of your moodle directory on line 406 from:

} else if (($fh = @fopen($INSTALL['wwwrootform'].'/'.$INSTALL['admindirname'].'/environment.xml', 'r')) !== false) {

to:

} else if (($fh = @fopen("'".$INSTALL['wwwrootform']."/".$INSTALL['admindirname']."/environment.xml'", 'r')) !== false) {

you should no longer receive a blank page during install. This problem occurs only on some systems in my experience. It occurs because the fopen() PHP function requires a string and is not being given one. Please let me know if this helps.

**************************

I would recommend that this solution be placed on the main installation page, especially for Windows 7 users.

Now, I can proceed to get my site up and running.
Thanks to Daniel Del Rio.


In reply to Daniel Conley

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Glenys Hanson -

Hi Daniel,

I thought you'd given me a solution on a plate, but no, I still get a blank install.php page.

I've just bought a new computer with Windows 7 pre-installed. I had a struggle to get it to give me the permissions to change the file, but I did finally manage that.

I went to:

Program files > Moodle > server > moodle > install.php

and as you and Daneil Del Rio recommend, I changed:

{page:WordSection1;} --> } else if (($fh = @fopen($INSTALL['wwwrootform'].'/'.$INSTALL['admindirname'].'/environment.xml', 'r')) !== false) {

to:

} else if (($fh = @fopen("'".$INSTALL['wwwrootform']."/".$INSTALL['admindirname']."/environment.xml'", 'r')) !== false) {


But to no avail. See screen shot below. If you can help, please do so in very simple words I'm not at all a techie person.

Cheers,
Glenys
Attachment 23-07-2010_21-20-39.png
In reply to Glenys Hanson

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Daniel Conley -
Hi Glenys,

Are you running one of the "all-in-one" Xampp packages that installs Apache, php, mysql and moodle at one time or did you do it the way I did and install each package separately?

The other thing that I did (that I did not mention) was to downgrade my php version to 5.2.14 from 5.3 because of problems mentioned on this page under paragraph 5:

http://www.artfulsoftware.com/php_mysql_win.html

If you are running the Xampp package, I'm not sure if I can help you because I don't know what version of php is incorporated into it.

One thing, for sure that I would try is to turn off UAC in Windows 7 using this procedure: Start Menu -> Control Panel -> User Accounts and Family Safety -> User Account. Then slide the indicator to the bottom of the scale. I would then restart the PC.

Also, if you made the change that Daniel Del Rio came up with, be sure that you properly save the file as administrator and restart your PC so that there is no question that Apache read the revised install.php file.

What I mean by "saving the file as administrator" is that when you are going to open the text editor to edit the file, first right click on the text editor program icon and choose "run as Administrator" before you edit and save the install.php file.

It may not be necessary to "run as administrator" when editing php files, but you should always do it for sure if you edit Apache files and it never hurts.

Also, check the wording of Daniel's entry in your install.php file and make sure it is exactly as he typed it. I cut and pasted it, because I don't trust my typing skills on copying lines of code.

I used "phpMyAdmin" to create the mysql database (moodle), rather than rely on Moodle to create it, but I don't think that probably matters for the installation.

I hope this helps--let me know how you do. It was really frustrating getting this program to run on Windows 7.


In reply to Daniel Conley

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Glenys Hanson -
Hi Daniel,

Thanks so much for trying to help. It is !!@§**&&!! difficult trying to take control of Windows 7. I've bopped around on the Internet to find info but it's a steep learning curve for me. I've learnt all sorts of clever techie things over the last 2 days but not the right ones. sad

Yes, I am (trying) to run the Moodle package for Windows Moodle 1.9.9+. So I can't tell you what version of php it is until it's installed.

I was able to install the Moodle package for Moodle for Mac OS X in my new 10.6.3 in a couple of clicks no problem. (Yes, I've got money to throw around on new computers but not always the brains to install the software correctly. wink)

"One thing, for sure that I would try is to turn off UAC in Windows 7 using this procedure: Start Menu -> Control Panel -> User Accounts and Family Safety -> User Account. Then slide the indicator to the bottom of the scale." I'm not sure I found this: certainly didn't find a slider. My computer speaks to me in French.

Yes, I did a "copy and paste" of the change in the code - I'm a lousy typist.

It seems I may have to learn to be a big girl and install each package separately. But Mary Cooch says (on the French forum) she was able to install the Moodle Package for Windows on Windows 7, so I'm still hopeful. thoughtful

Thanks again.
Glenys






In reply to Glenys Hanson

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
Well I tell you Glenys - you will be a Bigger Girl than I if you install each package separately - so far I have only used the all in one packagesmile (though I have learned to update via CVS only today so I guess I am growing taller!)
In reply to Mary Cooch

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Glenys Hanson -
But Mary, nom d'une pipe, how did you manage to install the "all in one package"? I get the dreaded "white page" - install.php doesn't install.

Tearing my hair out,
Glenys
In reply to Glenys Hanson

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
Er - well- I just downloaded it (to my downloads folder) unzipped it, pressed Start Moodle exe and then went up to my browser, typed localhost -and - Robert est le frère de ta soeur, as I heard an English person say the other day, trying to be funny. I didn't do anything special, change any permissions or admin settings..
In reply to Mary Cooch

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7 - solved

by Glenys Hanson -
Hi Daniel and Mary,

I solved the problem thanks to Fred Quay on the French forum who suggested I use http://bitnami.org/stack/moodle (amazon.com is behind it). Any moron like me can use it - just download and follow the instructions. They do ask for an email address but don't insist on a confirmation process. It takes quite a long time and at certain points nothing seems to be happening.

Other Open Source applications - Drupal, Joomla, WordPress, etc. - can be installed in the same way.

Cheers,
Glenys
Average of ratings: Useful (1)
In reply to Glenys Hanson

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7 - solved

by Glenys Hanson -
Hi everyone,

I've seen since that Art Lader has proposed exactly the same solution here: Installation of Moodle on a personal computer

I'm not used to adding thing to Moodle Docs but I will add this unless someone more experienced gives a reason not to. mixed

Cheers,
Glenys
In reply to Glenys Hanson

Re: Can't Get Moodle 1.9.9+ to Install on Windows 7 - solved

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
I won't give you a reason not to -on the contrary;when I saw your post both in the French and English forums I thought to myself -Glenys should add that to the docswink