Bug #15493 MySQL 5.0.16 installation fails with runtime error 217 at 0040F716 on W2K
Submitted: 5 Dec 2005 15:52 Modified: 23 Dec 2005 20:14
Reporter: Wolfgang Baron Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.0.16 OS:Windows (Windows 2000 Professional SP4)
Assigned to: CPU Architecture:Any

[5 Dec 2005 15:52] Wolfgang Baron
Description:
The installation runs in the Administrator security context, because normal users do not have appropriate rights. Some files are copied upto the notification "Removing backup files". Shortly thereafter, a typical Delphi error requester appears, telling me "Runtime error 217 at 0040F716". I press OK and the program seems to continue.

Then I press Finish and leave the "Configure the MySQL Server now" button active. I get a similar requester for address 0040ffca.

That's it for the installation. I find myself with a MySQL start menu chapter, which only contains a subdirectory for the server and an installation directory containing 79254031 bytes contained in 51 directories and 662 files.

I can start the instance configuration wizard and enter all the details. As soon as I press "Execute", the "Write configuration file" options gets red and an error message appears for not finding the "my-template.cnf" file.

Please help, I would very much like to use MySQL!

How to repeat:
I gues either your copy installs, or it doesn't.
[5 Dec 2005 16:38] Valeriy Kravchuk
Thank you for a problem report. Can you, please, describe your hardware and other (non-MySQL) software used (firewalls, antivirus software)? 

5.0.16 installs without any problems on my XP Professional, and previous version, 5.0.15, also was successfully installed on 2000 (Server? I haveto check) with SP4, according to my experience.

Describe all the steps you performed to install.
[6 Dec 2005 13:37] Wolfgang Baron
I had the problem with 5.0.15 too. Back then, I thought an obvious thing like that would have to appear on almost everyone's machine.
[6 Dec 2005 14:11] Wolfgang Baron
I'm sorry, I did not understand the bug system. This is the field, where to add the additional text...

Hooray, thank for your question. It was no software after all. I disabled everything and it did not work either. Then I logged in as Administrator and it worked beautifully. When I use the "Run As" feature from a normal user account, the installation does not work.

I hope this helps enough to find the bug and you also have a workaround. Thank you for your freeware.

I hope downgrading to S3 and leaving it open is the appropriate thing to do, as other users without administrative rights using the "Run As" feature in the Windows Explorer will run into the same problem.
[6 Dec 2005 14:28] Valeriy Kravchuk
I always install software on Windows using (local) Administrator account...

Thank you for the additional tests. I think, it is just a documentation issue. The appropriate warning should be given in http://dev.mysql.com/doc/refman/5.0/en/windows-troubleshooting.html, http://dev.mysql.com/doc/refman/5.0/en/mysql-install-wizard-introduction.html or some other prominent place. Do you agree with me.
[7 Dec 2005 20:53] Wolfgang Baron
It should definitely go there until the bug is fixed. I also definitely believe this should be treated like a bug (even though Windows is to be blamed), as there should be no difference between running a program as the logged on user or runnning a program from another logon using the "Run As" entry in the Windows Explorer (shift right-click, then a "Run As" entry appears, usually directy under the "Open" entry) and logging on as that user.
Apparently, there is a bug in the RunAs Service, creating some minor difference between the two security contexts (no, I am fed up hunting down Windows bugs!). However, using the "Run As" feature is the single most used feature for people who run their machine as it should be configured (not giving every user administrative rights). Therefore, I beg you to support this way of running the installation program, so that Windows can at least be somewhat used like a decent operating system.
[11 Dec 2005 15:19] Valeriy Kravchuk
Please, specify, what exact MySQL package you were trying to install. It may happen so, that installer, even when "run as" administrator user, starts some other programs as current user, hence the failure.

Looks it is a feature request, really - "Make it possible to install in such a way". What do you think?
[13 Dec 2005 22:25] Wolfgang Baron
As I said, the bug is really in Windows. However, setup-programs should count on being run by the RunAs service, as sane people do not give their user accounts administrative rights.
So, seen from a legal point of view, you are innocent.
Seen from the user's point of view, you produced something, which is only usable in a stupid environment. I do not blame you, as I was not aware of this fact myself, until I discovered this bug a few days ago. If I ever write a setup program, I will definitely test it for being able to run by the RunAs service from a non administrative account!
I do not care, whether you see it as a feature request or a bug. I would only be very happy to see, that you manage to make MySQL Server install in the environment everyone should use (and is advised to use by Microsoft and anyone with a brain).
[23 Dec 2005 10:27] Valeriy Kravchuk
I've just tried to perfrom a clean install of 5.0.17 on my XP just as you described ("Run as" from unpriviledged user account). It installed and works without any problems. So, please, try 5.0.17. If it does not work for you in this version, then it is surely not a MySQL-related problem.

> I do not care, whether you see it as a feature request or a bug. I would only
> be very happy to see, that you manage to make MySQL Server install in the
> environment everyone should use (and is advised to use by Microsoft and
> anyone with a brain).

Working as Administrator permanently is not a good practice, but switching to that account to perform adimistrative tasks is absolutely normal, I believe.
[23 Dec 2005 10:44] Aleksey Kishkin
error 217 - it's sigsegv in borland delphi's runtime. I wonder where do  we use delphi??
[23 Dec 2005 20:14] Wolfgang Baron
I am talking about Windows 2000, as stated in the topic header. There is no quick user switch in Windows 2000, which is why you have to use the RunAs feature in Windows 2000. I will try 5.0.17 sometime in January, but I do not assume the bug just disappeared. I rather suspect, that Windows-XP does not have the RunAs Bug like Windows 2000 has.