Solved

MySQL cannot create tables / DBs as root!!!

Posted on 2006-06-12
4
256 Views
Last Modified: 2010-05-18
I run mysql on my RedHat system and I have this problem.
when I log onto mysql and try to create a table in one of my DBs:

-bash-2.05b# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 62 to server version: 3.23.58

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> use test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed

mysql> CREATE TABLE `eggster` (
`id` int(11) NOT NULL auto_increment,
`number` int(11) NOT NULL default '0',
`type` varchar(60) NOT NULL default '',
`addr` varchar(130) NOT NULL default '',
`city` varchar(130) NOT NULL default '',
`state` varchar(130) NOT NULL default '',
`zip` int(20) NOT NULL default '0',
`phone` bigint(20) default NULL,
`fax` bigint(20) default NULL,
`pphone` bigint(20) default NULL,
`fphone` bigint(20) default NULL,
`manager` varchar(130) default NULL,
`pmanager` varchar(75) default NULL,
`sb` enum('N','Y') NOT NULL default 'N',
`rest` enum('N','Y') NOT NULL default 'N',
`pharm` enum('N','Y') NOT NULL default 'N',
`liq` enum('N','Y') NOT NULL default 'N',
`fuel` enum('N','Y') NOT NULL default 'N',
`atm` enum('N','Y') NOT NULL default 'N',
`bank` enum('N','Y') NOT NULL default 'N',
`hisp` enum('N','Y') NOT NULL default 'N',
`photo` enum('N','Y') NOT NULL default 'N',
`postal` enum('N','Y') NOT NULL default 'N',
`ups` enum('N','Y') NOT NULL default 'N',
`inter` enum('N','Y') NOT NULL default 'N',
`natur` enum('N','Y') NOT NULL default 'N',
`rug` enum('N','Y') NOT NULL default 'N',
`design` enum('N','Y') NOT NULL default 'N',
`dining` enum('N','Y') NOT NULL default 'N',
`vid` enum('N','Y') NOT NULL default 'N',
`wu` enum('N','Y') NOT NULL default 'N',
`cu` enum('N','Y') NOT NULL default 'N',
`parcel` enum('N','Y') NOT NULL default 'N',
`express` enum('N','Y') NOT NULL default 'N',
`hours` text,
`phours` text,
`latitude` decimal(26,20) default NULL,
`longitude` decimal(26,20) default NULL,
`map_direction` enum('N','E','S','W') default 'N',
`map_size` decimal(2,1) default NULL,
PRIMARY KEY  (`id`)
) TYPE=MyISAM AUTO_INCREMENT=39

Error occured at:2006-06-12 21:33:30
Line no.:43
Error Code: 3 - Error writing file './test/eggster.frm' (Errcode: 28)

what is the problem?

0
Comment
Question by:eggster34
4 Comments
 
LVL 30

Expert Comment

by:todd_farmer
ID: 16888170
Does the account under which the MySQL server is running have the appropriate file permissions to the ./test/ directory?
0
 

Author Comment

by:eggster34
ID: 16888360
yes. I found out what the problem is:

-bash-2.05b# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/md4             1012M  374M  587M  39% /
/dev/md1               99M   26M   69M  27% /boot
/dev/md0               26G  2.1G   23G   9% /home
none                  501M     0  501M   0% /dev/shm
/dev/md5              494M  8.5M  460M   2% /tmp
/dev/md2               51G  2.4G   46G   5% /usr
/dev/md6              494M  487M     0 100% /var
/dev/sdc1             147G   42G   99G  30% /root/snapshot

my /var is %100 full and my mysql DB is in /var.
how can I empty or grow the /var mount? or perhaps move it to one of the larger drives?

-bash-2.05b# fdisk -l

Disk /dev/sda: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot    Start       End    Blocks   Id  System
/dev/sda1             1         4     32098+  de  Dell Utility
/dev/sda2             5      3410  27358695   fd  Linux raid autodetect
/dev/sda3   *      3411      3423    104422+  fd  Linux raid autodetect
/dev/sda4          3424     19929 132584445    f  Win95 Ext'd (LBA)
/dev/sda5          3424     10059  53303638+  fd  Linux raid autodetect
/dev/sda6         10060     10320   2096451   fd  Linux raid autodetect
/dev/sda7         10321     10451   1052226   fd  Linux raid autodetect
/dev/sda8         10452     10516    522081   fd  Linux raid autodetect
/dev/sda9         10517     10581    522081   fd  Linux raid autodetect

Disk /dev/sdb: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot    Start       End    Blocks   Id  System
/dev/sdb1   *         1         4     32098+   b  Win95 FAT32
/dev/sdb2             5      3410  27358695   fd  Linux raid autodetect
/dev/sdb3          3411      3423    104422+  fd  Linux raid autodetect
/dev/sdb4          3424     19929 132584445    f  Win95 Ext'd (LBA)
/dev/sdb5          3424     10059  53303638+  fd  Linux raid autodetect
/dev/sdb6         10060     10320   2096451   fd  Linux raid autodetect
/dev/sdb7         10321     10451   1052226   fd  Linux raid autodetect
/dev/sdb8         10452     10516    522081   fd  Linux raid autodetect
/dev/sdb9         10517     10581    522081   fd  Linux raid autodetect

Disk /dev/sdc: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot    Start       End    Blocks   Id  System
/dev/sdc1             1     19457 156288321   83  Linux

Disk /dev/md0: 28.0 GB, 28015198208 bytes
2 heads, 4 sectors/track, 6839648 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md0 doesn't contain a valid partition table

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md1 doesn't contain a valid partition table

Disk /dev/md2: 54.5 GB, 54582837248 bytes
2 heads, 4 sectors/track, 13325888 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/md3: 2146 MB, 2146697216 bytes
2 heads, 4 sectors/track, 524096 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md3 doesn't contain a valid partition table

Disk /dev/md4: 1077 MB, 1077411840 bytes
2 heads, 4 sectors/track, 263040 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md4 doesn't contain a valid partition table

Disk /dev/md5: 534 MB, 534511616 bytes
2 heads, 4 sectors/track, 130496 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md5 doesn't contain a valid partition table

Disk /dev/md6: 534 MB, 534511616 bytes
2 heads, 4 sectors/track, 130496 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md6 doesn't contain a valid partition table
-bash-2.05b#

I don't want to move it to sdc1 but any other drive would be ok.

0
 
LVL 5

Accepted Solution

by:
Netminder earned 0 total points
ID: 17118194
Closed, 500 points refunded.
Netminder
Site Admin
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

All XML, All the Time; More Fun MySQL Tidbits – Dynamically Generate XML via Stored Procedure in MySQL Extensible Markup Language (XML) and database systems, a marriage we are seeing more and more of.  So the topics of parsing and manipulating XM…
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now