apache2 mysqld php5 på ubuntu 14.04 Emnet er løst

Få hjælp og support til alt server-relateret. Guides og How-to's i forbindelse med servere hører også til her.
Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 28. apr 2014, 20:38

Hej jeg har brug for nogle eksperter til opsætning af php5 i ubuntu 14.03
jeg er ved at installere noget der heder Stalker portal

er komme så langt at jeg skal lave dette

PHP
Set in the /etc/php5/apache2/php.ini

Kode: Vælg alt

short_open_tag = On


men i den ny udgave er den ikke nogle /etc/php5/apache2/php.ini

Apache

Enable mod_rewrite:
Make sure that the package libapache2-mod-php5filter is not installed on the system. If necessary, remove it.

Kode: Vælg alt

sudo a2enmod rewrite


Set next to the host configuration which is responsible for the portal:

Kode: Vælg alt

Options -Indexes -MultiViews
AllowOverride All



Set in the /etc/apache2/ports.conf:

Kode: Vælg alt

NameVirtualHost *:88
Listen 88



In the /etc/apache2/sites-enabled/default.conf

<VirtualHost *:80> change to <VirtualHost *:88>

Restart apache:

da ingen a filere ser ud som de plejer
så jeg aner faktisk ikke hvad jeg gør ?

så jeg håber at der er nogen den vil forbarme sig over mig og hjælpe mig step by step
Tak
Mvh Martin

Klaus Rasmussen
Admin
Indlæg: 5518
Tilmeldt: 26. apr 2010, 02:40
IRC nickname: ClaudiuS
Geografisk sted: Nyborg [fyn]

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Klaus Rasmussen » 28. apr 2014, 20:44

Hej jeg er overbevist om at der er nogen her der nok skal hjælpe dig med det. Jeg flytter dog lige tråden til: Server: Guides, installation og opsætning.
Med Venlig Hilsen
Klaus

Kører Ubuntu 22.04 på ASUS All-Series, og Probook 4520s.
Gratis Ubuntumagasin: http://fullcirclemagazine.org/
https://mega.nz/folder/aJsmCYKa#dxMHKTi4Idmz6hiVpsI68Q

AJenbo
Admin
Indlæg: 20860
Tilmeldt: 15. nov 2009, 15:04
IRC nickname: AJenbo
Geografisk sted: Vanløse, København

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf AJenbo » 28. apr 2014, 21:00

Sørg for at libapache2-mod-php5 er installeret

/etc/php5/apache2/php.ini linje 226:
short_open_tag = On

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 28. apr 2014, 22:34

AJenbo skrev:Sørg for at libapache2-mod-php5 er installeret

/etc/php5/apache2/php.ini linje 226:
short_open_tag = On


takker var elles 100 på at jeg hade den inde
geninstallere den og så var den der ;)

så er det bare det sidste :(
her er den guide jeg bruge
http://wiki.infomir.eu/doku.php/en:stalker:install_and_configure

AJenbo
Admin
Indlæg: 20860
Tilmeldt: 15. nov 2009, 15:04
IRC nickname: AJenbo
Geografisk sted: Vanløse, København

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf AJenbo » 28. apr 2014, 22:54

Ok, hvor går du så i stå nu?

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 29. apr 2014, 06:35

AJenbo skrev:Ok, hvor går du så i stå nu?

Set next to the host configuration which is responsible for the portal:


Options -Indexes -MultiViews
AllowOverride All

Brugeravatar
NickyThomassen
Admin
Indlæg: 3650
Tilmeldt: 5. mar 2010, 19:58
IRC nickname: nicky
Geografisk sted: 192.168.20.42

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf NickyThomassen » 29. apr 2014, 07:49

"host configuration" er de filer der ligger i /etc/apache2/sites-enabled/*, og det er sikkert i /etc/apache2/sites-enabled/000-default du skal tilføje de 2 linier (eller sikre at de er der).

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 29. apr 2014, 12:19

NickyThomassen skrev:"host configuration" er de filer der ligger i /etc/apache2/sites-enabled/*, og det er sikkert i /etc/apache2/sites-enabled/000-default du skal tilføje de 2 linier (eller sikre at de er der).


* Restarting web server apache2 [fail]
* The apache2 configtest failed.
Output of config test was:
apache2: Syntax error on line 219 of /etc/apache2/apache2.conf: Syntax error on line 32 of /etc/apache2/sites-enabled/000-default.conf: Expected </Directory> but saw </VirtualHost>
Action 'configtest' failed.
The Apache error log may have more information.

Kode: Vælg alt

<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 /var/www/stalker

        # 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
Options -Indexes -MultiViews
AllowOverride All
<Directory>
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet


log file

Kode: Vælg alt

[Mon Apr 28 22:34:46.522863 2014] [:error] [pid 25440] [client 192.168.1.233:60701] PHP Parse error:  syntax error, unexpected end of file in /var/www/stalker/server/lib/func.php on line 405
[Mon Apr 28 22:35:32.041109 2014] [mpm_prefork:notice] [pid 25434] AH00169: caught SIGTERM, shutting down

AJenbo
Admin
Indlæg: 20860
Tilmeldt: 15. nov 2009, 15:04
IRC nickname: AJenbo
Geografisk sted: Vanløse, København

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf AJenbo » 29. apr 2014, 12:43

Du glemmer at afslutte <Directory> og du speceficere heller ikke en mappe for den

Kode: Vælg alt

<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 /var/www/stalker

        # 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
        <Directory "/var/www/stalker">
                Options -Indexes -MultiViews
                AllowOverride All
        </Directory>
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 29. apr 2014, 18:53

hmmm
Har nu geneinstalleret maskinen, så jeg kunne starte på en frisk, men stadig problemer
Når jeg vil logge på serveren med http://server_ip
fulfører den med http://server_ip/server/administrator/index.php
og jeg for denne skrivelse på siden

Parse error: syntax error, unexpected end of file in /var/www/stalker/server/lib/func.php on line 405

har gjort følgende

istalleret

Kode: Vælg alt

apache2
    nginx
    memcached
    mysql-server
    php5
    php-soap *
    php5-intl *
    php-gettext *
    php5-memcache *
    php-pear
    php5-curl *
    php5-mysql *
    php5-tidy *
    php5-imagick *
    php5-geoip *
   libapache2-mod-php5


Kode: Vælg alt

sudo pear channel-discover pear.phing.info
sudo pear install phing/phing

sudo apt-get install git
git clone https://github.com/azhurb/stalker_portal.git
cp -a stalker_portal* /var/www/stalker

cd /var/www/stalker/deploy
sudo phing

min php.ini
sudo sed -i "s/short_open_tags = .*/short_open_tags = On/" /etc/php5/apache2/php.ini

/etc/apache2/sites-enabled/

Kode: Vælg alt

<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 /var/www/stalker

   # 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
        <Directory "/var/www/stalker/">
                Options -Indexes -MultiViews
                AllowOverride All
        </Directory>
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

AJenbo
Admin
Indlæg: 20860
Tilmeldt: 15. nov 2009, 15:04
IRC nickname: AJenbo
Geografisk sted: Vanløse, København

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf AJenbo » 29. apr 2014, 19:52

apache2 og nginx udelukkere mere eller mindre hin anden. Jeg har kun set referencer til opsætningen af apache2 så måske du skulle fjerne nginx.

Den fejl du får er så vidt jeg kan se pga. at programmet du prøver at køre er skrevet med korte start tags (ikke just et tegn på kvalitet), det var det du prøved at kativere undersøttelsen af i starten ved at aktivere "short_open_tag = On", det kan dog være du ikke brugere apache2 pga. du også har installere nginx og det ikke er aktivere der.

Edit: Kan se du forsøger at aktivere short tags igen med sed i dit seneste indlæg.

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf Mr Cool Span » 29. apr 2014, 19:55

AJenbo skrev:apache2 og nginx udelukkere mere eller mindre hin anden. Jeg har kun set referencer til opsætningen af apache2 så måske du skulle fjerne nginx.

Den fejl du får er så vidt jeg kan se pga. at programmet du prøver at køre er skrevet med korte start tags (ikke just et tegn på kvalitet), det var det du prøved at kativere undersøttelsen af i starten ved at aktivere "short_open_tag = On", det kan dog være du ikke brugere apache2 pga. du også har installere nginx og det ikke er aktivere der.

Edit: Kan se du forsøger at aktivere short tags igen med sed i dit seneste indlæg.


har afinstalleret nginx

og har prøvet at aktivere short tags igen med sed
genstartet pc
men for stadig Parse error: syntax error, unexpected end of file in /var/www/stalker/server/lib/func.php on line 405

har en lille maskine her ved siden af mig som kære med debian og der virker det fint.
Senest rettet af Mr Cool Span 29. apr 2014, 20:19, rettet i alt 1 gang.

AJenbo
Admin
Indlæg: 20860
Tilmeldt: 15. nov 2009, 15:04
IRC nickname: AJenbo
Geografisk sted: Vanløse, København

Re: apache2 mysqld php5 på ubuntu 14.04

Indlægaf AJenbo » 29. apr 2014, 20:18

Kode: Vælg alt

sudo nano +212 /etc/php5/apache2/php.ini

Mr Cool Span
Indlæg: 26
Tilmeldt: 10. nov 2008, 15:59
Geografisk sted: Hirtshals

Re: apache2 mysqld php5 på ubuntu 14.04  Emnet er løst

Indlægaf Mr Cool Span » 29. apr 2014, 20:22

AJenbo skrev:

Kode: Vælg alt

sudo nano +212 /etc/php5/apache2/php.ini



du er ginial, der stod den som off satte den til on og genstarte og nu virker det
Hurra 1000 tak alle

Tilbage til "Server: Guides, installation og opsætning"

Hvem er online

Brugere der læser dette forum: [Bot] og 0 gæster