Admin_only value changes at modules table

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Admin_only value changes at modules table

Post by almustone »

Hi!

I have a wierd problem with site. My website worked well about a week and now there came problems.

There is screenshot about my changelog about things what have done before crash and the error message.

I had backup about database and I made comparing with tables.

Website started working again after I replaced mywebsite_modules table with old mywebsite_modules table. I compared table content next to each others and found out that there was happened one change.

******THIS IS WORKING VERSION******
INSERT INTO `mywebsite_modules` (`module_name`, `status`, `version`, `admin_only`, `active`, `allow_fe_lazyload`, `allow_admin_lazyload`) VALUES
('CMSMailer', 'installed', '5.2.2', 1, 1, 1, 0),
('CMSPrinting', 'installed', '1.0.5', 1, 1, 0, 1),
('FileManager', 'installed', '1.4.5', 1, 1, 1, 0),
('MenuManager', 'installed', '1.8.6', 1, 1, 0, 0),
('MicroTiny', 'installed', '1.2.7', 1, 1, 1, 1),
('ModuleManager', 'installed', '1.5.8', 1, 1, 0, 1),
('News', 'installed', '2.14.4', 1, 1, 1, 1),
('Search', 'installed', '1.7.11', 1, 1, 1, 1),
('ThemeManager', 'installed', '1.1.8', 1, 1, 0, 1),
('Gallery', 'installed', '2.0.1', 0, 1, 0, 0),
('FormBuilder', 'installed', '0.8', 1, 1, 0, 0),
('TinyMCE', 'installed', '2.9.12', 1, 1, 0, 0),
('Showtime', 'installed', '3.4', 0, 1, 0, 0),
('JQueryTools', 'installed', '1.2.6', 1, 1, 0, 0),
('CGSimpleSmarty', 'installed', '1.7.4', 1, 1, 0, 0),
('CGExtensions', 'installed', '1.42.2', 1, 1, 0, 0),
('CGBlog', 'installed', '1.12.6', 1, 1, 0, 1);

-- --------------------------------------------------------

*******THIS IS BROKEN VERSION*******

INSERT INTO `mywebsite_modules` (`module_name`, `status`, `version`, `admin_only`, `active`, `allow_fe_lazyload`, `allow_admin_lazyload`) VALUES
('CMSMailer', 'installed', '5.2.2', 1, 1, 1, 0),
('CMSPrinting', 'installed', '1.0.5', 1, 1, 0, 1),
('FileManager', 'installed', '1.4.5', 1, 1, 1, 0),
('MenuManager', 'installed', '1.8.6', 1, 1, 0, 0),
('MicroTiny', 'installed', '1.2.7', 1, 1, 1, 1),
('ModuleManager', 'installed', '1.5.8', 1, 1, 0, 1),
('News', 'installed', '2.14.4', 1, 1, 1, 1),
('Search', 'installed', '1.7.11', 1, 1, 1, 1),
('ThemeManager', 'installed', '1.1.8', 1, 1, 0, 1),
('Gallery', 'installed', '2.0.1', 0, 1, 0, 0),
('FormBuilder', 'installed', '0.8', 1, 1, 0, 0),
('TinyMCE', 'installed', '2.9.12', 1, 1, 0, 0),
('Showtime', 'installed', '3.4', 1, 1, 0, 0),
('JQueryTools', 'installed', '1.2.6', 1, 1, 0, 0),
('CGSimpleSmarty', 'installed', '1.7.4', 1, 1, 0, 0),
('CGExtensions', 'installed', '1.42.2', 1, 1, 0, 0),
('CGBlog', 'installed', '1.12.6', 1, 1, 0, 1);

-- --------------------------------------------------------

What causes that change?

Now I created new admin and there came no problems. Is problem causer that CMSMS version tester?

Best regards

Aleksi Mustonen
Attachments
help3.jpg
Näyttökuva 2014-11-12 kello 11.41.50.png
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: Admin_only value changes at modules table

Post by Jo Morg »

admin_only is a setting used by CMSMS to determine whether the module should only be loaded from the admin or not, thus preventing it from being loaded by the frontend. While it being set accounts for the errors you are experiencing, there is no plausible explanation to why it was changed by other means than when the module is installed or upgraded. CMSMS on it's own doesn't change the value.
My suggestion, is of course, to backup the database, and change that 1 back to 0.
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Thank you for fast reply! Yes website is now up and running and now I'm looking for a answer what made that value change? It wasn't first time I saw that error and before I reinstalled module and everything started working again. Now I found out that value change which causes error. I believe there is something what makes that change every now and then but I don't know what it is.
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

Problem is still there. Now it changed values from Gallery and Formbuilder module from 0 -> 1, but not in Showtime. And I haven't done anything special. Just normal modifycations with template.

What can be problem and how to fix it? What can possibly cause that?

Please help, because I must publish website soon.

Do you need more info about my website?
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: Admin_only value changes at modules table

Post by Jo Morg »

almustone wrote:Do you need more info about my website?
Indeed: System info, at least.
I have installed/upgraded CMSMS hundreds of times already with and without some of the most popular modules in different server environments, and I have never experienced an issue even remotely similar to this one.
The only possible causes that come to my mind are:
  • - file corruption: if you uploaded files through ftp;
  • - some UDT with some custom code that alters the database;
  • - some included PHP script that alters the database;
  • - some external script that somehow misbehaves;
  • - human intervention (this if you are not the only one with access to the server or CMSMS backend);
So there is little information for us to be able to help. Only thing we can do is guess...
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

Here is system information. There aren't red marks.

----------------------------------------------
Cms Version: 1.11.11
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
MicroTiny: 1.2.7
ModuleManager: 1.5.8
News: 2.14.4
Search: 1.7.11
ThemeManager: 1.1.8
Gallery: 2.0.1
FormBuilder: 0.8
TinyMCE: 2.9.12
Showtime: 3.4
JQueryTools: 1.2.6
CGSimpleSmarty: 1.7.4
CGExtensions: 1.42.2
CGBlog: 1.12.6

Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: none
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true

Php Information:
phpversion: 5.3.3
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 32M
upload_max_filesize: 32M
session_save_path: /tmp (0777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)

Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysqli)
Server Db Version: 5.5.37
Server Db Grants: Could not find a suitable "GRANT ALL" permission. This may mean you could have problems installing or removing modules. Or even adding and deleting items, including pages
Server Time Diff: No filesystem time difference found

----------------------------------------------

Server: mysql14.nebula.fi (10.2.3.45 via TCP/IP)
Server: MySQL
Server versio: 5.5.37-log - MySQL Community Server (GPL)

Web server:
Apache
libmysql - 5.1.73

Here is url to the website test version: http://tanhuvaara.fi/testisivu/

Hopefully this will help you.
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: Admin_only value changes at modules table

Post by Jo Morg »

From your system info alone there is no apparent reason for this issue to happen.
Jo Morg wrote: The only possible causes that come to my mind are:
  • - file corruption: if you uploaded files through ftp;
  • - some UDT with some custom code that alters the database;
  • - some included PHP script that alters the database;
  • - some external script that somehow misbehaves;
  • - human intervention (this if you are not the only one with access to the server or CMSMS backend);
Can you exclude any if not all of the above list?
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

Here are some answers.

The only possible causes that come to my mind are:
- file corruption: if you uploaded files through ftp;
- I have moved files from another server to this one. But I checked from Filezilla that every transfer was successfully completed. But I can't be 100 % sure, that there will not be corrupted file somewhere.

- some UDT with some custom code that alters the database;
- I'm not really sure what is UDT, but there isn't any special code anywhere. Just normal install with most common modules.

- some included PHP script that alters the database;
- No there isnt. Only a couple of standalone javascript codes like Jquery Social Stream, Google analytics and so on.

- some external script that somehow misbehaves;
- I have used only smarty scripts like global contents ect. from CMSMS. Theres nothing special.

- human intervention (this if you are not the only one with access to the server or CMSMS backend);
- I'm only one who uses phpMyAdmin, but there are a couple of other admin users at CMSMS who can edit content. But is it even possible to change values without logging in to phpMyAdmin and manually change them?

Thank you for an answer!
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: Admin_only value changes at modules table

Post by Jo Morg »

almustone wrote:- I have moved files from another server to this one. But I checked from Filezilla that every transfer was successfully completed. But I can't be 100 % sure, that there will not be corrupted file somewhere.
http://docs.cmsmadesimple.org/installat ... -integrity
This test can also be made from the admin panel in: Site Admin > System Verification. You can typically disregard errors in validating lang files, and files in tmp folder, as there could be justified differences.
almustone wrote:- some UDT with some custom code that alters the database;
- I'm not really sure what is UDT, but there isn't any special code anywhere. Just normal install with most common modules.
http://docs.cmsmadesimple.org/tags/user-defined-tags
almustone wrote:- some external script that somehow misbehaves;
- I have used only smarty scripts like global contents ect. from CMSMS. Theres nothing special.
By external I mean any other application that may have been installed alongside CMSMS, such as another CMS package, Forum software, e-com script... etc.
almustone wrote:- I'm only one who uses phpMyAdmin, but there are a couple of other admin users at CMSMS who can edit content. But is it even possible to change values without logging in to phpMyAdmin and manually change them?
No Yes. (*)

(*) PS: actually the correct answer is yes... there are modules which allow direct backend interaction with the database in ways similar to phpMyAdmin.

Note: this is completely atypical behavior. There is no way that flag should be set/unset by normal CMSMS use other than by installing the module itself. I would try a different server (even a local development one) to test it thoroughly. I'm willing to bet that there is something not working as it should on your server environment. This kind of issue never happened before that I know of.
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

Thanks again.

I'm not using any UDT. There aren't any other installed applications either.

I downloaded that checksum file and checked my system. Here is the result:

3 Files Not found
Files Not found:
/tmp/cache/SITEDOWN
/tmp/cache/index.html
/tmp/templates_c/index.html

1425 Files failed md5sum check:
/index.php
/doc/CHANGELOG.txt
/doc/COPYING.txt
/doc/UPGRADE.txt
/doc/htaccess.txt
...

I'm not sure is that helping at all, but maybe something. Result isn't telling me nothing. I downloaded checksum file from my installation, so I can compare files if problem come again.

Or how about upgrading my CMSMS installation with new files, or at least replacing old files with new ones? If I'm right core files are stand alone, so they will not replace or destroy installed modules.

How about optimizing or repairing tables from System maintenance? Will that make any difference? CMSMS shows that everything is working fine.

I just got an idea where I can maybe go that problem around if it is possible to do. Do you know, that am I able to change writing permissions to that specific table only at database? Idea is that CMSMS can't write nothing to that modules table and change values. It will only read it. If I wan't to install something later I go change writing permissions back on. I'm not so familiar with database settings so I'm not sure if this is possible to do.

But I will create mirror site of this to other server tonight. I will let that stand alone and let's see if that will be up without problems.
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: Admin_only value changes at modules table

Post by Jo Morg »

almustone wrote:1425 Files failed md5sum check:
that shouldn't happen at all.

I recommend the following procedure:
  • - do a full backup of files and db;
  • - upload the CMSMS archive to the root of the site by using Cpanel File Manager upload feature (or through ssh if you have access to it);
  • - extract files from the archive (Cpanel File Manager or ssh again);
  • - enter the backend and clear CMSMS cache;
  • - test everything;
HTH
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

I downloaded same version of CMSMS installation. I don't have cPanel, so I uploaded files via FTP. I extracted files to my computer and then overided old ones.

After that I cleared cache and checked checksum. Nothing happened.. Still md5sum check fails. Any clue why is this happening?

I even tried uploading files two times, to be sure that uploading files went fine. Same result both times. I have tried different browsers with cleared browser history.

1 Files Not found
Files Not found:
/tmp/cache/SITEDOWN

1413 Files failed md5sum check:
/index.php
/doc/CHANGELOG.txt
/doc/COPYING.txt
/doc/UPGRADE.txt
...

*** EDIT ***

I made test with clean install to the other folder and checksum problems are there too. Here is a screenshot. I downloaded checksumfile from here: http://dev.cmsmadesimple.org/project/files/6 File name: cmsmadesimple-1.11.11-full-checksum.dat

So I think thats wierd.. Can there be something to do with file permission or something like that with errors?
Attachments
Näyttökuva 2014-11-20 kello 0.40.18.png
almustone
Forum Members
Forum Members
Posts: 43
Joined: Wed Oct 22, 2014 7:04 pm

Re: Admin_only value changes at modules table

Post by almustone »

Hi!

I extracted files again via ssh and now errors are gone. So it looks like problem was uploading files via Filezilla. Thats wierd, because I have created a lot of websites with that way and get any of problems like that before. This is first time I ever used file checksum either.

But let's see if that helps now. At least there aren't any error messages around and everything is running like it should be.

I let you know, if problems come back again.

Thanks a lot for a help!
Attachments
Näyttökuva 2014-11-20 kello 10.16.23.png
Näyttökuva 2014-11-20 kello 10.16.23.png (14.8 KiB) Viewed 4181 times
Post Reply

Return to “Modules/Add-Ons”