Acceso a 3w y guarani, mismo server, misma IP, distinto DNS

Hola que tal?

Quería saber que estoy haciendo mal puesto que estoy intentando configurar el APACHE para ingresar a guarani a traves del DNSNAME = gestion.dominio.com y al 3w como alumno.dominio.com.

La config que tengo en apache es:

<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /home/dominio/guarani/www
ServerName gestion.dominio.com

<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /home/dominio/3w/src/siu/www/
ServerName alumno.dominio.com

Si ingreso al primero, funciona sin problemas. Si quiero ingresar al segundo, arroja el error que adjunto.
Por otro lado, si ingreso como gestion.dominio.com/3w o alumno.dominio.com/3w ingresa sin problemas (esto es debido a que es lo mismo que reemplazar el DNS por el IP)

En errores de apache, figura el siguiente:

Uncaught Exception: La entrada $_SERVER[“ACC_ID”] no est\xe1 definida, hay un error en la configuraci\xf3n in /home/insusep/3w/src/siu/bootstrap.php:270\nStack trace:\n#0 /home/insusep/3w/src/siu/bootstrap.php(160): siu\bootstrap->get_id_bloque_acceso()\n#1 /home/insusep/3w/src/siu/bootstrap.php(128): siu\bootstrap->test_errores_configuracion()\n#2 /home/insusep/3w/src/siu/bootstrap.php(68): siu\bootstrap->cargar_config()\n#3 /home/insusep/3w/src/siu/bootstrap.php(35): siu\bootstrap->_cargar(false, false)\n#4 /home/insusep/3w/src/siu/www/index.php(14): siu\bootstrap::cargar()\n#5 {main}\n thrown in /home/insusep/3w/src/siu/bootstrap.php on line 270

estoy seguro que debe ser algún parametro que falte agregar en 3w.conf, pero desconozco cual puede ser.

Agradecería ayuda.

Saludos,


Error al ingresar 3w - mismo IP distintos DNS.png

Error al ingresar 3w - mismo IP distintos DNS.png

Hola

<VirtualHost *:80>

cambialo por

Gracias por la respuesta.

A gestion.dominio.com ingresa bien

El problema es cuando quiero ingresar a alumno.dominio.com

Ahí tira el error de HTTP 500 y el error que adjunté del apache, que hace referencia al ACC_ID.

Saludos,

Amplio un poco mi configuración de apache:

/etc/apache2/sites-enabled/3w.conf

Este template permite tener instalado en diferentes alias las diferentes unidades

académicas y también define de manera centralizada todo el manejo de nombres en los dominios

LOS ALIAS NO TIENEN QUE TENER PUNTOS

<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request’s Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName www.example.com

    ServerAdmin webmaster@localhost
    DocumentRoot /home/dominio/3w/src/siu/www
    ServerName alumno.dominio.com

    # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
    # error, crit, alert, emerg.
    # It is also possible to configure the loglevel for particular
    # modules, e.g.
    #LogLevel info ssl:warn

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

    # For most configuration files from conf-available/, which are
    # enabled or disabled at a global level, it is possible to
    # include a line for only one particular virtual host. For example the
    # following line enables the CGI configuration for this host only
    # after it has been globally disabled with "a2disconf".
    #Include conf-available/serve-cgi-bin.conf
Alias /3w "home/dominio/3w/srv/siu/www" Require all granted Options FollowSymLinks DirectoryIndex index.php Order allow,deny AllowOverride All Allow from all AddDefaultCharset ISO-8859-1 include /home/insusep/3w/dominio/rewrite.conf # representa el id interno de la unidad académica. Se correponde con la entrada # en el archivo config.yml ua_. Ej: ua_VET SetEnv ACC_ID des01
    # se setea de esta manera para que esta variable sea accesible desde mod_rewrite
    # ATENCIç?N: el alias debe empezar con '/'
    SetEnvIf always_match ^ ACC_ALIAS=/3w

/etc/apache2/sites-enabled/000-default.conf

<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request’s Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName www.example.com

    ServerAdmin webmaster@localhost
    DocumentRoot /home/dominio/guarani/www/
    ServerName gestion.dominio.com

    # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
    # error, crit, alert, emerg.
    # It is also possible to configure the loglevel for particular
    # modules, e.g.
    #LogLevel info ssl:warn

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

    # For most configuration files from conf-available/, which are
    # enabled or disabled at a global level, it is possible to
    # include a line for only one particular virtual host. For example the
    # following line enables the CGI configuration for this host only
    # after it has been globally disabled with "a2disconf".
    #Include conf-available/serve-cgi-bin.conf

Si ingreso a gestion.dominio.com, ingreso a gestión sin problemas.
Si ingreso a gestion.dominio.com/3w, ingreso a autogestión sin problemas.
Si ingreso a alumno.dominio.com, arroja error
Si ingreso a alumno.dominio.com/3w, ingreso a autogestión sin problemas.

Algo hay en la config que obliga a ingresar con /3w.

Desde ya, muchas gracias.

Saludos,

/etc/apache2/sites-enabled/3w.conf

Este template permite tener instalado en diferentes alias las diferentes unidades

académicas y también define de manera centralizada todo el manejo de nombres en los dominios

LOS ALIAS NO TIENEN QUE TENER PUNTOS

ServerAdmin webmaster@localhost DocumentRoot /home/dominio/3w/src/siu/www ServerName alumno.dominio.com
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

<Directory “/home/dominio/3w/src/siu/www”>
Require all granted
Options FollowSymLinks
DirectoryIndex index.php
Order allow,deny
AllowOverride All
Allow from all
AddDefaultCharset ISO-8859-1
include /home/insusep/3w/dominio/rewrite.conf

SetEnv ACC_ID des01

    SetEnvIf always_match ^ ACC_ALIAS=/