PDA

Bekijk Volledige Versie : Probleem met installeren van soap (php-soap)



jopiet
13/09/10, 21:42
Sinds enige tijd heb ik mijn website draaien op een VPS en sinds dien krijg ik de volgende foutmelding op een bepaalde pagina:
Fatal error: Class 'SoapClient' not found

Ik vermoed zelf dat soap niet geinstalleerd is, dus na wat googlen eea gevonden.

Volgens mij moet ik php-soap package installeren maar die is nergens te vinden.


yum search soap
levert op:


axis.i386 : A SOAP implementation in Java
libsoup.i386 : Soup, an HTTP library implementation


Maar volgens mij moet ik beide niet hebben en moet ik toch echt php-soap.i386 installeren.

Nu 'gebruikt' yum de fastestmirror-plugin, nu heb ik wat gevogeld zodat hij wel zoekt op andere mirrors (door steeds de mirror waar hij het packag niet vond toe te voegen in een file zodat hij die niet meer gebruikte).
Maar nergens is het 'php-soap' package gevonden.

Moet ik deze nu handmatig ergens downloaden en installeren?
Ik hoop dat jullie mij kunnen helpen...

p.s. ik ben echt een newbie maar ben zeker niet vies van google-n dus als je wat trefwoorden geeft dan kom ik er vast wel uit :-)
Uiteraard is een a-z tutorial wel hartelijk welkom ;-)

phreak
13/09/10, 21:51
Je kunt soap ook niet installen via pear?

jopiet
13/09/10, 22:01
Dat begrijp ik niet helemaal, misschien moest ik nog vermelden dat CentOS draait...

jopiet
13/09/10, 22:06
ow wacht

pear install SOAP
levert op:

Failed to download pear/SOAP within preferred state "stable", latest release is version 0.12.0, stability "beta", use "channel://pear.php.net/SOAP-0.12.0" to install
install failed

Blijkbaar dus een andere channel gebruiken... als iemand weet hoe (ondertussen google ik verder :-) )

jopiet
13/09/10, 22:15
met:

pear install channel://pear.php.net/SOAP-0.12.0
is hij nu geinstalleerd


..
<knip>
..
install ok: channel://pear.php.net/SOAP-0.12.0

Maar het werkt nog niet, vergeet ik nog iets?

Yourwebhoster
13/09/10, 22:30
Heb je DirectAdmin geïnstalleerd? DirectAdmin heeft namelijk de mogelijkheid om PHP te updaten met yum uitgeschakeld. Omdat de PHP versie uit de yum repo achterloopt moet je zelf de PHP SOAP compilen (zie bijvb Enable Soap - DirectAdmin Forums).

ilnee
13/09/10, 22:30
Apache al herstart?

jopiet
13/09/10, 22:37
Zojuist gedaan met:

service httpd restart

Krijg nog steeds de melding:

Class 'SoapClient' not found

en DirectAdmin is geinstalleerd, dus ik zal daar nog even induiken

Yourwebhoster
13/09/10, 22:41
Zojuist gedaan met:

service httpd restart

Krijg nog steeds de melding:

Class 'SoapClient' not found

en DirectAdmin is geinstalleerd, dus ik zal daar nog even induiken

Om die reden werkt het dus niet. Als je PHP compiled met --enable-soap in custombuild dan heb je een werkende soap extentie.

Succes verder, het compilen is niet zoveel werk dus je zou zo klaar moeten zijn.

jopiet
13/09/10, 22:47
Hij is nu aan het hercimpileren met --enable-soap...
Ik laat het zo weten of het werkt

jopiet
13/09/10, 22:52
Ok, het werkt.
Bedankt!

daveww
13/09/10, 22:57
Als je PHP compiled met --enable-soap in custombuild dan heb je een werkende soap extentie.Let ook even op dat je deze regel toevoegd in
/usr/local/directadmin/custombuild/custom/ap2/configure.php5i.p.v.
/usr/local/directadmin/custombuild/configure/ap2/configure.php5Dit omdat als je nu nieuwe data binnenhaalt of updates van custombuild de file overschreven wordt

Robert Esseveld
18/09/10, 12:19
Voor de mensen die SOAP ook niet geinstalleerd krijgen hier een kleine howto:
Dit is voor Centos i.c.m. DirectAdmin

Ga naar /usr/local/directadmin/custombuild/configure/ap2/

cd /usr/local/directadmin/custombuild/configure/ap2/
Open php configuratie bestand

nano configure.php5
Voeg voor --enable-mbstring toe:

--enable-soap \
Ga naar custombuild van DirectAdmin

cd /usr/local/directadmin/custombuild
Build php opnieuw

./build php n
check je phpinfo bestand of SOAP erbij staat

Geert-Jan
18/09/10, 17:08
Voor de mensen die SOAP ook niet geinstalleerd krijgen hier een kleine howto:


Leuk, maar alleen geldig voor een enter/enter installatie. Met een custom build of gebruik van php in cgi modus gaat het hele verhaal bij stap 1 al mis.

Jammer dat je er dat niet bij verteld, gezien het hoge ctrl-c / ctrl-v gehalte van veel mensen.

Robert Esseveld
18/09/10, 21:49
:oops:Inderdaad, had ik er even bij moeten vermelden.

Met een custom build of gebruik van php in cgi modus gaat het hele verhaal bij stap 1 al mis.
Maar mensen met een hoog ctrl-c / ctrl-v gehalte zullen dat ook vaak niet hebben ;)

dave cooper
24/10/10, 15:26
Hallo,

Weet iemand hoe ik soap kan activeren?
ik krijg de volgende error bij het uitvoeren van: ./build.php n

.

eerst:

yum search soap

Result:
axis.i386 : A SOAP implementation in Java
libsoup.i386 : Soup, an HTTP library implementation

dan:

pear install SOAP

Result:

pear/SOAP is already installed and is the same as the released version 0.12.0
install failed

Then i added --enable-soap\ in:
/usr/local/directadmin/custombuild/custom/ap2/configure.php5

When i run ./build php n

deze error komt er dan:

updating cache ./config.cache
creating ./config.status
creating php5.spec
creating main/build-defs.h
creating scripts/phpize
creating scripts/man1/phpize.1
creating scripts/php-config
creating scripts/man1/php-config.1
creating sapi/cli/php.1
creating main/php_config.h
creating main/internal_functions.c
creating main/internal_functions_cli.c
+--------------------------------------------------------------------+
| *** WARNING *** |
| |
| You will be compiling the CGI version of PHP without any |
| redirection checking. By putting this cgi binary somewhere in |
| your web space, users may be able to circumvent existing .htaccess |
| security by loading files directly through the parser. See |
| http://www.php.net/manual/security.php for more details. |
+--------------------------------------------------------------------+
| License: |
| This software is subject to the PHP License, available in this |
| distribution in the file LICENSE. By continuing this installation |
| process, you are bound by the terms of this license agreement. |
| If you do not agree with the terms of this license, you must abort |
| the installation process at this point. |
+--------------------------------------------------------------------+

Thank you for using PHP.

/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 3: --with-apxs2: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 4: --with-curl=/usr/local/lib: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 5: --with-gd: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 6: --enable-gd-native-ttf: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 7: --with-ttf: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 8: --with-gettext: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 9: --with-jpeg-dir=/usr/local/lib: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 10: --with-freetype-dir=/usr/local/lib: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 11: --with-kerberos: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 12: --with-openssl: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 13: --with-mcrypt: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 14: --with-mhash: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 15: --with-mysql=/usr: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 16: --with-mysqli=/usr/bin/mysql_config: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 17: --with-pcre-regex=/usr/local: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 18: --with-pdo-mysql=/usr: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 19: --with-pear: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 20: --with-png-dir=/usr/local/lib: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 21: --with-zlib: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 22: --with-zlib-dir=/usr/local/lib: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 23: --enable-zip: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 24: --with-iconv=/usr/local: No such file or directory
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 25: --enable-bcmath: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 26: --enable-calendar: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 27: --enable-ftp: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 28: --enable-magic-quotes: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 29: --enable-sockets: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 30: --enable-soap: command not found
/usr/local/directadmin/custombuild/custom/ap2/configure.php5: line 31: --enable-mbstring: command not found

*** There was an error while trying to configure php. Check the custom/ap2/configure.php5 file

Yourwebhoster
24/10/10, 15:28
PHP CGI heeft dit nodig "--enable soap \"

PHP cli heeft geen "" nodig. Ik denk dat je de cli versie over de CGI versie hebt heen geschreven, even met build de configs updaten of elke regel tussen "" plaatsen.

dave cooper
24/10/10, 15:35
Beste,

Bedankt voor je reactie.
Ik heb elke regel tussen "" gezet maar nog steeds dezelfde fout?

Nog andere ideeen?

Alvast bedankt.

#/bin/sh
./configure \
"--with-apxs2 \"
"--with-curl=/usr/local/lib \"
"--with-gd \"
"--enable-gd-native-ttf \"
"--with-ttf \"
"--with-gettext \"
"--with-jpeg-dir=/usr/local/lib \"
"--with-freetype-dir=/usr/local/lib \"
"--with-kerberos \"
"--with-openssl \"
"--with-mcrypt \"
"--with-mhash \"
"--with-mysql=/usr \"
"--with-mysqli=/usr/bin/mysql_config \"
"--with-pcre-regex=/usr/local \"
"--with-pdo-mysql=/usr \"
"--with-pear \"
"--with-png-dir=/usr/local/lib \"
"--with-zlib \"
"--with-zlib-dir=/usr/local/lib \"
"--enable-zip \"
"--with-iconv=/usr/local \"
"--enable-bcmath \"
"--enable-calendar \"
"--enable-ftp \"
"--enable-magic-quotes \"
"--enable-sockets \"
"--enable-soap \"
"--enable-mbstring "

Yourwebhoster
24/10/10, 15:38
Hi
sorry, mijn fout. Je bent bezig met PHP CGI builden blijkbaar terwijl configure.php5 voor PHP cli bedoeld is, je moet daarvoor in de config van suphp zijn.
Wat heb je allemaal gedaan? Met een normale build heb je dit namelijk niet. Ik zou je build even verversen, want dit ziet er niet goed uit.

T. Verhaeg
24/10/10, 15:38
Je kunt een



./build used_configs


gebruiken om te kijken welke config file gebruikt wordt. In deze file zet je dan de --enable-soap optie.

dave cooper
24/10/10, 15:42
Het enige wat ik gedaan heb staat boven.
dit is de gebruikte config deze heb ik ook aangepast

Graag hoor ik of je nog meer ideeen hebt.
dit is namelijk allemaal nieuw voor mij.

/usr/local/directadmin/custombuild/custom/ap2/configure.php5

Dat is ook waat die regel in staat.

Alvast bedankt.

Yourwebhoster
24/10/10, 15:44
En je hebt PHP op CGI ingesteld of cli?

dave cooper
24/10/10, 15:49
Sorry maar hoe zie ik dat?
Nogmaals ben nog niet zo bekend met linux

T. Verhaeg
24/10/10, 15:51
cat /usr/local/directadmin/custombuild/options.conf


Bovenin staat dan ergens php5_cgi = yes (of no) en php5_cli = yes (of no) Dat bepaalt hoe je PHP gecompileerd hebt.

dave cooper
24/10/10, 15:52
Staat op cli (php5)

Yourwebhoster
24/10/10, 15:58
Ik denk dat er wat mis is met je build aangezien hij de CGI versie probeert te compilen. Het beste kan je de custombuild even updaten/opnieuw installeren.
./build update

of zie Custombuild FAQ - DirectAdmin Forums voor meer over custombuild.

T. Verhaeg
24/10/10, 16:26
Probleem is fixed, er spookte een 'custom' directory die de boel in de war hielp, na het removen van deze, het builden van de used configs en het builden van php werkt alles, en staat soap vermeld als php module.

daveww
24/10/10, 17:31
Probleem is fixed, er spookte een 'custom' directory die de boel in de war hielp, na het removen van deze, het builden van de used configs en het builden van php werkt alles, en staat soap vermeld als php module.De custom moet er juist zijn, als je nu custombuild update zijn al je instellingen weer kwijt.

Daarvoor is de map 'custom', daarin defineer je je settings, bij elke update van custombuild blijft deze ongewijzigd. Je hoeft dan dus niet meer je rules terug te zetten maar kunt direct './build php n' o.i.d. doen.

Zie mijn eerdere post in dit topic ;)

T. Verhaeg
24/10/10, 19:44
De custom moet er juist zijn, als je nu custombuild update zijn al je instellingen weer kwijt.

Daarvoor is de map 'custom', daarin defineer je je settings, bij elke update van custombuild blijft deze ongewijzigd. Je hoeft dan dus niet meer je rules terug te zetten maar kunt direct './build php n' o.i.d. doen.

Zie mijn eerdere post in dit topic ;)

Klopt, maar als de custom directory ergens staat waar hij niet thuishoort (/usr/local/directadmin) in plaats van in de /usr/local/directadmin/custombuild directory en dan ook nog verkeerde info bevat (geen / bij de op 1-na-laatste option) dan ga je niet ver komen.

Vandaar ook mijn 'spookte', maar daar had iets meer info bij gekund.

daveww
24/10/10, 20:37
Klopt, maar als de custom directory ergens staat waar hij niet thuishoort (/usr/local/directadmin) in plaats van in de /usr/local/directadmin/custombuild directory en dan ook nog verkeerde info bevat (geen / bij de op 1-na-laatste option) dan ga je niet ver komen.

Vandaar ook mijn 'spookte', maar daar had iets meer info bij gekund.Lijkt me dan wel een 'bug' te noemen, zover ik weet heeft enkel custombuild optie voor 'custom'.

Waarom die het ook accepteerd als het in andere map staat vind ik wel vreemd.

T. Verhaeg
24/10/10, 20:39
Lijkt me dan wel een 'bug' te noemen, zover ik weet heeft enkel custombuild optie voor 'custom'.

Waarom die het ook accepteerd als het in andere map staat vind ik wel vreemd.

Keek er ook vreemd van op want normaal gesproken wordt dit ook geweigerd (verklaar wellicht de foutmeldingen?), maar anyhow, het werkt weer en SOAP staat erin.

dave cooper
25/10/10, 10:44
Allemaal erg bedankt en in het bijzonder T. Verhaeg die heeft het probleem opgelost.

Tom super bedankt!

Gr Dave