The "Tiki Remote Instance Manager (TRIM)" has gone into maintenance mode, and the code was forked and revamped to become its replacement, now known as the "Tiki Manager".
TRIM is an acronym for the Tiki Remote Instance Manager
See also TIM and Tiki Console.
Some of the wishes below will likely be handled by Monitoring and Configuration Management and Systems Orchestration
State as of October 2018
- 2017-2018 was a very active period for TRIM : https://sourceforge.net/p/tikiwiki/code/HEAD/log/?path=/trim Mostly:
- Addition and refinement of clone and clone-and-upgrade
- Permit support on setups with multiple versions of PHP. Ex.: http://wikisuite.org/How-to-install-a-PHP-version-picker-on-ClearOS (which itself had some trickiness with respect to Command Line version of PHP vs web version of PHP)
- This uncovered a lot of edge cases, as TRIM is regularly moving between directories.
- This was necessary to start using in production for Pre-Dogfood Servers
- A test Test plan was created
State as of April 2017
- After a pretty calm period in 2012-2013-2014, there has been a recent increase in activity in 2015-2016-2017: https://sourceforge.net/p/tikiwiki/code/HEAD/log/?path=/trim
- Has quite a few features but mostly used for backups
- Use at your own risk. However, it was demonstrated to work on different hosts, so somewhat usable.
- It is somewhat usable in "ideal" conditions (ideal PHP configuration, certain tools must be installed on the server), but not yet robust to deal with various server configurations.
- It is not yet fully documented. It is a wizard-like app, so if you are familiar with shell scripts and installing/upgrading Tiki, you should be OK. However, it is not robust to user errors. For example, if you mistype your database username, the script could just die instead of giving a second chance.
- A revamp is being contemplated: TRIM Revamp
^
Who is behind this?
- Marc Laporte
- Jonny Bradley
- Louis-Martin Richard (tester)
- Philippe Back (plans to add a nicer front-end GUI)
- amette
- Rodrigo Primo (added WordPress support)
- You? (We are looking for Beta-testers!!)
Nice to have
- If TRIM tries to make an instance where there is a directory "images", it will causes conflicts and create problems.
- TRIM could check that no conflicting directories exist
Roadmap
[+]Phase 1
-
Disable site during upgrade (via .htaccess)Done -
Update DB (1.x to 1.y sql script)Done -
Handle both 1.9 and 1.10 -
Cron job for automatic check and report on file integrity (what about cache files?)Done -
Something to indicate TRIM is working (sometimes, it is busy for many minutes and we are just left to wait, not knowing if it's stalled) ... may not be possible-
Ok. Then, please indicate (in general) what TRIM is doing. Something like "TRIM will now transfer all files from SourceForge to TRIM (master) and then upload them to your instance. As long as you are not getting an error message, TRIM is hard at work! This operation could take 10-20 minutes or even a few hours, depending on server performance and network speed."Done
-
-
run fixperms.shDone -
Be more robust to various paths for php5 (ex.: using "which php" to find it)Done (using variables in Makefile so modification only required once)
Phase 2
-
For TRIM to handle backupsDone -
Make instance should suggest some values (ask for SSH host name and SSH user first). If you just type "Enter", it picks this value. These defaults should be editable somewhere in a config file. It also serves as a good example for the proper format. The default format which works for Fantastico hosting:Done- Web root : /home/$sshuser/public_html
- Web URL : http://$sshhost
- Working directory : /home/$sshuser/trim_working (TRIM should create with appropriate rights)
- TRIM will need to be indicated the database login with sufficient rights to do this
- Use this new info to populate db/local.php
- Maybe pick profile from TRIM? (equivalent to tiki-install.php?)
- Cron job
- Option to backup things outside of Tiki (ex.: mail directory, access logs, etc)
- To be able to handle symlinks
- /home/user/www is a symlink of /home/user/public_html and if I indicate /home/user/www as the web root of the instance, TRIM backup will not backup files) bug or feature enhancement request?
-
Rename the bundled _htaccess to .htaccess for instances running on Apache-
Would be better to set an alias from .htaccess to _htaccessThis is what the Tiki installer tried to do by default
-
- Handle transition from CVS to SVN (Sylvie has an unreleased script)
- 1.9.x to 1.10.x, which requires 2 .sql operations
- document so people know to type things like C 0-52
- "Next page" when too much info in one screen (sometimes hundreds of lines of scrollback), but maybe this is a bad idea because it'll prevent unattended operations. hmmm
-
Add a note before entering a passphrase in addinstance.php : "If you enter a passphrase, you will need to enter it every time you run TRIM, and thus, automatic, unattended operations (like backups, file integrity checks, etc.) will not be possible."done -
If mysqladmin fails (ex.: bad login, MySQL down), it should offer to re-enter value or to abort database creation. In this last case, the system should indicate something like : "TRIM was unable to create your database with the information you provided. You should create it via your admin panel (cPanel, etc) and provide the information when you point your browser to tiki-install.php"done
- time stamp 2008-06-02 22:33:48 is 3938 s in the future
- errors on setup.sh (when insufficient perms)
-
"warning: locate: warning: database /var/lib/slocate/slocate.db' is more than 8 days old"Nothing to do with TRIM -
ssh: profiles.tiki.org: Name or service not knownSeems solved-- -
Make convert should handle 2.2 to 3.0This is done by make upgrade
Phase 3
-
TRIM can sometimes use 100% of the CPU (especially when compressing files): should we add the "nice" command?done - Should be a way to set a different folder/disk for backups (since this will become huge!)
- Should also be a way to set permissions, so other software can access. Ex.: http://wikisuite.org/TRIM-and-Syncthing-for-automated-offsite-backups
-
TRIM should add db/lock file -
TRIM should populate {$lastup}, which appears in templates/tiki-bot_bar.tpl. However, lastup should be (de)activatable and filterable by group.This is now well handled in Tiki. SVN revision number is from the code, and display is a module, which can be assigned to certain groups - Set password at install (or anytime!)should be in tiki-install.php as well 😊. recreate admin user if deleted?
-
Investigate DB creation with ClearOS (perhaps cPanel, ISPConfig, etc.)TRIM creates database and user with MySQL root -
Once everything is nice and stable with SSH, add SFTP/FTP support(done) so we could use on hosts like Mosso Cloud sites -
In addition to check and backup, having an automatic update script option (useful to always keep test sites like demo.tiki.org up to date.Unattended updates won't be able to deal with SVN conflicts. Maybe just send a warning email? - Check used/available disk space. (% of used space) where TRIM is installed. TRIM will not be able to make proper backups if it runs out of space. Checking disk space on each Tiki is the job of the Monitoring process.
Phase 4
- Alerts for failure of an unattended operation. Ex: backup fails because SSH connection is refused.
- Backup
- Have backups generate a "live" version of Tiki.
- So a web agency could have a locally running backup of all their Tikis with yesterday's data.
- Insures an easy way to test the automated backup system
- Staff can continue to work if server or Internet connection is down.
- Data could be in a USB Tiki format so Tiki admins could copy/sync to a mobile drive to have a backup in their pocket at all times.
- Could also be to setup read-only mirrors
- Tiki would need a read-only mode. So when users log in, they are informed that any changes here will be overwritten at the next sync.
- These mirrors could be used for DNS3, DNS4, DNS5, etc.
- So a web agency could have a locally running backup of all their Tikis with yesterday's data.
- Move an instance from one server to another (backup & restore in one step?)
- This could include (This is the manual procedure I do) closing the old site ($site_closed eq 'y'), setting $site_closed_msg="This site has moved to: http://..." or "This site has moved to a new server. If you are seeing this message, it's because the DNS has not yet propagated for you. Please try again in a few hours or use this temporary address: http://..." before the backup and opening the site on the new server ($site_closed eq 'n').
- Save to Amazon S3 and similar online storage services
- Backup of the database should handle multitiki like doc/devtools/backupdb.sh
- Investigate if scripts like automysqlbackup, rsync-incr or rsnapshot have any concepts, features or code that would be useful for us.
- Have backups generate a "live" version of Tiki.
- Profiles
- Investigate if/how TRIM could help maintaining: OpenSourceCMS type demo to test/develop and show off profiles
- Hourly build of each profile: http://profiles.tiki.org/profile_name
- Investigate any synergy with the Profiles to apply database change to one, many or all instances.
- Turn off unsafe, buggy or unused features
- Add watch all wiki pages or watch all trackers to multiple Tikis
- Use existing Tiki functions for mass operations. Ex.: add a Tiki user on dozens of Tikis, etc (In this case, it's important to use existing Tiki functions rather than alter the database directly)
- Management
- Add branch & lastup when listing instance.
- Sort by branches & date, so as to see who is most out of date, who needs a security release, etc.
- Add branch & lastup when listing instance.
- Install
- At install, a maintenance.html (or install.html should be shown instead of files/folders)
Phase 5
- Trigger Server Monitoring for check for domain name expiry, uptime / performance / content testing /etc.
- Attempt a Recovery for common issues (ex.: MySQL crashed table)
- When suspicious files are detected, in addition to deleting them, it should be possible to send them to a non Web accessible "quarantine" for further analysis or even optionally send to the security squad.
- import mysql data a bit like BigDump
- Possibly automated running of testing feature.
Related
- TikiTests
- https://svn.bryght.com/hostmaster and http://groups.drupal.org/hm2/project-goals
- http://mu.wordpress.org/
- XWiki Enterprise Manager is typically used to manage public or private wiki farms.
- https://github.com/ziadoz/awesome-php/blob/master/README.md#deployment
Wishlist
Rating | Subject | Submitted by | Importance | Easy to solve? | Priority | Category | Volunteered to solve | Created | LastModif | Comments | |
---|---|---|---|---|---|---|---|---|---|---|---|
(0) | OpenSourceCMS type demo to test/develop and show off profiles | Marc Laporte | 8 | 7 | 56 |
| 2008-01-29 | 2018-10-19 | luci-22 Oct 18 | ||
(0) | TRIM: make compare | Marc Laporte | 4 | 2 | 8 |
| 2016-05-12 | 2016-12-12 | marclaporte-19 Oct 18 | ||
(0) | TRIM make clone (mirror) and make cloneandupdate or cloneandupgrade (pre-dogfood server) | Marc Laporte | 3 | 2 | 6 |
| 2016-05-19 | 2018-10-11 | marclaporte-19 May 17 | ||
(0) | TRIM and Tiki closer interop brainstorming: make TRIM available via Composer? | Marc Laporte | 5 | 3 | 15 |
| 2016-05-25 | 2016-05-25 | marclaporte-19 Oct 18 | ||
(0) | Enable .htaccess or its nginx equivalent on show instances for SEFURLs demonstrations | luciash d' being 🧙 | 2 | 10 |
| 2016-10-06 | 2024-05-03 | ||||
(0) | TRIM fails with PHP parse error | luciash d' being 🧙 | 7 | 35 |
| 2018-08-10 | 2018-08-10 | luci-11 Oct 18 | |||
(0) | TRIM: make update reports svn: invalid option: --allow-mixed-revisions | luciash d' being 🧙 | 1 low | 8 | 8 |
| 2018-08-15 | 2018-10-11 | marclaporte-11 Oct 18 | ||
(0) | TRIM: make instance fails with PHP Fatal error | luciash d' being 🧙 | 5 | 25 |
| 2018-08-17 | 2018-10-11 |
Closed issues
[+]Rating | Subject | Submitted by | Importance | Easy to solve? | Priority | Category | Volunteered to solve | Created | LastModif | Comments | |
---|---|---|---|---|---|---|---|---|---|---|---|
(0) | Round Robin / Redundancy / Disaster planning for all *.tikiwiki.org content | Marc Laporte | 9 | 6 | 54 |
| 2007-07-11 | 2013-11-14 | marclaporte-28 Sep 12 | ||
(0) | tiki-install.php to create mysql user, mysql database and assign permissions | Marc Laporte | 1 low | 5 |
| 2008-03-11 | 2012-04-18 | ||||
(0) | templates_c cleaning is too aggressive and deletes system files | Marc Laporte | 8 | 40 |
| 2008-05-19 | 2011-01-05 | ||||
(0) | TRIM should replace PECL's ssh2 extension with phpseclib | vauxhaul | 6 | 30 |
| 2010-02-01 | 2015-10-23 | marclaporte-15 Jul 15 | |||
(0) | make update has 3 suspicious error messages | Marc Laporte | 25 |
| 2015-10-23 | 2018-10-11 | |||||
(0) | make update and make check messing up on svn tag | Marc Laporte | 25 |
| 2015-10-23 | 2015-10-30 | marclaporte-30 Oct 15 | ||||
(0) | make backup has trouble with backups of attachments stored on disk | Marc Laporte | 25 |
| 2015-10-23 | 2015-10-30 | marclaporte-30 Oct 15 | ||||
(0) | make delete works but issues an non-friendly error message | Marc Laporte | 25 |
| 2015-10-23 | 2015-10-30 | marclaporte-30 Oct 15 | ||||
(0) | make backup should exclude temporary data | Marc Laporte | 25 |
| 2015-10-23 | 2015-10-23 | rodrigo-23 Oct 15 | ||||
(0) | Instance folder ID vs instance ID mismatch | Marc Laporte | 25 |
| 2015-10-23 | 2015-10-27 | rodrigo-27 Oct 15 | ||||
(0) | Replace ssh-dss keys with ssh-rsa or ssh-ecdsa keys | Rodrigo Primo | 25 |
| 2015-10-23 | 2015-10-23 | |||||
(0) | Check that all is OK with Composer & Console | Marc Laporte | 25 |
| 2015-10-23 | 2017-09-24 | marclaporte-19 May 16 | ||||
(0) | Same server backup | Marc Laporte | 25 |
| 2015-10-23 | 2017-02-09 | marclaporte-19 May 16 | ||||
(0) | TRIM fails to install Tiki | drsassafras | 25 |
| 2018-05-15 | 2024-07-06 | marclaporte-16 Aug 18 | ||||
(0) | Creating a new SVN/GIT instance using the web manager doesn’t work ( CLI worked) | Bernard Sfez / Tiki Specialist | 5 | 5 | 25 |
| 2019-11-06 | 2021-07-04 | |||
(0) | fix 'make viewdb' command in trim (sqlite3 missing: add dependency check & info?) | Xavier de Pedro | 3 | 8 | 24 |
| 2016-08-03 | 2016-11-08 | marclaporte-08 Nov 16 | ||
(0) | TRIM: allow editing instance information | Xavier de Pedro | 4 | 4 | 16 |
| 2016-08-03 | 2017-11-16 | marclaporte-16 Nov 17 | ||
(0) | Prepare for SourceForge hosted Apps | Marc Laporte | 1 low | 1 difficult | 1 |
| Marc Laporte | 2008-11-03 | 2012-05-19 | marclaporte-03 Jul 12 |
Feedback on fresh install of TRIM as of 2016-04-04
-
"make instance": should offer to create a username and db from root accessdone a long time ago - TRIM should warn if not on PHP 5.5 CLI (for Tiki 13.x+)
Feedback on fresh install of TRIM as of 2016-02-12
Improvements
-
make access should cd to the right directorydone -
default web root should be /var/www/virtual/example.org instead of /home/root/public_htmldone, depending on OS -
backup format should go from 1_2016-02-12_04-19-40.tar.bz2 to 1_example.org_2016-02-12_04-19-40.tar.bz2done - If TRIM fails (ex: to login, to backup, etc.), an email alert should be sent out.
Web
The command line TRIM is useful, but the web GUI never got the attention it deserves. It needs a revamp to
- Bootstrap UI in standalone version
- Perhaps make use of Adminer or Adminer Editor: https://www.adminer.org/
- be re-architected to run in a Tiki
- Use Tiki groups and permissions
- Site list to be connected to trackers to track meta-data
- as a ClearOS app to manage 1 or many Tiki instances
Similar projects