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

  • SEARCH
  • Home
  • 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 7985283
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T11:30:38+00:00 2026-06-04T11:30:38+00:00

I have an Amazon EC2 Server instance and it is attached with five EBS

  • 0

I have an Amazon EC2 Server instance and it is attached with five EBS volumes say

  1. ebsvol1
  2. ebsvol2
  3. ebsvol3
  4. ebsvol4
  5. ebsvol5

while provisioning this server I need to install MySQL Server and need set up my Database. Here I need to mount few tables to one EBS volume (say ebsvol1) and other tables to another volume (say ebsvol2).

I am beginner to this Amazon env. Please guide me how to proceed.

  • 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-04T11:30:39+00:00Added an answer on June 4, 2026 at 11:30 am

    This answer applies to LINUX-based instances.

    Start with this article at Amazon which explains how to set up MySQL to run on an EBS volume. This is not strictly necessary – the following steps should work fine with a standard MySQL installation.

    You will need to create a new schema for each EBS volume / group of tables. I don’t believe you can keep your tables in one schema, but spread them over multiple EBS volumes. Each empty schema is represented by a folder in /var/lib/mysql/ containing a single file named db.opt.

    To move a schema to it’s own EBS volume requires the following steps (using schema my_schema):

    • mount the EBS volume if not already mounted (assuming mounted as /ebsvol1); make sure the volume is listed in /etc/fstab so it will get automatically mounted on reboots

    • change permissions of the mounted folder to match the current schema folder

       chmod 700 /ebsvol1
       chown mysql /ebsvol1
       chgrp mysql /ebsvol1
    
    • copy the db.opt file from the schema folder to the new volume (if you have already created tables under the schema, those too need to be copied)
       cp /var/lib/mysql/my_schema/db.opt /ebsvol1/
       chmod 660 /ebsvol1/db.opt
       chown mysql /ebsvol1/db.opt
       chgrp mysql /ebsvol1/db.opt
    
    • replace the original schema folder with a symbolic link to the EBS volume
       cd /var/lib/mysql
       rm -fr my_schema
       ln -s /ebsvol1 my_schema
    

    If your operating system uses AppArmor, you may need to include /ebsvol1 in the list of folders MySQL is allowed to write to. See the article here for details.

    Now any tables created under my_schema will be stored on /ebsvol1.

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

Sidebar

Related Questions

I have created an Amazon EC2 Instance that provides Windows Server 2008 with SQL
I have a MongoDB server running on an 64-bit Amazon EC2 instance (journaling enabled).
I have a puppet master server running in a Amazon EC2 instance. I spawn
I have an server process with internal registry (on an Amazon EC2 instance). The
I have server instance running on amazon ec2. I want to forward from port
I have a django test, on an amazon ec2 instance, I see the It
I have elastic search running on a linux instance on Amazon EC2. I use
We are using a dedicated Amazon Ubuntu ec2 instance as Cron server, which executed
I have ubuntu instance on Ec2 cloud server and on same instance I have
Hi I have created an amazon ec2 instance and now I need to deploy

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.