Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9182551
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T18:35:10+00:00 2026-06-17T18:35:10+00:00

I was wondering if there’s a way to decrease the opened files in mysql.

  • 0

I was wondering if there’s a way to decrease the opened files in mysql.

Details :

  • mysql 5.0.92

  • engine used : MyISAM

  • SHOW GLOBAL STATUS LIKE ‘Opened_tables’ : 150K

  • SHOW VARIABLES LIKE ‘%open%’ :

        open_files_limit    200000
        table_open_cache    40000
    

Solutions tried :

  • restart server : it works the opened tables counter is 0 but this isn’t a good solution from my pov since you will need a restart every week because the counter will increase fast

  • FLUSH TABLES : like the mysql doc said it should force all tables in use to close but this doesn’t happen

So any thoughts on this matter?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T18:35:11+00:00Added an answer on June 17, 2026 at 6:35 pm

    Generally, many open tables are nothing to worry about. If you come close to OS limits, you can increase this limits in the kernel settings:

    How do I change the number of open files limit in Linux?

    MySQL opens tables for each session independently to have better concurrency.

    The table_open_cache and max_connections system variables affect the maximum number of files the server keeps open. If you increase one or both of these values, you may run up against a limit imposed by your operating system on the per-process number of open file descriptors. Many operating systems permit you to increase the open-files limit, although the method varies widely from system to system.

    In detail, this is explained here

    http://dev.mysql.com/doc/refman/5.5/en/table-cache.html

    EDIT

    To verify your assumption you could decrease max_connections and table_open_cache temporarily by SET GLOBAL table_open_cache := newValue.

    The value can be adjusted dynamically without a server restart.

    Prior MySQL 5.1 this variable is called table_cache

    What I was trying to tell, is, that decreasing this value will probably even have a negative impact on performance in terms of less possible concurrent reads (queue get’s longer), instead you should try to increase the OS limit and increase max_open_files, but maybe I just don’t see the point here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Wondering if there is any way to get the lambda expressions that result from
Wondering if there is a good way to generate temporary URLs that expire in
just wondering if there is a way to reduce the amount of code needed
Just wondering is there any way I can check whether the url links to
Just wondering if there is any way to get the NS records in C#.
Wondering if there is a way I could trigger an event, so that any
HI there I was wondering if there is a better way of testing that
Hi there i was wondering is there a way to write your code so
Just wondering if there is a way you can attach a function while startDrag
wondering if there is a way to do the following: I basically want to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.