Bug #37704 Setting wait_timeout using my.cnf error
| Submitted: | 27 Jun 2008 22:03 | Modified: | 28 Jun 2008 16:47 |
|---|---|---|---|
| Reporter: | Mario Martinez | Email Updates: | |
| Status: | Not a Bug | Impact on me: | |
| Category: | MySQL Server | Severity: | S3 (Non-critical) |
| Version: | 5.1.22-rc | OS: | Linux |
| Assigned to: | CPU Architecture: | Any |
[27 Jun 2008 22:20]
MySQL Verification Team
Thank you for the bug report. The error message you got: error: Found option without preceding group in config file: /etc/my.cnf at line: 1 means you don't have a group section i.e: [mysqld] wait_timeout=86400
[28 Jun 2008 5:02]
Mario Martinez
Thanks for the quick response. I added the group eliminating the error. However, the expected result was to modify the wait_timeout. After restarting and verifying the variables, I found the the wait_timeout default value (28800) was not changed to the new 86400 value. Any ideas on how I can change the wait_timeout?
[28 Jun 2008 12:31]
Sveta Smirnova
Thank you for the feedback. This is expected behavior. See bug #24064 for details.
[28 Jun 2008 16:47]
Mario Martinez
Again, thanks for the quick response. The bug report indicates that the global "wait_timeout" was changed, but the session was not. So, this presents one more questions. Some background first. I am developing a JAVA application that will run 24 hours a day and from time to time, it may experience 8 hours or more of in-activity. The application renews the connection once at the start of a new day. Question: Will the global "wait_timeout" apply to the connection? Or, will the session "wait_timeout"? Currently, every other day or two, the first query of the day results in a SQL error due to the "wait_timeout". Thanks for your help and support.
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.054 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.
Description: I am trying to override the default value for wait_timeout=24400 using the my.cnf file. The content of the file are: wait_timeout=86400 Per the information found in the online documentation and the posted problems and resolutions. However, when I start mysql I receive the following error: error: Found option without preceding group in config file: /etc/my.cnf at line: 1 Fatal error in defaults handling. Program aborted error: Found option without preceding group in config file: /etc/my.cnf at line: 1 Fatal error in defaults handling. Program aborted Starting MySQL/etc/init.d/mysql: line 159: kill: (28797) - No such process [FAILED] It is obvious that I there is something wrong in the my.cnf but I can not locate the problem. HELP... How to repeat: To recreate the error, just create a my.cnf file in the /etc folder with one line as follows: wait_timeout=86400 Save it and start mysql using the service mysql start from root.