Multiple domains on 1 IP


I have set up Virtualmin GPL on my server, which is in my local home network currently. Whole installation worked flawlessly. I have installed both Webmin amd Virtualmin from deb packages. My question is how can I set up multiple accounts on 1 IP address, like it can set up on cPanel and Directadmin. For example I have noticed that when my website was set up I could access it like this: http:///~username
or better exmaple:

How can this set up on Virtualmin?

It should be no problem at all to setup as many domains as you want on one IP address – that’s what Virtualmin does by default, and is well-supported by Apache.

If you want multiple accounts to have websites, but they don’t have unique domain names, you might consider setting up aliases for them.

For example, if you’re domain is, you can setup aliases that point to each users DocumentRoot.

Some additional ideas are mentioned in here:,frequently_asked_questions/#how_do_i_make_a_users_website_available_at_httpwww.mydomain.tldcustomerdomain

Hi, again so I did set up few domains in local network, but I cannot access them like this
What am I doing wrong? I have tried to assign a virtual IP and assign it to some other domain at the same time and I could access it using ip, but I couldn’t access using the method /~username at the end :S How do I set this up in LAN?

The Apache folks discourage using the that you’re describing.

If you wish to do that anyhow, instructions on how to enable that are in the FAQ I linked above – you’ll need to follow the steps there to enable the Apache module for handling that.


Hello again,

why do they discourage using it, does this have an a major security risk? Is there a way accessing it some other way, if I won’t install the module as you suggest?

you can edit your client hosts file to point a domainname to a server in LAN. mydomain.tld www.mydomain.tld otherdomain.tld www.otherdomain.tld

if you are on a winbox…c:windows/system32/drivers/etc/hosts

The problems are discussed in the FAQ Eric linked you to, as are several better alternatives. They are mostly related to the lack of suexec support in such a configuration, which means executable scripts can have significant data exposure risks.

I’m not sure what you want us to tell you beyond the documented options (including the one you’re specifically asking about).


this worked perfectly, thanks, now I’ll try to figure out the rest.