stop
Project:Support desk
MediaWiki 1.17wmf1
PHP 5.2.12 (apache)
MySQL 5.0.90-log
There is a problem with a temporary folder path resolving.
Php on server side sets this directive as following:
upload_tmp_dir = /home/XXXXX/hdlwiki.com/tmp
and
open_basedir = /home/XXXXX/
However Wiki ignores these directives and tries to use /var/tmp
which is out of the allowed path.
This warning I received during Wiki installation:
Warning: is_dir() [function.is-dir]: open_basedir restriction in effect.
File(/tmp) is not within the allowed path(s): (/home/XXXXX/) in /home/XXXXX/hdlwiki.com/www/config/Installer.php on line 474 Warning: Your session.save_path value (/tmp) appears to be invalid or is not writable.
PHP needs to be able to save data to this location for correct session operation.
As a result I cannot upload files by url. The system returns an error:
Warning: tempnam() [<a href='function.tempnam'>function.tempnam</a>]: open_basedir restriction in effect.
File(/var/tmp/) is not within the allowed path(s): (/home/XXXXX/)in/home/XXXXX/hdlwiki.com/www/includes/upload
/UploadFromUrl.php on line 101
What can be a solution for such problem.
Set the TMP (or TEMP or TMPDIR) environment variables for what you want your temp directory. (for the upload by url error)
For the install error, this can be caused if php is configured to store session files in the temp directory (sesssion.save_path in your php.ini). This should cause logins to not work at all, but perhaps only mediawiki is dissallowed, and php session handlers don't have the open_basedir restriction. If you get that warning when installing, but can still log in after the install is done, then the warning is in error, and is a bug in the installer (should probably file a bug about it).
Where should I set TMP variable? I have these in my LocalSettings.php
$wgEnableUploads = true; $wgAllowCopyUploads = true; $wgUploadPath = "{$wgScriptPath}/images"; $wgUploadDirectory = "{$IP}/images"; $wgTmpDirectory = "{$wgUploadDirectory}/temp"; $wgGroupPermissions['sysop']['upload_by_url'] = true;
and I still have the above mentioned error. The folders for uploads are all writable. The Special:Upload shows Could not create temporary file. in red.
putenv("TMP={$wgUploadDirectory}/temp");
UploadFromUrl appears to not support wgTmpDirectory, I believe this is a bug.
Really I'd consider it a bug in wfTempDir() function. Imports, and diffs (depending on config) are also affected.
Thank you! This solved the problem. Can it be fixed in the following MW release?
Dunno if the fix will make it into 1.17, but in 1.18 it most likely will.
I still see the problem in MediaWiki 1.41.1
- If you can edit webserver site, you need to configure PHP's sys_temp_dir (this is the server's variable MediaWiki uses!)
- If you can only edit CMS files, the only workaround is to add
$wgTmpDirectory = ini_get('upload_tmp_dir');
- to LocalSettings.php
Hi,
we are trying to add a sidebar dropdown to our wiki, but it doesn't work. We tried it by changing Common.js, Vector.css and the sidebar page, butr that didn't work.
Also, we wanted to follow the instructions in this thread, but the extensions wer not available anymore: Topic:Plrdnw4b2i0pxwmb
Can someoone please help a complete Noob?!
Hi, I upgraded my mediawiki from version 1.38 to version 1.39. The upgradation is successful.
I got the following error "The supplied credentials could not be authenticated." and no credential box (username and password box) show to me.
I updated the "wgPluggableAuth_Config" as directed and then I was able to see the username and password checkbox but the "keep me logged in" checkbox has on top of username
Can I get any advice on it?
i activate numbering of paragraphs in my user preferences. Then when displaying the page itself numbering is:
Sommaire 1 2 Welcome to MediaWiki.org help pages 2.1Reading 2.2Editing 2.3Advanced editing 2.4Collaboration 2.5Personal customization 2.6Wiki administration
Strange: There is nothing between level 1 and level 2 on first line and all is under level 2.
Then making modify source + preview with a forced TOC, all is under level 1:
Sommaire 1Welcome to MediaWiki.org help pages 1.1Reading 1.2Editing 1.3Advanced editing 1.4Collaboration 1.5Personal customization 1.6Wiki administration
Can someone analyse and correct the display ? Thanks. --Christian 🇫🇷 FR (talk) 09:04, 18 May 2024 (UTC)
What "page itself"? Please provide clear and full steps to reproduce something somewhere, including URLs.
it is written in the title, read the complete topic please. --Christian 🇫🇷 FR (talk) 08:39, 20 May 2024 (UTC)
This might have something to do with the change of the heading structure that is rolling out. Although I have proper spacing between the numbers and the titles. I suggest we wait a week or so more, before fixing this to allow changes to settle down.
thanks sometimes things appear strange to me, so I just warn. --Christian 🇫🇷 FR (talk) 10:18, 21 May 2024 (UTC)
In a similar way on page -> Help:Extension:Translate/Group_configuration/MediaWiki the numbering shows :
1 2 Configuration file
There is only a single level == so there is no need to see a 2 and the two numbers are on the same item. With a forced TOC the structure is correct :
Sommaire 1 Configuration file
--Christian 🇫🇷 FR (talk) 20:10, 28 May 2024 (UTC)
More awful -> Manual_talk:LocalisationCache.php the numbering of the topics is doubled at each step :
1 2 role of this page ? 3 4 ? as mentioned above
--Christian 🇫🇷 FR (talk) 21:28, 28 May 2024 (UTC)
I rather not have my IP-adress listed, but I forgot to log in. How can I attribute those edits to my account now? It's an IPv6 and the contributions were just a few hours ago so since I am on logged in through the same IPv6 it should be obvious that I am the same person.
Generally, you would request the administrators of the specific wiki to remove/suppress those contributions and you can make them again when logged in.
Thanks but would it not be possible for the administrator to change the user attribution on edits without destroying them?
Yes, see https://www.mediawiki.org/wiki/Manual:ReassignEdits.php. Keep in mind that it may not (always) reassign things like logs.
لقد وجدت ثغرة اختراق في موقعكم واريد التواصل معكم ل اخباركم عنها معلومات خاصة
Please see reporting security bugs.
How can I make reset in sqlzoo.net?
I made it before and I want to go through it again.
Deleting cookies doesn't work
@Dax123dax Hi, this is mediawiki.org. Why do you think that we know anything about other random websites like "sqlzoo.net"? Because we do not.
Mediawiki 1.39.6, PHP 7.4.3, MySQL 8.0.36
wfLoadExtension( 'MobileDetect' ); wfLoadExtension( 'MobileFrontend' ); wfLoadSkin( 'MinervaNeue' ); $wgMFDefaultSkinClass = 'SkinMinerva'; $wgDefaultMobileSkin = 'MinervaNeue'; $wgMinervaEnableSiteNotice = true; $wgMFAutodetectMobileView = true; $wgMFEditorOptions = array( 'anonymousEditing' => false, 'skipPreview' => false );
Till 1.35 we used to have MinervaNeue as mobile skin. With 1.39, this doesn't work anymore. Mobile devices apparently use the vector skin. What will i have to do to make the mobile skin work?
The mediawiki logfile is full of thousands of lines which don't say nothing to me, by filtering "mobile" i found one interesting line:
[resourceloader] Module "ext.MobileDetect.mobileonly" not loadable on target "mobile".
???
Do you have the correct versions of all your extensions? You need 1.39 version of Minerva and MobileFrontend etc.
I am quite sure. MobileDetect 2.2 (fc3a66e) 18:49, 11. Feb. 2024, MobileFrontend 2.4.0 (7dc20b0) 07:36, 4. Mär 2024, MinervaNeue – (d515f6a) 08:24, 29. Apr. 2024
These are the versions I get when using ExtensionDistributor and SkinDistributor using target "1.39"
In the desktop browser, skin MinervaNeue has got the look. After login, of course. On my mobile, the skin is s.th. like vector, whether I am logged in or not. This means even when I select MinervaNeue in my user preferences!
Certainly the problem is sitting here in front of my screen, but I've got no more ideas where to look.
How about $wgDefaultMobileSkin = 'minerva';
This answer is not helpful. In fact, may you be volunteers or not, this is exactly the kind of answer that makes me angry. This is exactly the kind of support that is superfluous. "Why do you want to use x, use y" is intolerable.
We used to have MinervaNeue as mobile skin for years and years. It used to work for years and years. Now with the upgrade it does not work anymore. You tell me I should use another skin. I am upset, i am outraged. If it does not work THEN DO NOT OFFER IT.
f***, te name of the skin is MinervaNeue but the value of the parameter is minerva. But, it has been working for years and years so obviously some sort of braniac must have changed it. Those kind of modifications are making me ill. Thanks for the conversation.
Hello! I recently messed up. A few days ago, I shut down my PC without stopping Apache or MySQL, which I have been running through XAMPP to use MediaWiki. I think this caused issues with MySQL, since when I tried running it again, it kept crashing and refusing to load any pages. I have since reinstalled XAMPP and copied over the MediaWiki and MySQL data folders, and MySQL is no longer crashing, however i am now getting the following error when trying to access my wiki:
MediaWiki internal error.
Original exception: [2e740f7107b90c8fdf67f407] /wiki/ Wikimedia\Rdbms\DBConnectionError: Cannot access the database: Access denied for user 'wikiuser'@'localhost' (using password: YES) (localhost)
Backtrace:
from C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(1149)
#0 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(805): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()
#1 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(793): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)
#2 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(99): Wikimedia\Rdbms\LoadBalancer->getConnectionInternal(integer, array, string, integer)
#3 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(117): Wikimedia\Rdbms\DBConnRef->ensureConnection()
#4 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(710): Wikimedia\Rdbms\DBConnRef->__call(string, array)
#5 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\Database.php(2760): Wikimedia\Rdbms\DBConnRef->getSessionLagStatus()
#6 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(526): Wikimedia\Rdbms\Database::getCacheSetOptions(Wikimedia\Rdbms\DBConnRef)
#7 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\objectcache\wancache\WANObjectCache.php(1725): MediaWiki\User\User->MediaWiki\User\{closure}(boolean, integer, array, NULL, array)
#8 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\objectcache\wancache\WANObjectCache.php(1556): WANObjectCache->fetchOrRegenerate(string, integer, Closure, array, array)
#9 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(522): WANObjectCache->getWithSetCallback(string, integer, Closure, array)
#10 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(480): MediaWiki\User\User->loadFromCache()
#11 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(412): MediaWiki\User\User->loadFromId(integer)
#12 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\UserInfo.php(92): MediaWiki\User\User->load()
#13 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\CookieSessionProvider.php(127): MediaWiki\Session\UserInfo::newFromId(string)
#14 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\SessionManager.php(538): MediaWiki\Session\CookieSessionProvider->provideSessionInfo(MediaWiki\Request\WebRequest)
#15 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\SessionManager.php(244): MediaWiki\Session\SessionManager->getSessionInfoForRequest(MediaWiki\Request\WebRequest)
#16 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\Request\WebRequest.php(840): MediaWiki\Session\SessionManager->getSessionForRequest(MediaWiki\Request\WebRequest)
#17 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\SessionManager.php(165): MediaWiki\Request\WebRequest->getSession()
#18 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\Setup.php(486): MediaWiki\Session\SessionManager::getGlobalSession()
#19 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\WebStart.php(92): require_once(string)
#20 C:\Users\Aven\Desktop\xampp\htdocs\wiki\index.php(44): require(string)
#21 {main}
Exception caught inside exception handler: [2e740f7107b90c8fdf67f407] /wiki/ Wikimedia\Rdbms\DBConnectionError: Cannot access the database: Access denied for user 'wikiuser'@'localhost' (using password: YES) (localhost)
Backtrace:
from C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(1149)
#0 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(805): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()
#1 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\loadbalancer\LoadBalancer.php(793): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)
#2 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(99): Wikimedia\Rdbms\LoadBalancer->getConnectionInternal(integer, array, string, integer)
#3 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(117): Wikimedia\Rdbms\DBConnRef->ensureConnection()
#4 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\DBConnRef.php(710): Wikimedia\Rdbms\DBConnRef->__call(string, array)
#5 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\rdbms\database\Database.php(2760): Wikimedia\Rdbms\DBConnRef->getSessionLagStatus()
#6 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(526): Wikimedia\Rdbms\Database::getCacheSetOptions(Wikimedia\Rdbms\DBConnRef)
#7 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\objectcache\wancache\WANObjectCache.php(1725): MediaWiki\User\User->MediaWiki\User\{closure}(boolean, integer, array, NULL, array)
#8 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\libs\objectcache\wancache\WANObjectCache.php(1556): WANObjectCache->fetchOrRegenerate(string, integer, Closure, array, array)
#9 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(522): WANObjectCache->getWithSetCallback(string, integer, Closure, array)
#10 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(480): MediaWiki\User\User->loadFromCache()
#11 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(412): MediaWiki\User\User->loadFromId(integer)
#12 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\UserInfo.php(92): MediaWiki\User\User->load()
#13 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\CookieSessionProvider.php(127): MediaWiki\Session\UserInfo::newFromId(string)
#14 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\SessionManager.php(538): MediaWiki\Session\CookieSessionProvider->provideSessionInfo(MediaWiki\Request\WebRequest)
#15 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\session\SessionManager.php(244): MediaWiki\Session\SessionManager->getSessionInfoForRequest(MediaWiki\Request\WebRequest)
#16 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\Request\WebRequest.php(840): MediaWiki\Session\SessionManager->getSessionForRequest(MediaWiki\Request\WebRequest)
#17 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(1024): MediaWiki\Request\WebRequest->getSession()
#18 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(393): MediaWiki\User\User->loadDefaults()
#19 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(1637): MediaWiki\User\User->load()
#20 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\User.php(2297): MediaWiki\User\User->getId()
#21 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\UserOptionsManager.php(656): MediaWiki\User\User->isRegistered()
#22 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\UserOptionsManager.php(500): MediaWiki\User\UserOptionsManager->getCacheKey(MediaWiki\User\User)
#23 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\user\UserOptionsManager.php(147): MediaWiki\User\UserOptionsManager->loadUserOptions(MediaWiki\User\User, integer)
#24 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\context\RequestContext.php(459): MediaWiki\User\UserOptionsManager->getOption(MediaWiki\User\User, string)
#25 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\language\Message.php(389): RequestContext->getLanguage()
#26 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\language\Message.php(1485): Message->getLanguage()
#27 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\language\Message.php(972): Message->fetchMessage()
#28 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\language\Message.php(1059): Message->format(string)
#29 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionRenderer.php(254): Message->text()
#30 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionRenderer.php(398): MWExceptionRenderer::msg(string, string)
#31 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionRenderer.php(103): MWExceptionRenderer::reportOutageHTML(Wikimedia\Rdbms\DBConnectionError)
#32 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionHandler.php(134): MWExceptionRenderer::output(Wikimedia\Rdbms\DBConnectionError, integer)
#33 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionHandler.php(251): MWExceptionHandler::report(Wikimedia\Rdbms\DBConnectionError)
#34 C:\Users\Aven\Desktop\xampp\htdocs\wiki\includes\exception\MWExceptionHandler.php(219): MWExceptionHandler::handleException(Wikimedia\Rdbms\DBConnectionError, string)
#35 [internal function]: MWExceptionHandler::handleUncaughtException(Wikimedia\Rdbms\DBConnectionError)
#36 {main}
Any help is appreciated, thank you! :)
Ah. Just discovered that the wiki SQL database is gone. Where can I go from here?
Looking in the folder mysql/data/data i have found that the folder for my wiki database is still there, however it isnt showing up on phpMyAdmin and it responded with "Unknown database 'wikidb'
" when i tried to access it using SQL.
Yes, that sounds like you deleted your database. Copying the files over is not the proper way to make a backup. Its not impossible to recover from this situation but its not straight forward. Try following the steps at https://community.spiceworks.com/t/recover-mysql-database-from-frm-and-ibd-files/1014394
For reference, for the original situation (too late now) - be sure to use innoDB and not myisam tables. Depending on the situation repair table might have been useful.