Posts: 76
tremeur53
Joined: 29 Sep 2016
#16
@Dave
It do not works
and I have an error in the lines when I restart the PC...

Folder Web => ok
I replaced

Code: Select all

DocumentRoot /var/www/html/
        <Directory /var/www/html/>
with

Code: Select all

ServerAdmin webmaster@localhost  => [i]this line was already in the file[/i]
    DocumentRoot /home/dan/Web
        <Directory /home/dan/Web>
I created /Web/test (folder)
I created an index.php in test

Code: Select all

<?php
echo 'Hello world';
?>
localhost/Web/test/index.php => nothing (404)

localhost/test.index/php => nothing (404)

What' about ?
Last edited by tremeur53 on 08 Oct 2016, 10:53, edited 1 time in total.
Posts: 76
tremeur53
Joined: 29 Sep 2016
#17
I tried

Code: Select all

# ServerAdmin webmaster@localhost  
   DocumentRoot /home/dan/Web
        <Directory /home/dan/Web>
It does not work
I restarted apache
Posts: 1,062
Dave
Joined: 20 Jan 2010
#18
Ls -l /home/dan/Web?

Cat /var/log/apache/apache-error.log?
Posts: 76
tremeur53
Joined: 29 Sep 2016
#19
Your commands dont work ?

Code: Select all

root@antix1:/home/dan# Ls -l /home/dan/Web?
bash: Ls : commande introuvable
root@antix1:/home/dan# Cat /var/log/apache/apache-error.log?
bash: Cat : commande introuvable
root@antix1:/home/dan# 
While starting the computer I can see => start apache FAILED
Yesterday it worked.
Posts: 1,062
Dave
Joined: 20 Jan 2010
#20
Sorry.
Ls = ls
Cat = cat

I think apache2 does not start because the directory is missing.
Would like to see... so cat is to read the log file
Posts: 76
tremeur53
Joined: 29 Sep 2016
#21

Code: Select all

dan@antix1:~
$ ls -l /home/dan/Web?
ls: impossible d'accéder à /home/dan/Web?: Aucun fichier ou dossier de ce type
dan@antix1:~
$ 
dan@antix1:~
$ cat /var/log/apache/apache-error.log?
cat: /var/log/apache/apache-error.log?: Aucun fichier ou dossier de ce type
dan@antix1:~
$ 
Translation : No files or folders of this type for the 2 commands !

What ? dan/Web/ really exists !

It's not important.
I do not really need to use PHP on my laptop.
If it's too difficult...

But How to uninstal the package ??
I do not like the error messages while starting the computer !
It's apache2
I tried

Code: Select all

ls var/log/apache2
No files or folders of this type ! !
Posts: 76
tremeur53
Joined: 29 Sep 2016
#22
It is the folder home/dan/
Web is there !
Posts: 1,062
Dave
Joined: 20 Jan 2010
#23
I wish I could write french! I only know how to read / listen a little, you are much farther in english than I am in French.
I am making exact instructions on the computer now. It is very easy to do.

I see now I gave the wrong name for apache error log
try: cat /var/log/apache2/error.log
Posts: 76
tremeur53
Joined: 29 Sep 2016
#24

Code: Select all

root@antix1:/home/dan# cat /var/log/apache2/error.log
[Thu Oct 06 20:43:22.528984 2016] [mpm_event:notice] [pid 8285:tid 3074967360] AH00489: Apache/2.4.10 (Debian) configured -- resuming normal operations
[Thu Oct 06 20:43:22.529212 2016] [core:notice] [pid 8285:tid 3074967360] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 06 20:43:56.232447 2016] [mpm_event:notice] [pid 8285:tid 3074967360] AH00491: caught SIGTERM, shutting down
[Thu Oct 06 20:43:57.622540 2016] [mpm_prefork:notice] [pid 10348] AH00163: Apache/2.4.10 (Debian) configured -- resuming normal operations
[Thu Oct 06 20:43:57.623749 2016] [core:notice] [pid 10348] AH00094: Command line: '/usr/sbin/apache2'

root@antix1:/home/dan# 
For me it's CHINESE language ! ! ! __{{emoticon}}__ __{{emoticon}}__

May be I restore the apache config like it was, and you give me a command to transform www/html with r-w rights ??? With a right clic it's not possible
Posts: 1,062
Dave
Joined: 20 Jan 2010
#25
type: service apache2 status
type: cat /etc/apache2/sites-enabled/000-default

I think it says
start @ 11:59
using command /usr/sbin/apache2 @ 11:59
not familiar with errors from 12:00 - 12:19
told to shutdown 12:20


Other:
as root: apt-get -f install bluefish
to install bluefish
Posts: 1,062
Dave
Joined: 20 Jan 2010
#26
instructions from new install.

open terminal
type: mkdir /home/dan/Web
type: su root
type: ROOT PASSWORD
type: apt-get -f install apache2 php5 mysql-server
type: leafpad /etc/apache2/site-enabled/000-default
Old:

Code: Select all

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /var/www/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
    </Directory>

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory"/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Change to:

Code: Select all

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /home/dan/Web
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /home/dan/Web>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
    </Directory>

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory"/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
save and close:
type: service apache2 restart
type: exit
type: leafpad /home/dan/Web/index.html
Write:

Code: Select all

<html>
<body>
This is a test page
</body>
</html>
save and close:
type: exit
open web browser.
type:
========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"http://localhost"
linktext was:"http://localhost"
====================================


Does it work?
Posts: 76
tremeur53
Joined: 29 Sep 2016
#27
Problem ! !
The forum says FORBIDDEN
You do not have permission access posting.php

With the small PC
Posts: 1,062
Dave
Joined: 20 Jan 2010
#28
OK. Bug in the forum.
It is because of /etc
type a space between / and etc
or type like:

Code: Select all

[i]/[/i]etc
Posts: 76
tremeur53
Joined: 29 Sep 2016
#29
NO the error when I try to post a response !
Whith My big PC (Windows 7) it's works.

I try to restart the small one ?
Posts: 76
tremeur53
Joined: 29 Sep 2016
#30
I have restarted !
I try ....

Ok it seems working....