Quantcast
Channel: Installing and upgrading help
Viewing all 46779 articles
Browse latest View live

Moodle 3.6.3 Database settings Error Code: 18456

$
0
0
by Michael Guizzetti.  

I'm running through the install process of Moodle 3.6.3 and am now stuck on the Database Settings page.  I'm getting the following error:


Error: Database connection failed

It is possible that the database is overloaded or otherwise not running properly.

The site administrator should also check that the database details have been correctly specified in config.php

SQLState: 28000
Error Code: 18456
Message: [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Login failed for user 'domain\user'.


I have two Windows 2016 servers one with IIS and the other with SQL 2016. 


IIS Server

I've installed the Microsoft ODBC Driver 17 for SQL Server and the SQL drivers in the C:\Program Files\PHP\v7.2\ext folder "php_sqlsrv_72_nts_x64.dll""php_pdo_sqlsrv_72_nts_x64.dll" and added the following to my php.ini:

[PHP_SQLSRV]

extension=php_pdo_sqlsrv_72_nts_x64.dll

extension=php_sqlsrv_72_nts_x64.dll


SQL server

I've created a DB  and enabled "SQL Server and Windows Authentication mode".  TCP/IP is also enabled.


I've run through as many forums as I can and the solutions are not working for my issue.  What am I missing?


Re: moodle migration

$
0
0
by Ken Task.  

First, I don't run Bitnami ... so my qualfications/experience in doing what you desire is nada.

But ... can google ... just sharing info and links you will have to use for your purpose.

Bitnami installed it's own AMP stack + Moodle.

Documentation for Moodle on moodle.org (or in community forums)
probably won't have much on Bitnami specifics.   So you, the bitnami user/admin
will have to figure out where it's installed and how to create backups
of code + data directory + get an sql dump of the current sites DB.

There is this for Bitnami
https://docs.bitnami.com/general/apps/moodle/administration/

And looks like:
Migrate your Moodle installation
https://docs.bitnami.com/general/apps/moodle/administration/migrate/

will be your starting point.

Key for you is to use the above to find locations of code, moodledata, and do the
SQL dump.

***Using Bitnami's Upgrade Moodle as a resource to locate files:***

https://docs.bitnami.com/general/apps/moodle/administration/upgrade/

moodle code: /opt/bitnami/apps/moodle/htdocs/

Inside moodle code, a config.php file that will show the full path
to the location of moodledata.

But you are not migrating on same server but to a different server.

So if one doesn't know how to transfer those backups from current server
to new server, then you'll have to download those backups and upload them
to new server.

Once on new server without Bitnami, that's now under your hosting system there.

Moodle docs might come back into play.

'SoS', Ken

Re: Moodle 3.6.3 Database settings Error Code: 18456

$
0
0
by Luis de Vasconcelos.  

You can't connect using a domain account (domain\user) - at least, I could never get it to work. So, create a database user in SQLServer and use that username and password to connect the Moodle installer to the MSSQL database.

But first check that PHPInfo() shows the SQLSRV section? If not, your PHP isn't configured correctly.

Re: Moodle 3.6.3 Database settings Error Code: 18456

$
0
0
by Michael Guizzetti.  

Thanks, the local account worked.

Getting rid of Installatron (upgrade to 3.6.3)

$
0
0
by W. Schouten.  

Dear Moodle-admin,

Some time ago, I've installed Moodle by using the Installatron-function (cpanel) of my provider. I was curious about Moodle and was happy about the 'automatic' updates. However, an upgrade to 3.6.2 caused problems which are fixed a couple months ago. So far so good.

The upgrade to 3.6.3 caused some challenges as I want to get rid of the Installatron-function. The steps, I've taken are as follow:

  • Created a backup of the public_html-folder (complete with data-folder)
  • Removed Moodle from Installatron
  • Manually created a database in cpanel with values from config.php
  • Followed the Installing Moodle-document (web-based installer) so the webserver includes version 3.6.3 with my data-folder of 3.6.2. (https://docs.moodle.org/36/en/Installing_Moodle)
  • I'm unable to trigger the installation as no connection to the database can't be made (enabled: '$CFG->debug = (E_ALL | E_STRICT);' and '$CFG->debugdisplay = 1;' in config.php

The problem is the password which I can't remember unfortunately. The salted one in config.php doesn't match the one in cpanel. I've changed config.php by adding '$CFG->includeuserpasswordsinbackups = true;' and changing '$CFG->dbpass    = '' with the plain database password of cpanel. However, without any success sad.

Which following step do you suggest. Help!


Re: moodle migration

$
0
0
by Ken Task.  

Since you've already installed a new instance on new server the path of least resistance for you might be to simply make full course backups of old site (the Bitnami) ... and restore them to new site.

Depends upon the number of courses ... but even if a fairly large number might still be easier than migrating entire site.

Up to you of course.

Comment: kinda the price one pays when looking for the proverbial 'easy button' when it comes to open source software.  Bitnami is easy to install (so I've heard), but when it comes to moodle, easy install is but tip of a large iceburg.  And thus, one is better informed admin wise if installing manually.

Just one additional consideration ... plugins ... addons.  If you used plugins/addons on old site, find compat versions and install them prior to restore of backups to new site.

Hopefully, you didn't go 'plugin nuts' (insert nut emoji here) cause one has the potential to be 'plugin sad' sad on new site.

'SoS', Ken


Comptia Exam Preparation - A Plus Essentials - 15 True and False Practice Questions

$
0
0
by Rosie Sitton.  

Comptia Exam Preparation - A Plus Essentials - 15 True and False Practice Questions 

After you examine your course books it is imperative to test your recently obtained information and see exactly how well you have assimilated the material. Practice tests... 

- Reinforce what you realized - fill in the holes of what you missed 

- Get you used to respond to inquiries to assemble certainty and commonality 

Here are 15 True/False tests inquiries for you to rehearse on: 

Q.1 - WEP is utilized to verify remote information transmissions. Genuine/False 

Q.2 - Changing the Boot Order in DOS enables you to change the drive the PC first searches for while booting. Genuine/False 

Q.3 - Overclocking alludes to running your processor at a higher speed than a maker suggests. Genuine/False 

Q.4 - The record trait 'r' speaks to a 're-established' document. Genuine/False 

Q.5 - SRAM is static and necessities steady invigorating. Genuine/False 

Q.6 - A 10BaseT link has a most extreme separation length of 100 meters. Genuine/False 

Q.7 - When all segments on the PC are killed, including the hard plate drive, CMOS, RAM, show and CPU to spare battery control, this is called hibernation. Genuine/False 

Q.8 - If you put in new programming on your framework and the framework starts to glitch, you can address this by 'moving back' the framework to a past reestablish point. Genuine/False 

Q.9 - If you erase a grind and hold down the move key while squeezing erase, the record will be erased and won't go into the reuse container. Genuine/False 

Q.10 - The document framework most normally experienced on a Linux framework is EXT2. Genuine/False 

Q.11 - ROM doesn't lose information when you turn the PC off. Genuine/False 

Q.12 - Bus Mastering enables a controller on the transport to converse with different gadgets without experiencing the CPU. Genuine/False 

Q.13 - A Firewall can be either programming or equipment. Genuine/False 

Q.14 - MSconfig holds the information before handling it. Genuine/False 

Q.15 - The memory type SO-DIMM would doubtlessly be utilized in a PC phone. Genuine/False 

CompTIA Exam Questions An or more Essentials Answers 

The inquiries alongside the appropriate responses are incorporated into this CompTIA test addresses prep for your better accommodation 

Q.1 - WEP is utilized to verify remote information transmissions. Genuine/False 

Genuine 

Q.2 - Changing the Boot Order in DOS enables you to change the drive the PC first searches for while booting. Genuine/False 

False. The Boot Order is changed in CMOS 

Q.3 - Overclocking alludes to running your processor at a higher speed than a maker suggests. Genuine/False 

Genuine 

Q.4 - The recording quality 'r' speaks to a 're-established' document. Genuine/False 

False. It speaks to a 'read-just' record. 

Q.5 - SRAM is static and necessities steady reviving. Genuine/False 

False. SRAM is static and shouldn't be continually invigorated. 

Q.6 - A 10BaseT link has a most extreme separation length of 100 meters. Genuine/False 

Genuine 

Q.7 - When all segments on the PC are killed, including the hard plate drive, CMOS, RAM, show, and CPU to spare battery control, this is called hibernation. Genuine/False 

Genuine 

Q.8 - If you put in new programming on your framework and the framework starts to breakdown, you can address this by 'moving back' the framework to a past reestablish point. Genuine/False 

Genuine 

Q.9 - If you erase a scrape and hold down the move key while squeezing erase, the document will be erased and won't go into the reuse container. Genuine/False 

Genuine 

Q.10 - The record framework most regularly experienced on a Linux framework is EXT2. Genuine/False 

Genuine 

Q.11 - ROM doesn't lose information when you turn the PC off. Genuine/False 

Genuine 

Q.12 - Bus Mastering enables a controller on the transport to converse with different gadgets without experiencing the CPU. Genuine/False 

Genuine 

Q.13 - A Firewall can be either programming or equipment. Genuine/False 

Genuine 

Q.14 - MSconfig holds the information before preparing it. Genuine/False 

False. The Registers hold the CPU information. 

Q.15 - The memory type SO-DIMM would in all probability be utilized in a workstation phone. Genuine/False 

Genuine 

By Georgie State - Certification Help [https://www.examguarantee.com/comptia-certifications.html] is learners manual for getting affirmed.

Moving moodle from directory to root

$
0
0
by Nikola Novakovic.  

Hello there,

I'm new to Moodle software and I need a bit of help and advice about how to proceed.

I installed moodle in subdirectory on my server, so it's currently accessed through mysite.com/~directory/

It all works fine, but I'd like to move it to root directory, as I have nothing there, and I don't want that directory name to be seen when accessing moodle itself.


What exactly should I move to root, and where to change paths/settings? Should I also change something in the database?

Moodle version: 3.6.2+

Thanks in advance.



Re: Moodle 3.5.5 + 3.6 After successfully installation - Setup Main Admin Account, cannot see password input field

$
0
0
by Sven Härtel.  

Hello Joerg,


No sry, I havent a solution for this problem. We have decided not to invest more time and order a pre installed Moodle.

https://www.ionos.de/pro/cloud-apps/a/moodle

 

I don't think it's the best solution, but it'll work for now.

 

Greetings


Moodle after installation redirect issue

$
0
0
by Mani Acos.  

Attempting to install a moodle 36_STABLE test system on my local machine, I set in my host file 127.0.0.1 to moodle.dev.local then I created an apache2 virtual host with moodle.dev.local as the ServerName and document root to /var/www/moodle


I cloned git in /var/www, creating moodle directory.

The installation went through and it gave me this config.php. I copied and pasted it into config.php and clicked next. Then I get this error

The page isn’t redirecting properly

Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

    This problem can sometimes be caused by disabling or refusing to accept cookies.


Config.php:

<?php  // Moodle configuration file

unset($CFG);
global $CFG;
$CFG = new stdClass();

$CFG->dbtype    = 'mariadb';
$CFG->dblibrary = 'native';
$CFG->dbhost    = 'localhost';
$CFG->dbname    = 'moodle';
$CFG->dbuser    = 'moodleuser';
$CFG->dbpass    = 'moodlepass';
$CFG->prefix    = 'mdl_';
$CFG->dboptions = array (

  'dbpersist' => 0,
  'dbport' => 3306,
  'dbsocket' => '',
  'dbcollation' => 'utf8mb4_general_ci',
);

$CFG->wwwroot   = 'http://moodle.dev.local';
$CFG->dataroot  = '/var/www/moodledata';
$CFG->admin     = 'admin';

$CFG->directorypermissions = 0777;

require_once(__DIR__ . '/lib/setup.php');

// There is no php closing tag in this file,
// it is intentional because it prevents trailing whitespace problems!

This makes no sense, why does it try to redirect to itself after it gave me these exact settings in the config.php?


EDIT: Curl gave me this output. It sends a 303 header with an empty location.

*   Trying 127.0.0.1...
* TCP_NODELAY set
* Expire in 200 ms for 4 (transfer 0x55bf17fdbdd0)
* Connected to moodle.dev.local (127.0.0.1) port 80 (#0)
> GET /admin/index.php HTTP/1.1
> Host: moodle.dev.local
> User-Agent: curl/7.64.0
> Accept: */*
>
< HTTP/1.1 303 See Other
< Date: Wed, 08 May 2019 08:55:14 GMT
< Server: Apache/2.4.38 (Debian)
< X-Accel-Buffering: no
< Set-Cookie: MoodleSession=41l5jnk2rcq80ff83dmu6cr0st; path=/
< Expires: Thu, 19 Nov 1981 08:52:00 GMT
< Cache-Control: no-store, no-cache, must-revalidate
< Pragma: no-cache
< Location:
< Content-Language: en
< Transfer-Encoding: chunked
< Content-Type: text/html; charset=utf-8
<
<!DOCTYPE html>
<html  lang="en"xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Redirect</title>
* Connection #0 to host moodle.dev.local left intact
</head><body><div style="margin-top: 3em; margin-left:auto; margin-right:auto; text-align:center;">This page should automatically redirect. If nothing is happening please use the continue link below.<br /><a href="">Continue</a></div></body></html>

Backup no longer functional

$
0
0
by Mike Neirinck.  

Hi


I could not make backups of huge courses. Small courses were backuped fine. 

In Home / ▶︎ Site administration / ▶︎ Server / ▶︎ Environment I noticed a warning. It told me to converting InnoDB tables to Barracuda. The server admin did so. 

$ php admin/cli/mysql_compressed_rows.php --list

mdlsp_data                      Compressed

mdlsp_data_fields               Compressed

mdlsp_enrol_paypal              Compact     (needs fixing)

mdlsp_lti                       Compact     (needs fixing)

mdlsp_user                      Compact     (needs fixing)

mdlsp_user_info_field           Compact     (needs fixing)


$ php admin/cli/mysql_compressed_rows.php --fix

mdlsp_enrol_paypal               ... Compressed

mdlsp_lti                        ... Compressed

mdlsp_user                       ... Compressed

mdlsp_user_info_field            ... Compressed


$ php admin/cli/mysql_compressed_rows.php --list

mdlsp_data                      Compressed

mdlsp_data_fields               Compressed

mdlsp_enrol_paypal              Compressed

mdlsp_lti                       Compressed

mdlsp_user                      Compressed

mdlsp_user_info_field           Compressed


$ php admin/cli/mysql_compressed_rows.php --showsql

No changes necessary

Then I upgraded Moodle to version 3.1.17 (Build: 20190311). When I try to perform a backup now I get the error shown in the screenshot or in print below.

Error reading from database


More information about this error


×Debug info: MySQL server has gone away

SELECT count(r.repositoryid)

FROM mdlsp_files f

LEFT JOIN mdlsp_files_reference r

ON r.id = f.referencefileid

JOIN mdlsp_backup_ids_temp bi

ON f.id = bi.itemid

WHERE bi.backupid = ?

AND bi.itemname = 'filefinal'

[array (

0 => '80292195975a3b19c566cc01ed7fe677',

)]

Error code: dmlreadexception

×Stack trace:

line 479 of /lib/dml/moodle_database.php: dml_read_exception thrown

line 1175 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()

line 1551 of /lib/dml/moodle_database.php: call to mysqli_native_moodle_database->get_records_sql()

line 1624 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()

line 1834 of /lib/dml/moodle_database.php: call to moodle_database->get_field_sql()

line 522 of /backup/util/dbops/backup_controller_dbops.class.php: call to moodle_database->count_records_sql()

line 1980 of /backup/moodle2/backup_stepslib.php: call to backup_controller_dbops::backup_includes_file_references()

line 34 of /backup/util/plan/backup_execution_step.class.php: call to backup_store_backup_file->define_execution()

line 181 of /backup/util/plan/base_task.class.php: call to backup_execution_step->execute()

line 177 of /backup/util/plan/base_plan.class.php: call to base_task->execute()

line 120 of /backup/util/plan/backup_plan.class.php: call to base_plan->execute()

line 322 of /backup/controller/backup_controller.class.php: call to backup_plan->execute()

line 136 of /backup/util/ui/backup_ui.class.php: call to backup_controller->execute_plan()

line 131 of /backup/backup.php: call to backup_ui->execute()

How can I solve this?


Yours sincerely

Re: Backup no longer functional

$
0
0
by Ken Task.  

MySQLserver has gone away

max_allowed_packet is too low in config of DB server.

In my.cnf under [mysqld]
max_allowed_packet=512M

restart mysqld (your mariadb)

The value above is up to you.

'SoS', Ken

Re: Moodle after installation redirect issue

$
0
0
by Ken Task.  

So you can access the moodle only by using a browser on the local system itself - not from any other workstation. http://moodle.dev.local

So what do you get with
netstat -ltnp | grep -w ':80'
Manually remove contents of moodledata/cache/ moodledata/localcache/ /moodledata/sessions/
Also clear browser cache/cookies for moodle.dev.local

'SoS', Ken


Re: Getting rid of Installatron (upgrade to 3.6.3)

$
0
0
by Ken Task.  

Too confusing to follow so really don't have any suggestion as to where you could go from where you are.

However, having said that ... did you begin by making a full site backup of the site you had working?

Hope so ... cause it might be the only way to get it back up and running again is to restore what you had and try it again.

Why?  Installatron-function ... which suggest remotely hosted and hopefully NOT on a shared host.  Unless one here in community happened to host where you do and used hosting providers scripts to install/maintain a moodle, folks like myself, who could possibly help, can't ... would be guessing forever and ever. sad

So ... where do you host?  What type of server do you have?  Shared/Managed/Self-Managed.  Do you have ssh access to the server? (terminal icon in cPanel).

'SoS', Ken


Re: Moodle after installation redirect issue

$
0
0
by Mani Acos.  

> So you can access the moodle only by using a browser on the local system itself - not from any other workstation. http://moodle.dev.local

Yes of course only locally. This is a test installation and only my computer will resolve to the vhost ServerName due to entry in /etc/hosts

> netstat -ltnp | grep -w ':80'

Apache is running, I would not get 303 from localhost otherwise.

> Manually remove contents of moodledata/cache/ moodledata/localcache/ /moodledata/sessions/
> Also clear browser cache/cookies for moodle.dev.local

Nothing of this helped unfortunately.

Re: Backup no longer functional

$
0
0
by Mike Neirinck.  

After fumbling around I'm getting following error upon trying to create a backup


Fatal error: Uncaught ddl_change_structure_exception: DDL sql execution error in /home/appcra1q/public_html/moodle/lib/dml/moodle_database.php:485 Stack trace: #0 /home/appcra1q/public_html/moodle/lib/dml/mysqli_native_moodle_database.php(1000): moodle_database->query_end(false) #1 /home/appcra1q/public_html/moodle/lib/ddl/database_manager.php(77): mysqli_native_moodle_database->change_database_structure('DROP TEMPORARY ...', Array) #2 /home/appcra1q/public_html/moodle/lib/ddl/database_manager.php(332): database_manager->execute_sql_arr(Array, Array) #3 /home/appcra1q/public_html/moodle/lib/dml/moodle_temptables.php(140): database_manager->drop_table(Object(xmldb_table)) #4 /home/appcra1q/public_html/moodle/lib/dml/moodle_database.php(398): moodle_temptables->dispose() #5 /home/appcra1q/public_html/moodle/lib/dml/mysqli_native_moodle_database.php(565): moodle_database->dispose() #6 /home/appcra1q/public_html/moodle/lib/dml/moodle_database.php(157): mysqli_native_moodle_database->dispose() #7 [internal function]: moodle_da in /home/appcra1q/public_html/moodle/lib/dml/moodle_database.php on line 485

Re: Backup no longer functional

$
0
0
by Mike Neirinck.  

I saw your message too late

Now I'm getting another error

Re: Moodle after installation redirect issue

$
0
0
by Ken Task.  

Reason I asked for you to check with netstat ... did it show the IPv6 for loopback only or did it also show or the IPv4.

Does your /etc/host have an entry for both IPv4 and IPv6?

What's the DCHP lease on your network?   A year?  Every login?

If a year, I'd set the /etc/host entry for the private IP address - IPv4 - mapped to moodle.dev.local

And you could mess with network by using arp to get an IPv4 set in a more permenant fashion.

All in all, this isn't really a moodle issue, but network/server config.

'SoS', Ken




Re: Backup no longer functional

$
0
0
by Ken Task.  

First, backup your database first (sql dump) .. even if in the state that it is, having a backup is a good idea.

The DB character set *and* collation must match for not only tables, but for columns in those tables.

In moodlecode/admin/cli/ there are scripts that will help.

 mysql_collation.php mysql_compressed_rows.php mysql_engine.php

They all will present a help screen that shows options/switches to command if executing: php nameofscript.php

Think I'd start with php mysql_compressed_rows.php -i and go from there.

https://docs.moodle.org/36/en/MySQL_full_unicode_support

Not sure the vr 3.1 environment check checks for above or not ... don't run a 3.1.x any  more.

I see /home/customerlogin/public_html/ in paths ... are you on shared host?

Do you know the user credentials for the superuser of your DB server?   If so, use those in copied DB info lines of config.php file as a test to see if the user being used normally has enough priv's to do things it needs.

Large courses ... defined how?   Size of backup or in content ... like a lot of quizzes.

Large courses either was could require tweaks upwards in php setup ... more memory to consume, max memory to use, as well as time to run.

Here again, CLI is your friend ... in code/admin/cli/ there is also a backup.php script ... execute with no parameters and it will show help.

For a large course (size) think I'd opt to set destination directory outside of moodledata and execute the script as root.   The script, BTW, takes apache out of the loop ... just php and your DB server talking is required.

'SoS', Ken


Re: Moving moodle from directory to root

Viewing all 46779 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>