Submitted by christefano on Thu, 12/08/2011 - 18:35 Pro Licensee
So, I'm trying to clone a virtual server to create a new dev site and I'm thinking this is a perfect time to use the clone tool. I'm getting these errors:
$ virtualmin clone-domain --domain www.example.com --newdomain dev.example.com --newuser example.dev --newpass password
Cloning virtual server www.example.com to dev.example.com with username example.dev ..
Creating new virtual server settings ..
.. done
Allocating new IPv4 address ..
.. no IPv4 allocation ranges have been configured
.. cloning failed!
This happens whether the virtual server has SSL enabled or not. I added a couple IPv4 addresses that are allocated to my server to the default templates and the clone tool reported that it still couldn't find a free IP address. Do you have any ideas?
Status:
Closed (fixed)
Comments
Submitted by JamieCameron on Thu, 12/08/2011 - 18:56 Comment #1
If the domain being cloned has a private IP address, Virtualmin will need to allocate a new one for the clone. This means that you have to setup an IP allocation range, at System Settings -> Server Templates -> Default Settings -> Virtual IP Address.
Submitted by christefano on Thu, 12/08/2011 - 19:50 Pro Licensee Comment #2
That makes sense. This virtual server has an external IP, though, and that's the range that I put in the template virtual IP address settings.
Submitted by JamieCameron on Thu, 12/08/2011 - 19:52 Comment #3
Have you upgraded to Virtualmin 3.89 yet? I seem to recall I fixed a bug in this area that was in the 3.88 release ..
Submitted by christefano on Fri, 12/09/2011 - 00:19 Pro Licensee Comment #4
I'm using 3.89.
When I add an IP range in the "Virtual IP Addresses" part in Server Templates, I get this:
Cloning virtual server www.example.com to dev.example.com with username example.dev ..
Creating new virtual server settings ..
.. done
Allocating new IPv4 address ..
.. no free IPv4 address was found
.. cloning failed!
I think it would make more sense to allow the setting of an IP address directly from the "Clone Virtual Server" form.
Submitted by JamieCameron on Fri, 12/09/2011 - 00:21 Comment #5
That error means that Virtualmin thinks that every IP in the range is in use by a domain or pingable..
Submitted by christefano on Mon, 01/02/2012 - 20:29 Pro Licensee Comment #6
What would be ideal, I think, is to be able to enter the new IP address when cloning a virtual server (similar to how a new IP address can be entered when creating a new virtual server or sub-server). Choosing which features are getting cloned would be very useful, too.
As it is now, I have several free IP addresses that are in /etc/network/interfaces but aren't used by Virtualmin for any virtual servers. Virtualmin still gives me the error:
Allocating new IPv4 address ..
.. no IPv4 allocation ranges have been configured
Is there another place to enter this information in advance? As noted in #4, I do see a "Virtual IP address" section in Server Templates, but manually entering the available IP ranges there is not working as expected.
Submitted by JamieCameron on Mon, 01/02/2012 - 23:11 Comment #7
You should remove the IPs from /etc/network/interfaces , or else Virtualmin will think they are in use - then automatic IP allocation should work.
Another option is to revert the source domain to a shared IP address, clone it, and then assign the specific IP that you want to the clone.
Submitted by christefano on Sun, 02/12/2012 - 13:35 Pro Licensee Comment #8
Right, all the IP addresses that I have are already in /etc/network/interfaces so that they're available when I manually create new virtual servers.
Another option is to revert the source domain to a shared IP address, clone it, and then assign the specific IP that you want to the clone.
Would it be possible to add this to the existing form and workflow?
Submitted by JamieCameron on Sun, 02/12/2012 - 17:47 Comment #9
Sure .. I will look into adding this for the next Virtualmin release.
Submitted by JamieCameron on Wed, 02/15/2012 - 20:07 Comment #10
This has been implemented, for inclusion in Virtualmin 3.91.
Submitted by Issues on Wed, 02/29/2012 - 20:17 Comment #11
Automatically closed -- issue fixed for 2 weeks with no activity.