undefined function mail()ってなんだ?

PHP

16:58:21, by dozo Email , 60 words, 4003 views   Japanese (JP) del.icio.us

???

(ノ・・)ン。。。。。。(((●コロコロッ


譲り受けたシステム移行作業。
作業自体は全く問題なしに進み。
ふーやれやれ。

そんな矢先、さくっとトラブル発生。


メールが送れないんですけど・・・



いや・いやいや。。。何を仰いますやら。
そんなわけないでしょ。
システム内部を見ても単にmail関数に渡しているだけ。
これで動かないって事はまずない。
パラメータの引き渡され具合をチェックすると、
全く問題ない。

これでメールが送れないなんてことは・・・アレ?

[More:]


ほんとに届かない。
いったい何だこれは。。。
特別エラーメッセージも出たわけでもないのに。

ただ、本番環境なのでdisplay_errorsでエラーが抹消されているのかもしれない。
試しに、メールを送信するだけの単純なプログラムを書いてみて、
Apacheログを確認。


実行!(・ω・`)

PHP Fatal error: Call to undefined function mail() in /home/hoge/sendmail.php on line 6



・・・ハイ?(゜Д゜;)

mail関数がないってどういうこと?
そんなことが発生するのですか?
mail関数ってコンパイルから外すことすら出来ないはずなのに。


...?^^);・・)?ロ_ロ)?

ちょっと検索してみよう。


エラー文で検索したところ、
結構な数の結果が出てきた。
解答はまちまちで一つ一つ試すしかないかもと思っていたが、

Hello,

That means /usr/sbin/sendmail didn't exist at the time of the php compile.

1) make sure exim is installed (and /usr/sbin/sendmail exists)
2) recompile php:


アァ。。。(´・ω・`)

そういえば、標準で入っているqmailを抹殺し、
postfixをrpmで突っ込んだら、
sendmailパスが/usr/sbin/sendmail.postfixになった。
単純にsendmail_pathを設定すればいいのだと思っていたが、
コンパイルの段階で存在しないとダメなのね。
sendmail_pathパラメータ意味なし。



シンボリックリンクを張り直してリコンパイルしてみる。


(・∀・)ナオッタ!!

Trackback address for this post:

http://hain.jp/htsrv/trackback.php/139

Comments, Trackbacks:

No Comments/Trackbacks for this post yet...

Leave a comment:

Your email address will not be displayed on this site.
Your URL will be displayed.

Allowed XHTML tags: <p, ul, ol, li, dl, dt, dd, address, blockquote, ins, del, span, bdo, br, em, strong, dfn, code, samp, kdb, var, cite, abbr, acronym, q, sub, sup, tt, i, b, big, small>
(Line breaks become <br />)
(Set cookies for name, email and url)
(Allow users to contact you through a message form (your email will NOT be displayed.))
This is a captcha-picture. It is used to prevent mass-access by robots.

Please enter the characters from the image above. (case insensitive)

powered by b2evolution

shinobi

Neighbors
Relative
Favorites
PR

極論istの技術屋を始めて早幾年。 流れの速い業界の波にもまれながらも精一杯生きている様をとくとごらんあれ。

Archives
スポンサー

Latest bookmark
Search

Categories

Who's Online?
Misc
Syndicate this blog XML

Valid XHTML 1.0! Valid CSS! Valid RSS 2.0! Valid Atom 1.0!