User Tools

Site Tools


cbsnet

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
cbsnet [2025/12/08 18:34] – created renocbsnet [2025/12/17 14:13] (current) reno
Line 68: Line 68:
 </konsole> </konsole>
 </hidden> </hidden>
 +
 ===== Brewer Log Form ===== ===== Brewer Log Form =====
  
Line 76: Line 77:
 [[http://cbsn.hiitravel.ca:8671/embed/instruments|Manage Instruments]]\\ [[http://cbsn.hiitravel.ca:8671/embed/instruments|Manage Instruments]]\\
  
 +The log form backend is running off cbsnet via pm2.\\
 +<hidden To check the status>
 +<konsole>
 +cbsnet$ pm2 ls
 +┌────┬────────────────────┬──────────┬──────┬───────────┬──────────┬──────────┐
 +│ id │ name               │ mode     │ ↺    │ status    │ cpu      │ memory   │
 +├────┼────────────────────┼──────────┼──────┼───────────┼──────────┼──────────┤
 +│ 1  │ brewer-admin       │ fork     │ 1    │ online    │ 0%       │ 66.2mb   │
 +│ 0  │ brewer-back        │ fork     │ 1    │ online    │ 0%       │ 56.5mb   │
 +└────┴────────────────────┴──────────┴──────┴───────────┴──────────┴──────────┘
 +
 +</konsole>
 +</hidden>
 +<hidden How to reset pm2 the service>
 +<konsole>
 +cbsnet$ pm2 restart 1
 +Use --update-env to update environment variables
 +[PM2] Applying action restartProcessId on app [1](ids: [ '1' ])
 +[PM2] [brewer-admin](1) ✓
 +┌────┬────────────────────┬──────────┬──────┬───────────┬──────────┬──────────┐
 +│ id │ name               │ mode     │ ↺    │ status    │ cpu      │ memory   │
 +├────┼────────────────────┼──────────┼──────┼───────────┼──────────┼──────────┤
 +│ 1  │ brewer-admin       │ fork     │ 2    │ online    │ 0%       │ 16.3mb   │
 +│ 0  │ brewer-back        │ fork     │ 1    │ online    │ 0%       │ 53.3mb   │
 +└────┴────────────────────┴──────────┴──────┴───────────┴──────────┴──────────┘
 +</konsole>
 +Where '1' is the id number
 +</hidden>
  
 +==== Error in log forms ====
 +Archived and error logs can be found in <key>/var/cache/brewer-log/logs</key>.\\
 +Error logs are identified by the prefix of the file name <key>ERROR_*</key>.\\
 +Some common log issues
 +  - Too many <key>,</key>. This is usually found when right before the comment line or comments including commas
 +  - The use of a <key>;</key>. semicolon are not supported
 +  - Comments too long. The max length for the comment is 500 characters.
  
 +===== Metabase =====
 +Metabase is an open source program that is able to read from a database and plot/display it in a friendly interface. The CBSN version can be found [[http://metabase.cbsn.hiitravel.ca|here]].
 +<hidden To check the status of metabase>
 +<konsole>
 +cbsnet@Thinkbrew:~$ su root
 +Password:
 +root@Thinkbrew:/home/cbsnet# systemctl status metabase
 +● metabase.service - Metabase server
 +     Loaded: loaded (/etc/systemd/system/metabase.service; disabled; vendor pre>
 +     Active: active (running) since Sun 2025-12-07 20:22:44 GMT; 3 days ago
 +   Main PID: 32791 (java)
 +      Tasks: 160 (limit: 37964)
 +     Memory: 2.8G
 +        CPU: 45min 41.735s
 +     CGroup: /system.slice/metabase.service
 +             └─32791 /usr/bin/java -jar /home/cbsnet/metabase/metabase.jar
 +</konsole>
 +This indicates metabase is running properly. </hidden>
 +<hidden How to restart metabase>
 +<konsole>
 +cbsnet@Thinkbrew:~$ su root
 +Password:
 +root@Thinkbrew:/home/cbsnet# systemctl restart metabase
 +</konsole>
 +</hidden>
 +\\
 +===== Backups =====
 +  - Drive Backups are managed by [[https://github.com/linuxmint/timeshift|timeshift]]. 
 +    - Monthly Backup
 +      - Backup are made on the 1st of each month at 00:00:00 UTC
 +      - up to 3 copies are saved at one time
 +    - Weekly Backup
 +      - Backup are made on each Sunday at 21:00:00 UTC
 +      - up to 2 copies are saved at one time
 +  - Database backups are managed by the db_backup.sh
 +    - Database base backup are done every Tuesday and at 04:00:00 UTC
 +    - Up to 9 copies are saved at one time
 +    - Database that are being backed up are
 +      - brewerdata
 +      - brewer_db
 +      - brewer_security
 +      - brewerpart
 +      - metabase
 +\\
 +===== Database =====
 +There are currently 5 database (as of Dec 17, 2025) running on cbsnet via mariadb (Version 10.5.29-MariaDB-0+deb11u1 Debian 11)
 +  - brewerdata - this database is primary used to host the IDEAS database and includes all the brewer data. The best way to view this data is via [[https://metabase.cbsn.hiitravel.ca|metabase]].
 +  - brewer_db - this database is used to for hosting the brewer log form data.
 +  - brewer_security - this database is used to host the user information needed for the brewer log form
 +  - brewerpart - This database is used to host the brewer parts database. This is what brewparts.exe uses
 +  - metabase - This database is used to host the config and different views used for [[https://metabase.cbsn.hiitravel.ca|metabase]].
  
cbsnet.1765218860.txt.gz · Last modified: 2025/12/08 18:34 by reno