Re: apache2 can not find the file

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks for the reply.

According to the following output, mod_rewrite is installed

root@webshub:/var/www/html# apachectl -M
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
Loaded Modules:
 core_module (static)
 so_module (static)
 watchdog_module (static)
 http_module (static)
 log_config_module (static)
 logio_module (static)
 version_module (static)
 unixd_module (static)
 access_compat_module (shared)
 alias_module (shared)
 auth_basic_module (shared)
 authn_core_module (shared)
 authn_file_module (shared)
 authz_core_module (shared)
 authz_host_module (shared)
 authz_user_module (shared)
 autoindex_module (shared)
 deflate_module (shared)
 dir_module (shared)
 env_module (shared)
 filter_module (shared)
 mime_module (shared)
 mpm_prefork_module (shared)
 negotiation_module (shared)
 php7_module (shared)
 reqtimeout_module (shared)
 rewrite_module (shared)
 setenvif_module (shared)
 status_module (shared)
root@webshub:/var/www/html# vim .htaccess
root@webshub:/var/www/html# cat .htaccess
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . index.php [L]
root@webshub:/var/www/html# service apache2 restart




Then on my laptop, I can access the web installer without any error


mahmood@orca:~$ wget http://w.x.y.z
--2018-06-03 23:27:41--  http://w.x.y.z/
Connecting to w.x.y.z:80... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: http://w.x.y.z/install [following]
--2018-06-03 23:27:41--  http://w.x.y.z/install
Reusing existing connection to 5.57.36.104:80.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: http://w.x.y.z/install/rules [following]
--2018-06-03 23:27:41--  http://w.x.y.z/install/rules
Reusing existing connection to w.x.y.z:80.
HTTP request sent, awaiting response... 200 OK
Length: 6952 (6.8K) [text/html]
Saving to: ‘index.html’

index.html               100%[==================================>]   6.79K  --.-KB/s    in 0.006s  

2018-06-03 23:27:41 (1.07 MB/s) - ‘index.html’ saved [6952/6952]





The app documents doesn't say anything about htaccess. I have to say that on a web server which is working for some years, I was able to see the web installer and I didn't create any .htaccess file. I don't know but maybe the web server admins had installed some other things before and the results was that I was able to see the installer.


Now, I am working on a fresh ubuntu 1804. So, surely some configs are missing. Though .htaccess is the solution, but I would like to know if there is any NON .htaccess solution either.




Regards,
Mahmood




On Sunday, June 3, 2018, 11:20:44 PM GMT+4:30, Riemer Palstra <riemer@xxxxxxxxxxx> wrote:


Hi Mahmood,

Looking at the list of files and the URL that’s being searched for, there isn’t any “install" file or directory present. Probably your webapplication is trying to access that URL but you’re missing some kind of Redirect rules to handle URL’s through the index.php?

Hopefully you’ll find it it the app’s documentation, but it might be something as simple as:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . index.php [L]

Depending on your configuration, this could be in your config file, or in a .htaccess file and make sure that mod_rewrite is available.

--
Riemer Palstra
riemer@xxxxxxxxxxx


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux