reapir mysql table from php

Ask a Question related to PHP Development, Design and Development.

  1. #1

    Default reapir mysql table from php

    I have an on-going problem that my ".MYI" mysql files get corrupted.
    I have written php trapping routine to report on the problem to
    admin. My next step is to initiate "repair table" right after the
    error is trapped.

    The problem is that then I would have multiple repair table commands
    initiated from different browser sessions. How can I make sure that
    only one "repair table" is running at a time.

    --
    [url]http://www.dbForumz.com/[/url] This article was posted by author's request
    Articles individually checked for conformance to usenet standards
    Topic URL: [url]http://www.dbForumz.com/PHP-reapir-mysql-table-ftopict151640.html[/url]
    Visit Topic URL to contact author (reg. req'd). Report abuse: [url]http://www.dbForumz.com/eform.php?p=507693[/url]
    steve Guest

  2. Similar Questions and Discussions

    1. MySQL: What Table Type are you ?>
      Which is better: MyISAM or INNODB ?? All the apps I've written thus far are MyISAM; however, INNODB offers our dear friend `referential...
    2. MySQL tempory table rights
      I had a problem with this query (MySQL-4.1.0-alpha-standard): $query = "SELECT `id` , `date`, `date_added`, `title` " . "FROM ( " . " ...
    3. Testing if a mysql table exists
      Is there a simple way to test if a mysql table exists? JUST One line !
    4. I can't insert into mySQL db table - HELP!
      I have to get this done by tonight! I have a .CSV file and a PHP file where I am inserting the values of the CSV file into the db table. See the...
    5. PHP and MySQL Table Joins
      I am having a hard time with joins - my following code displays: ..member_name .gender instead of the actual data - I've been reading through...
  3. #2

    Default Re: reapir mysql table from php


    steve wrote:
    > I have an on-going problem that my ".MYI" mysql files get corrupted.
    > I have written php trapping routine to report on the problem to
    > admin. My next step is to initiate "repair table" right after the
    > error is trapped.
    >
    > The problem is that then I would have multiple repair table commands
    > initiated from different browser sessions. How can I make sure that
    > only one "repair table" is running at a time.
    Search for 'singleton class'

    /Marcin
    Marcin Dobrucki Guest

  4. #3

    Default Re: reapir mysql table from php

    steve wrote:
    > I have an on-going problem that my ".MYI" mysql files get corrupted.
    > I have written php trapping routine to report on the problem to
    > admin. My next step is to initiate "repair table" right after the
    > error is trapped.
    Out of curiosity... how are you db files getting corrupted? Is the
    server constantly shut off without a shutdown procedure? Perhaps
    enabling logging on the filesystem and making sure the computer doesn't
    creash is the way to go?

    /m
    Marcin Dobrucki Guest

  5. #4

    Default Re: reapir mysql table from php

    Hi Steve,

    you're coming home from the backyard. Try the front door. Why would
    you want users(browser sessions) iniatiate the repair sequence? This
    is usually done by a cron job. If this repair procedure should be
    event driven you may want to put a database in between the cron job
    and the client application. The application would check the integrity,
    if a repair procedure is needed, the flag in database would be set.
    Afterwards the only task for the cron-job would be checking the repair
    flag and carrying out necessary operations, if required.

    Best Regards,

    Lucas


    steve <UseLinkToEmail@dbForumz.com> wrote in message news:<414f45f2$1_2@alt.athenanews.com>...
    > I have an on-going problem that my ".MYI" mysql files get corrupted.
    > I have written php trapping routine to report on the problem to
    > admin. My next step is to initiate "repair table" right after the
    > error is trapped.
    >
    > The problem is that then I would have multiple repair table commands
    > initiated from different browser sessions. How can I make sure that
    > only one "repair table" is running at a time.
    Lucas Guest

  6. #5

    Default Re: Re: reapir mysql table from php

    "Marcin Dobrucki" wrote:
    > steve wrote:
    > > I have an on-going problem that my ".MYI" mysql files get
    > corrupted.
    > > I have written php trapping routine to report on the
    > problem to
    > > admin. My next step is to initiate "repair table" right
    > after the
    > > error is trapped.
    >
    > Out of curiosity... how are you db files getting corrupted?
    > Is the
    > server constantly shut off without a shutdown procedure?
    > Perhaps
    > enabling logging on the filesystem and making sure the
    > computer doesn't
    > creash is the way to go?
    >
    > /m
    I have a server with heavy load. Once every few days, I get this
    corruption. I have posted on this ng with no results...

    The server is constantly up, so it is not related to that.

    --
    [url]http://www.dbForumz.com/[/url] This article was posted by author's request
    Articles individually checked for conformance to usenet standards
    Topic URL: [url]http://www.dbForumz.com/PHP-reapir-mysql-table-ftopict151640.html[/url]
    Visit Topic URL to contact author (reg. req'd). Report abuse: [url]http://www.dbForumz.com/eform.php?p=508966[/url]
    steve Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139