I need help moving virtualmin to other hard disk

My OS: Ubuntu 8.04 and my server is in data center now.
I have virtualmin on hard disk which has bad blocks and it is going to die sooner or later.
I have another hard disk (mounted on /home) where all websites are located.

So I bought 74GB Raptor (system disk with bad blocks is 80GB disk).

Now at home I have already installed Ubuntu 8.04, virtualmin and other things.

Can I make backup from server without making backup for /home directory (because it is very big and I don’t have so big hard disk home)?
Can I use new Raptor hard disk and later mount my hard disk where are all websites are saved? Can I loose data? Will I have problems with permissions? Thank You for answers.
Virtualmin the best! :slight_smile:

Post edited by: malinens, at: 2009/02/22 02:45<br><br>Post edited by: malinens, at: 2009/02/22 02:46

Sure, you can go into Backup and Restore -> Backup Virtual Servers, and you can pick and choose what exactly to backup. You could grab everything but the home directory data if you like.

And then you can mount your other disk when you’re ready, and copy off all the data.

Can you loose data? Well, that all depends on how bad the damage on your hard disk is :slight_smile:

Will you have problems with permissions? Not if you copy the data in a manner that preserves the permissions. I’d either use a tool like rsync, or if you use cp to do the copy, make sure you’re using the “-p” option to copy over the existing ownership and permissions.

Have a good one,
-Eric

I will use old hard disk which is used for /home directory and I will only change system disk which has bad blocks. I created backup file with all features except “Server’s home directory and web pages”.

I have question about "Re-allocate UIDs and GID?" in restore menu. Do I need to set it to yes or no? Thank You for answer :slight_smile:

And if I checked “Server’s home directory and web pages” in restore menu, virtualmin created home directories without website content (because I didn’t created backup for website content). Do I need to check “Server’s home directory and web pages” in restore menu or better leave it empty? Thank You!

I have an error now after I was playing with backup/restore, now I can’t even restore the backup on new installation:

[code:1]Starting restore of 65 domains from local file /home/juris/backup …

Extracting backup archive file …
… done

Re-creating virtual server ads.bwap.org
… a clash was detected : A PostgreSQL database called ads or user called ads already exists

Restoring Virtualmin settings (Module configuration, Server templates, New mailbox email messages, Custom fields, links and shells, Scheduled Virtualmin backups, FTP directory restrictions) …
… done

Applying FTP server configuration …
… done

… failed! See the progress output above for the reason why.[/code:1]

For re-allocating UID’s and GID’s, I think you can leave that at the default, it tends to do the right thing :slight_smile:

As for what to have it restore – it should attempt to restore everything by default – and that’s fine.

You can then just copy over the home directory files later.

As far as why the Postgres database isn’t being restored – is there an existing database or user on your system with that name?
-Eric

Help me please!

I changed system disk, restored anything and now I have all permissions for all sites upside-down!
For exmaple, all user’s “domain1” files are chown: domain99:domain99, all files for user “domain18” have CHOWN: other:other etc.

I hope You’ll help me as soon as possible! Thank You!

False alarm!
All other sites except sites with domain name bwap.org (upload.bwap.org, forum.bwap.org) are working! How to get bwap.org domain name working? I get error 500 internal server error using LYNX web browser (from other browsers I get blank page).

bwap.org is my domain name used when I installed Virtualmin GPL.
I tried remove bwap.org from /etc/hosts, restarted server but still it is not working…

I’m glad your other sites are working :wink:

If you ever get a 500 Internal Server Error, trying looking in the error logs for that Virtual Server, it would say in there what the specific problem is.

That’s in $HOME/logs/error_log.
-Eric

OK, I found that I forgot to install some additional php/pecl/pear modules :slight_smile:

But I have still problems with this weird problem with users and I get error disk quota exceed but I have set up disk quota 200GB…

And in one virtual server I can not log in into FTP but I am 100% sure I have entered correct login and password because I copy&pasted them from virtualmin controlpanel…

For the FTP user – look in /var/log/auth.log whenever you attempt to login. Do you see any errors in there? Also, make sure the users shell is one that allows FTP logins.

For the quote issues – try going into Limits and Validation -> Check Disk Quotas, select "Both users and groups", and hit "Check now".

That should refresh the quotas – does that help?
-Eric

I CHOWNed all files for all the 60 servers but FTP problem still exists.

I ran queta check and edited server configuration(changed quota size):

[code:1]Checking user quotas on / …

… done

Check group quotas on / …

… done[/code:1]

I can upload on some servers but many have disk quota problem.
I know server bwap.rog has more than 40GB of files but virtualmin shows I have used only 68kb of files… :slight_smile:

I CHOWNed all files for all the 60 servers but FTP problem still exists.

I ran queta check and edited server configuration(changed quota size):

[code:1]Checking user quotas on / …

… done

Check group quotas on / …

… done[/code:1]

I can upload on some servers but many have disk quota problem.
I know server bwap.rog has more than 40GB of files but virtualmin shows I have used only 68kb of files… :slight_smile:

I have this error now:
Administration user : Unix user next’s quota of 1024 kB does not match the domain owner’s quota of 11 GB