0

I own a debian root web server at an ISP. By own I mean, I rent the server with a package, I do not own the hardware and such. No plesk or anything else. All configuration is done by hand (well, a self-written shell script does the dirty repetitive work).

This server is used as a development server, where many websites are run with different apache2 vhost settings, and databases on one mysql instance. It may be that the most of them are not touched in a long time, but then the customers want to make some changes and we need to work on them again. There are always 3 or 4 active development projects which run parallel. The servers do not have much traffic, only some developers, project managers, and the client.

With apache it is fairly easy to switch a vhost on and off, but it's not that easy with MySQL as I cannot deactivate a database. I could only drop it after some backup. But as it uses many InnoDB tables, I'm afraid I get into trouble when ressurecting the database. So I have many sleeping databases which may use RAM memory. I'm hoping I could prevent this, if I had a virtual settings with real virtual servers I could easily switch on and off

On my desktop computer (WIN10) it is fairly easy to do it with VirtualBox and the like to set up virtual servers (utilizing e.g. vagrant). But I don't know, if I can run VirtualBox or similar software on my webserver (no X system).

So here's the question: How (if possible) can I run virtual servers on a hosted webserver with root access?

If this is not possible, is there a secure way to backup/drop/restore entire MySQL databases with InnoDB tables?

Note:

I know, how to use vhost settings from apache. That's not, what I'm asking for.

Note2:

There may be other benefits as well:

  • Better security by encapsulating.
  • Better flexibility by setting the servers properties for any instance for itself
  • Better transportability by making a package out of the virtual server
  • Better collaboration through that transportability

closed as off-topic by Stephen Ostermiller Dec 10 '15 at 19:08

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions asking for recommended external websites, tools, resources, and software are off-topic as they tend to attract opinionated answers and spam. Recommendations for software are permitted on Software Recommendations, but be sure to read their quality guidelines before posting there." – Stephen Ostermiller
If this question can be reworded to fit the rules in the help center, please edit the question.

2

So I have many sleeping databases which may use RAM memory

What you are calling "sleeping" databases -- databases you are not accessing -- do not consume any meaningful resources on a MySQL server other than the physical disk space they occupy.

The "working data set" (tables you are accessing) is kept in memory in the InnoDB buffer pool to the extent possible, for performance reasons, but this pool is limited to a fixed size in memory, SELECT @@INNODB_BUFFER_POOL_SIZE;. If you start working with some tables, those tables will be loaded (in chunks) into the buffer pool (as you access specific pages of data), evicting old content from the pool.

There is really no significant impact of having idle/unused tables full of data on the server.

  • I think I already know what you mean. But that does not answer my question – yunzen Dec 11 '15 at 8:05

Not the answer you're looking for? Browse other questions tagged or ask your own question.