subdomain errors.

I got creating domains working and trying to now create a subdomain but all i get is :

Failed to create virtual server : Missing or invalid IP address

This error is actually quite cryptic. In creating subdomains there is no IP address entered there at all so which IP address is this and where is it coming from?

The line 147 below from “domain_setup.cgi” is where it’s coming from.

    if ($config{'all_namevirtual'}) {

            # Make sure the IP *is* assigned
            &check_ipaddress($in{'ip'}) || &error($text{'setup_eip'});

Hey George,

Yep, that error message is a bit iffy. We’ll see if we can’t get something a little less cryptic. It could very well be a bug, so I’ve filed a new bug in the bug-tracker here:

It looks like you have the ‘All Apache virtual servers are name-based?’ option enabled on the Module Config page. Very few sites really need this, so you should turn it off …

I have reasons for it to be turned on. Firstly this server will have it’s IP changed eventually and in doing so it wouldn’t cause all my virtualhosts to stop working only because the IP address isn’t IP assigned. Make sense…

< VirtualHost *:80>

will work on any address it receives a connection from. Virtualmin doesn’t give the option to do this afaik as it always tries puts the IP address. confuses me when I turned on “All Apache virtual servers are name-based”…

So turning off, is not a solution to the problem.

LOL… Virtualmin is a joke.

You’re solution is to turn NameVirtualHost off when it’s a standard feature of Apache and your main configuration for Virtualmin has it as an option yet within a single day you guys close off the bug by using a work around which is not suitable for me and god knows who else who needs it.

If this is how you handle the free version i hate to think how you treat your paying customers.

Looks like I have to patch your software for you.

Problem fixed. I have patched Virtualmin to ignore the IP when namebased is used and inserted in all effected areas $in{‘ip’} = “*”;

Now namebased works for me for domains and subdomain… eg below. (note: a space is added to the front of each tag due to this forums html restrictions…)

< VirtualHost *:80>
SuexecUserGroup "#503" "#502"
DocumentRoot /var/www/vhosts/
ErrorLog /var/www/vhosts/
CustomLog /var/www/vhosts/ common
ScriptAlias /cgi-bin/ /var/www/vhosts/

   [ Directory /var/www/vhosts/;
            Options Indexes IncludesNOEXEC ExecCGI FollowSymLinks
            allow from all
           [ IfModule sapi_apache2.c&gt;
                    php_admin_flag engine on
                    php_admin_flag magic_quotes_gpc off
                    php_admin_flag safe_mode off
                    php_admin_value open_basedir &quot;/home/webmail:/tmp:/usr/share/pear:/usr/sbin&quot;
                    php_admin_value include_path &quot;/usr/share/pear:.&quot;
           [ /IfModule&gt;
   [ /Directory&gt;

< /VirtualHost>