Topic on Project:Support desk

Jump to navigation Jump to search

E-mails Not Being Sent

2
Summary by Ciencia Al Poder
ZianFirstWatch (talkcontribs)

I configured $wgSMTP in LocalSettings.php with a set of credentials and IP addresses that worked in past versions of MediaWiki but now, with version 1.27.1, I get an HTTP 500 error when I try to generate a new password and an e-mail is not sent.

E-mail used to work with a PEAR folder in the wiki's root folder as described at http://syrkos.com/blog/2013/04/12/manual-install-of-pear-mail-in-mediawiki/

I read that version 1.27 no longer requires a separate PEAR install so I removed the folder and commented out $pearPath = .... and ini_set (step 8 in the linked article).

What can I do to fix the problem?

Log file excerpt:

Start request POST /wiki/Special:PasswordReset
HTTP HEADERS:
CONTENT-TYPE: application/x-www-form-urlencoded
CONTENT-LENGTH: 90
X-ORIGINAL-URL: /wiki/Special:PasswordReset
USER-AGENT: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; InfoPath.3)
REFERER: http://stoutwiki/wiki/Special:PasswordReset
HOST: stoutwiki
COOKIE: wikidb171UserName=Zchoy; wikidb171_session=vp5j01hnc1br5qrbetp7i8s5pug8lf7r
ACCEPT-LANGUAGE: en-US
ACCEPT-ENCODING: gzip, deflate
ACCEPT: image/gif, image/jpeg, image/pjpeg, application/x-ms-application, application/xaml+xml, application/x-ms-xbap, application/msword, application/vnd.ms-powerpoint, application/vnd.ms-excel, */*
CONNECTION: Keep-Alive
CACHE-CONTROL: no-cache
[caches] cluster: WinCacheBagOStuff, WAN: mediawiki-main-default, stash: db-replicated, message: WinCacheBagOStuff, parser: WinCacheBagOStuff, session: WinCacheBagOStuff
[caches] LocalisationCache: using store LCStoreCDB
[session] Session "vp5j01hnc1br5qrbetp7i8s5pug8lf7r" requested without UserID cookie
Unstubbing $wgParser on call of $wgParser::setHook from wfSimpleTable
Parser: using preprocessor: Preprocessor_DOM
IP: 192.168.2.186
Fully initialised
SpecialPage::getContext called and $mContext is null. Return RequestContext::getMain(); for sanity
[connect] Connected to database 0 at 127.0.0.1
[error] [2bf38f65217fb0f5e2e70bda] /wiki/Special:PasswordReset   ErrorException from line 58 of C:\wiki\wiki\includes\libs\objectcache\WinCacheBagOStuff.php: PHP Warning: wincache_ucache_cas() expects parameter 2 to be integer, string given
#0 [internal function]: MWExceptionHandler::handleError(integer, string, string, integer, array)
#1 C:\wiki\wiki\includes\libs\objectcache\WinCacheBagOStuff.php(58): wincache_ucache_cas(string, string, string)
#2 C:\wiki\wiki\includes\libs\objectcache\BagOStuff.php(305): WinCacheBagOStuff->cas(string, string, array, integer)
#3 C:\wiki\wiki\includes\libs\objectcache\WinCacheBagOStuff.php(72): BagOStuff->mergeViaCas(string, Closure, integer, integer)
#4 C:\wiki\wiki\includes\libs\objectcache\WANObjectCache.php(424): WinCacheBagOStuff->merge(string, Closure, integer, integer)
#5 C:\wiki\wiki\includes\cache\MessageCache.php(691): WANObjectCache->set(string, array, integer)
#6 C:\wiki\wiki\includes\cache\MessageCache.php(637): MessageCache->setValidationHash(string, array)
#7 C:\wiki\wiki\includes\cache\MessageCache.php(406): MessageCache->saveToCaches(array, string, string)
#8 C:\wiki\wiki\includes\cache\MessageCache.php(326): MessageCache->loadFromDBWithLock(string, array, NULL)
#9 C:\wiki\wiki\includes\cache\MessageCache.php(925): MessageCache->load(string)
#10 C:\wiki\wiki\includes\cache\MessageCache.php(857): MessageCache->getMsgFromNamespace(string, string)
#11 C:\wiki\wiki\includes\cache\MessageCache.php(827): MessageCache->getMessageForLang(Language, string, boolean, array)
#12 C:\wiki\wiki\includes\cache\MessageCache.php(767): MessageCache->getMessageFromFallbackChain(Language, string, boolean)
#13 C:\wiki\wiki\includes\Message.php(1178): MessageCache->get(string, boolean, Language)
#14 C:\wiki\wiki\includes\Message.php(801): Message->fetchMessage()
#15 C:\wiki\wiki\includes\Message.php(892): Message->toString()
#16 C:\wiki\wiki\includes\specialpage\SpecialPage.php(564): Message->text()
#17 C:\wiki\wiki\includes\specialpage\SpecialPage.php(445): SpecialPage->getDescription()
#18 C:\wiki\wiki\includes\specialpage\FormSpecialPage.php(148): SpecialPage->setHeaders()
#19 C:\wiki\wiki\includes\specialpage\SpecialPage.php(479): FormSpecialPage->execute(NULL)
#20 C:\wiki\wiki\includes\specialpage\SpecialPageFactory.php(576): SpecialPage->run(NULL)
#21 C:\wiki\wiki\includes\MediaWiki.php(282): SpecialPageFactory::executePath(Title, RequestContext)
#22 C:\wiki\wiki\includes\MediaWiki.php(745): MediaWiki->performRequest()
#23 C:\wiki\wiki\includes\MediaWiki.php(519): MediaWiki->main()
#24 C:\wiki\wiki\index.php(43): MediaWiki->run()
#25 {main}
[MessageCache] MessageCache::load: Loading en... local cache is empty, global cache is expired/volatile, loading from database
User::getBlockedStatus: checking...
Unstubbing $wgLang on call of $wgLang::_unstub from ParserOptions->__construct
User: got user 1 from cache
User::pingLimiter: adding record for mediawiki:limiter:mailpassword:ip:192.168.2.186 (limit 5 in 3600s)
MWCryptRand::realGenerate: Generating cryptographic random bytes for PasswordFactory::generateRandomPasswordString/MWCryptRand::generateHex/MWCryptRand->realGenerateHex/MWCryptRand::generate/MWCryptRand->realGenerate
MWCryptRand::realGenerate: mcrypt_create_iv generated 7 bytes of randomness.
MWCryptRand::realGenerate: 0 bytes of randomness leftover in the buffer.
User: got user 1 from cache
[authentication] Changing authentication data for Zchoy class MediaWiki\Auth\TemporaryPasswordAuthenticationRequest
MWCryptRand::realGenerate: Generating cryptographic random bytes for MediaWiki\Auth\TemporaryPasswordPrimaryAuthenticationProvider->providerChangeAuthenticationData/PasswordFactory->newFromPlaintext/Pbkdf2Password->crypt/MWCryptRand::generate/MWCryptRand->realGenerate
MWCryptRand::realGenerate: mcrypt_create_iv generated 16 bytes of randomness.
MWCryptRand::realGenerate: 0 bytes of randomness leftover in the buffer.
User: cache miss for user 1
User: loading options for user 1 from database.
[objectcache] Rejected set() for global:user:id:wikidb171:1 due to pending writes.
UserMailer::send: sending mail to zchoy@firstwatch.net
Sending mail via PEAR::Mail
Start request GET /wiki/Main_Page
Ciencia Al Poder (talkcontribs)

The exception shown is:

[error] [2bf38f65217fb0f5e2e70bda] /wiki/Special:PasswordReset ErrorException from line 58 of C:\wiki\wiki\includes\libs\objectcache\WinCacheBagOStuff.php: PHP Warning: wincache_ucache_cas() expects parameter 2 to be integer, string given

Sadly, this is reported but there have been no progress so far. See task T120896. The problem is with wincache, so as a workaround you'll need to remove $wgMainCacheType from your LocalSettings.php or install another caching system.

Reply to "E-mails Not Being Sent"