Hi, I have created website on ispconfig admin. Main Domain : http://simura.id Subdomain : http://demo.simura.id/company But main domain is not working ( got 404 not found), while subdomain is working. Please help me what is wrong with my configuration .
the dns is ok, so the problem would appear to be the vhost creation. did you create the website for simura.id? or did you just create the subdomain as a full website?
Yes , i have created the website for simura.id i have chown web11:client1 also for web11/web folder...
FYI, my website simura.id and demo.simura.id , has same name server ns1.simura.id Do i need to create different ns for subdomain ?
no dns is ok, the domain and subdomain are resolving fine. what's the output of Code: ls -l /var/www/sites-available | grep simura please post the contents of any vhost configs found by the above command
I got 3 vhosts for simura 1. simura.id.vhost Code: <Directory /var/www/simura.id> AllowOverride None Require all denied </Directory> <VirtualHost *:80> DocumentRoot /var/www/clients/client1/web11/web ServerName simura.id ServerAlias *.simura.id ServerAdmin [email protected] ErrorLog /var/log/ispconfig/httpd/simura.id/error.log Alias /error/ "/var/www/simura.id/web/error/" ErrorDocument 400 /error/400.html ErrorDocument 401 /error/401.html ErrorDocument 403 /error/403.html ErrorDocument 404 /error/404.html ErrorDocument 405 /error/405.html ErrorDocument 500 /error/500.html ErrorDocument 502 /error/502.html ErrorDocument 503 /error/503.html <Directory /var/www/simura.id/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> <Directory /var/www/clients/client1/web11/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> # suexec enabled <IfModule mod_suexec.c> SuexecUserGroup web11 client1 </IfModule> <IfModule mod_fastcgi.c> <Directory /var/www/clients/client1/web11/cgi-bin> Require all granted </Directory> <Directory /var/www/simura.id/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> <Directory /var/www/clients/client1/web11/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> Action php-fcgi /php-fcgi virtual Alias /php-fcgi /var/www/clients/client1/web11/cgi-bin/php-fcgi-*-80-simura.id FastCgiExternalServer /var/www/clients/client1/web11/cgi-bin/php-fcgi-*-80-simura.id -idle-timeout 300 -socket /var/lib/php7.4-fpm/web11.sock -pass-header Authorization -pass-header Content-Type </IfModule> <IfModule mod_proxy_fcgi.c> #ProxyPassMatch ^/(.*\.php[345]?(/.*)?)$ unix:///var/lib/php7.4-fpm/web11.sock|fcgi://localhost//var/www/clients/client1/web11/web/$1 <Directory /var/www/clients/client1/web11/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler "proxy:unix:/var/lib/php7.4-fpm/web11.sock|fcgi://localhost" </If> </FilesMatch> </Directory> </IfModule> # add support for apache mpm_itk <IfModule mpm_itk_module> AssignUserId web11 client1 </IfModule> <IfModule mod_dav_fs.c> # Do not execute PHP files in webdav directory <Directory /var/www/clients/client1/web11/webdav> <ifModule mod_security2.c> SecRuleRemoveById 960015 SecRuleRemoveById 960032 </ifModule> <FilesMatch "\.ph(p3?|tml)$"> SetHandler None </FilesMatch> </Directory> DavLockDB /var/www/clients/client1/web11/tmp/DavLock # DO NOT REMOVE THE COMMENTS! # IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE! # WEBDAV BEGIN # WEBDAV END </IfModule> </VirtualHost> 2. demo.simura.id.vhost Code: <Directory /var/www/demo.simura.id> AllowOverride None Require all denied </Directory> <VirtualHost *:80> DocumentRoot /var/www/clients/client1/web12/web ServerName demo.simura.id ServerAlias *.demo.simura.id ServerAdmin [email protected] ErrorLog /var/log/ispconfig/httpd/demo.simura.id/error.log Alias /error/ "/var/www/demo.simura.id/web/error/" ErrorDocument 400 /error/400.html ErrorDocument 401 /error/401.html ErrorDocument 403 /error/403.html ErrorDocument 404 /error/404.html ErrorDocument 405 /error/405.html ErrorDocument 500 /error/500.html ErrorDocument 502 /error/502.html ErrorDocument 503 /error/503.html <Directory /var/www/demo.simura.id/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> <Directory /var/www/clients/client1/web12/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> # suexec enabled <IfModule mod_suexec.c> SuexecUserGroup web12 client1 </IfModule> <IfModule mod_fastcgi.c> <Directory /var/www/clients/client1/web12/cgi-bin> Require all granted </Directory> <Directory /var/www/demo.simura.id/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> <Directory /var/www/clients/client1/web12/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> Action php-fcgi /php-fcgi virtual Alias /php-fcgi /var/www/clients/client1/web12/cgi-bin/php-fcgi-*-80-demo.simura.id FastCgiExternalServer /var/www/clients/client1/web12/cgi-bin/php-fcgi-*-80-demo.simura.id -idle-timeout 300 -socket /var/lib/php7.4-fpm/web12.sock -pass-header Authorization -pass-header Content-Type </IfModule> <IfModule mod_proxy_fcgi.c> #ProxyPassMatch ^/(.*\.php[345]?(/.*)?)$ unix:///var/lib/php7.4-fpm/web12.sock|fcgi://localhost//var/www/clients/client1/web12/web/$1 <Directory /var/www/clients/client1/web12/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler "proxy:unix:/var/lib/php7.4-fpm/web12.sock|fcgi://localhost" </If> </FilesMatch> </Directory> </IfModule> # add support for apache mpm_itk <IfModule mpm_itk_module> AssignUserId web12 client1 </IfModule> <IfModule mod_dav_fs.c> # Do not execute PHP files in webdav directory <Directory /var/www/clients/client1/web12/webdav> <ifModule mod_security2.c> SecRuleRemoveById 960015 SecRuleRemoveById 960032 </ifModule> <FilesMatch "\.ph(p3?|tml)$"> SetHandler None </FilesMatch> </Directory> DavLockDB /var/www/clients/client1/web12/tmp/DavLock # DO NOT REMOVE THE COMMENTS! # IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE! # WEBDAV BEGIN # WEBDAV END </IfModule> </VirtualHost> 3. invoice-indowebcity.simura.id.vhost Code: <Directory /var/www/invoice-indowebcity.simura.id> AllowOverride None Require all denied </Directory> <VirtualHost *:80> DocumentRoot /var/www/clients/client1/web13/web ServerName invoice-indowebcity.simura.id ServerAlias *.invoice-indowebcity.simura.id ServerAdmin [email protected] ErrorLog /var/log/ispconfig/httpd/invoice-indowebcity.simura.id/error.log Alias /error/ "/var/www/invoice-indowebcity.simura.id/web/error/" ErrorDocument 400 /error/400.html ErrorDocument 401 /error/401.html ErrorDocument 403 /error/403.html ErrorDocument 404 /error/404.html ErrorDocument 405 /error/405.html ErrorDocument 500 /error/500.html ErrorDocument 502 /error/502.html ErrorDocument 503 /error/503.html <Directory /var/www/invoice-indowebcity.simura.id/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> <Directory /var/www/clients/client1/web13/web> # Clear PHP settings of this website <FilesMatch ".+\.ph(p[345]?|t|tml)$"> SetHandler None </FilesMatch> Options +SymlinksIfOwnerMatch AllowOverride All Require all granted </Directory> # suexec enabled <IfModule mod_suexec.c> SuexecUserGroup web13 client1 </IfModule> <IfModule mod_fastcgi.c> <Directory /var/www/clients/client1/web13/cgi-bin> Require all granted </Directory> <Directory /var/www/invoice-indowebcity.simura.id/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> <Directory /var/www/clients/client1/web13/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler php-fcgi </If> </FilesMatch> </Directory> Action php-fcgi /php-fcgi virtual Alias /php-fcgi /var/www/clients/client1/web13/cgi-bin/php-fcgi-*-80-invoice-indowebcity.simura.id FastCgiExternalServer /var/www/clients/client1/web13/cgi-bin/php-fcgi-*-80-invoice-indowebcity.simura.id -idle-timeout 300 -socket /var/lib/php7.4-fpm/web13.sock -pass-header Authorization -pass-header Content-Type </IfModule> <IfModule mod_proxy_fcgi.c> #ProxyPassMatch ^/(.*\.php[345]?(/.*)?)$ unix:///var/lib/php7.4-fpm/web13.sock|fcgi://localhost//var/www/clients/client1/web13/web/$1 <Directory /var/www/clients/client1/web13/web> <FilesMatch "\.php[345]?$"> <If "-f '%{REQUEST_FILENAME}'"> SetHandler "proxy:unix:/var/lib/php7.4-fpm/web13.sock|fcgi://localhost" </If> </FilesMatch> </Directory> </IfModule> # add support for apache mpm_itk <IfModule mpm_itk_module> AssignUserId web13 client1 </IfModule> <IfModule mod_dav_fs.c> # Do not execute PHP files in webdav directory <Directory /var/www/clients/client1/web13/webdav> <ifModule mod_security2.c> SecRuleRemoveById 960015 SecRuleRemoveById 960032 </ifModule> <FilesMatch "\.ph(p3?|tml)$"> SetHandler None </FilesMatch> </Directory> DavLockDB /var/www/clients/client1/web13/tmp/DavLock # DO NOT REMOVE THE COMMENTS! # IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE! # WEBDAV BEGIN # WEBDAV END </IfModule> DocumentRoot "/var/www/clients/client1/web13/web/public" </VirtualHost>
I got this error: There is already a website or sub / aliasdomain with this domain name. Do i need to delete subdomain for demo first ?