On Tue, 18 Sep 2001, Massimo Miccoli wrote:

> Hi,
> 
> I'have reached the Mysql table size limit with urlword table. I'have
> RedHat 7.1 enterprise kernel ( 4GB+ file size). From mysql manual:
> ...By default, MySQL tables have a maximum size of about 4G. You can
> check the maximum table size for a table with the SHOW TABLE STATUS
> command or with the myisamchk -dv table_name. See section 4.5.5 SHOW
> Syntax. If you need bigger tables than 4G (and your operating system
> supports this), you should set the AVG_ROW_LENGTH and MAX_ROWS parameter
> when you create your table. See section 6.5.3 CREATE TABLE Syntax. You
> can also set these later with ALTER TABLE. See section 6.5.4 ALTER TABLE
> Syntax....
> 
> How Can I set this option in urlword (and other table)? Any Help.

To get an increase over 4Gb in Max_data_length you need to set MAX_ROWS large
enough that AVG_ROW_LENGTH * MAX_ROWS is greater than 4Gb. 

Try:

  alter table urlword MAX_ROWS=100000000;

e.g.

mysql> show table status;
+------------+ ... ----------------+-----------------+ ...
| Name       |      Avg_row_length | Max_data_length |
+------------+ ... ----------------+-----------------+ ...
| urlword    |                 152 |      4294967295 |
+------------+ ... ----------------+-----------------+ ...
mysql> alter table urlword MAX_ROWS=100000000;
mysql> show table status;
+------------+ ... ----------------+-----------------+ ...
| Name       |      Avg_row_length | Max_data_length |
+------------+ ... ----------------+-----------------+ ...
| urlword    |                 152 |   1099511627775 |
+------------+ ... ----------------+-----------------+ ...

Note:

  alter table urlword MAX_ROWS=10000000;

would not have increased Max_data_length since 152 * 10000000 < 4Gb.


Matt.

Reply via email to