nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

Tutorial: Setting up MySQL quotas for users (MyISAM)

This is a discussion on Tutorial: Setting up MySQL quotas for users (MyISAM) within the Databases servers forums, part of the Mastering Servers category; Ok, it was me only who asked this question. Now I have found a solution to this. Let the default ...


Go Back   nixCraft Linux Forum > Mastering Servers > Databases servers

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 01-26-2008, 10:01 PM
Junior Member
User
 
Join Date: Jan 2008
Location: Pune
My distro: Fedora 7 (presently). will soon upgrade to 8.
Posts: 3
Rep Power: 0
Nilesh is on a distinguished road
Send a message via ICQ to Nilesh Send a message via MSN to Nilesh Send a message via Yahoo to Nilesh
Default Tutorial: Setting up MySQL quotas for users (MyISAM)

Ok, it was me only who asked this question. Now I have found a solution to this.

Let the default MySQL datadir be /var/lib/mysql

Suppose you have a user foo on the system as well as on MySQL. Now how to limit space for foo ?

create a separate directory for databases in foo's home say /home/foo/dbs with ownership mysql:foo and permissions 3755.

Now move all foo's databases from /var/lib/mysql to /home/foo/dbs

Then create symbolic links to the database named folders.

Example there is one foo's db called db1 in /var/lib/mysql/db1

Code:
# mkdir /home/foo/dbs
# mv /var/lib/mysql/db1 /home/foo/dbs/
# chown mysql:foo /home/foo -Rf
# chmod 3755 -Rf /home/foo
# ln -s /var/lib/mysql/db1 /home/foo/dbs/db1 -v
NOTE- I AM NOT RESPONSIBLE FOR ANY DAMAGES OCCURRED & TO TEST THIS TRY RESTARTING mysqld.

if mysqld starts OK then its working else it isn't.
Reply With Quote
Sponsored Links
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Setting Samba to Bind to an ADS Domain kevv.mai Getting started tutorials 0 04-20-2008 01:47 AM
ffmpeg php tutorial anjanesh Getting started tutorials 3 02-23-2007 12:26 PM
Help in setting up an email server and net gateway ricc Mail Servers 2 01-04-2007 09:33 AM
Configuring disk quotas on Fedora Linux chimu Linux software 2 12-26-2006 10:18 AM
Ubuntu Linux: How do I setup print quotas? cityblogger Linux software 1 07-06-2006 05:11 PM


All times are GMT +5.5. The time now is 04:44 PM.


Powered by vBulletin® Version 3.7.2 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

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