Pomoc - Szukaj - Użytkownicy - Kalendarz
Pełna wersja: Reinstalacja serwera i brak dostepu do mail()
Forum PHP.pl > Forum > Serwery WWW
scanner
Slackware 9
php 4.3.3
Apache 2
Qmail

Root przeinstalowal system, postawil nowe php i od tego momentu przestala dzialac funkcja mail().

Wykonalem to co znalazlem w komentarzach do mail(), czyli:
Cytat
jamie at trewtech dot com
16-Feb-2002 01:40  
This problem/fix should be here since it oddly takes a long time to find the answer on the internet, yet the problem seems common. If you get  

mail() not supported in this php build

when trying to use this function then you need to recompile. This happens during configure if /sbin/sendmail is not found. For some reason php decides to leave out mail support entirely if it can't find this file while configuring for build. If you run qmail or some other sendmail replacement it is very likely this could be your situation. To fix, make sure the appropriate file or symlink exists. To be safe, why not make a symlink from /usr/sbin/sendmail too.  In the case of qmail, these should both point to /var/qmail/bin/sendmail which is qmail's sendmail wrapper.  

After fixing that, delete config.cache and start your build over again and reinstall. Thanks to Surojit Niyogi -- and Google, for caching the page on the www.bajaar.com where he posted this simple solution which was unfortunately broken at the time I was looking for an answer.


1. Wylacz apache
2. skasuj config.cache
3. zrob symlinki (w usr/sbin) byl
4. ./configure --enable-track-vars --with-apxs2=/usr/apache/bin/apxs --enable-force-cgi-redirect --with-config-file-path=/usr/apache/conf --enable-safe-mode --with-openssl --enable-calendar --with-jpeg-dir --enable-ftp --with-ttf --with-t1lib --with-mysql --with-pgsql --with-gd --with-png-dir=/usr/local --with-zlib
5. make
6. make install
7. wystartuj apache

i nic..
Pomocy, bo mi katowiccy księża kurialni exkomunike zalatwia, hahah smile.gif)
adwol
I co, poradziłeś sobie od czasu naszej rozmowy na ircu?
Jeśli nie, to zobacz czy napewno configure znajduje Ci binarkę sendmaila:
Kod
checking for sendmail...

i jak nie to posprawdzaj dobrze linki czy masz /usr/sbin/sendmail lub /usr/lib/sendmail. Z tego co widziałem to jedynym warunkiem istnienia funkcji mail jest istnienie takiego pliku podczas kompilacji.
scanner
sprawdze jeszcze link /usr/lib/sendmail
Z rootem ustalilismy juz tez, ze sprawdzimy php 4.3.2 i 4.3.4 rcX.
Dam znac, jak poszlo smile.gif)

A na drugim serwerze z tym problemem bede stawial juz php5...
To jest wersja lo-fi głównej zawartości. Aby zobaczyć pełną wersję z większą zawartością, obrazkami i formatowaniem proszę kliknij tutaj.
Invision Power Board © 2001-2025 Invision Power Services, Inc.