treehouses log ram [on|off] 40M memory for log files (fixes #807)#1276
Open
LordJashin32 wants to merge 7 commits into
Open
treehouses log ram [on|off] 40M memory for log files (fixes #807)#1276LordJashin32 wants to merge 7 commits into
treehouses log ram [on|off] 40M memory for log files (fixes #807)#1276LordJashin32 wants to merge 7 commits into
Conversation
Member
|
Is the only way to enable and disable this to install and uninstall every time? |
law-lin
reviewed
May 16, 2020
Member
law-lin
left a comment
There was a problem hiding this comment.
Works for me.
root@law-lin:~/cli# ./cli.sh log2ram
log2ram is off
root@law-lin:~/cli# ./cli.sh log2ram
log2ram is off
root@law-lin:~/cli# ./cli.sh log2ram on
Successfully enabled log2ram, please reboot
root@law-lin:~/cli# ./cli.sh log2ram on asodksaodsk
Error: Too many arguments.
Usage: cli.sh log2ram [on|off]
force logs to be stored in ram and only writes to disk on shutdown
https://github.com/azlux/log2ram
Stores logs in 40M (Megabytes) in mount point in memory
Example:
cli.sh log2ram
log2ram is off
cli.sh log2ram on
Successfully enabled log2ram, please reboot
cli.sh log2ram off
Successfully disabled log2ram
root@law-lin:~/cli# ./cli.sh log2ram off
Sucessfully disabled log2ram
root@law-lin:~/cli# ./cli.sh log2ram
log2ram is off
root@law-lin:~/cli# ./cli.sh log2ram on
Successfully enabled log2ram, please reboot
root@law-lin:~/cli# ./cli.sh log2ram
log2ram is off
root@law-lin:~/cli# reboot
...
root@law-lin:~/cli# ./cli.sh log2ram
log2ram is on
Member
Author
Yeah basically. The package doesn't really give much more than what the install does: root@treehouses:~/test1/cli# log2ram --help
Usage: log2ram {start|stop|write}
write doesn't even give an output message when i run it. And i can't tell if it ran from from df -h |
Member
Author
|
moved to log.sh root@treehouses:~/cli# ./cli.sh log ram
log2ram is on
root@treehouses:~/cli# ./cli.sh log ram on
Successfully enabled log2ram, please reboot
root@treehouses:~/cli# ./cli.sh log ram on dfds
Error: Too many arguments.
Usage: cli.sh log [0|1|2|3|4|show|max|ram [on|off]]
Example:
cli.sh log
log 0: log is disabled
cli.sh log 0
log 0: log disabled
cli.sh log 1
log 1: level set to Info
cli.sh log 2
log 2: level set to Info and Warning
cli.sh log 3
log 3: level set to Info, Warning, and Error
cli.sh log 4
log 4: level set to Info, Warning, Error, and Debug
cli.sh log show
Shows the default 6 lines of log which is at (/var/log/syslog)
@treehouses/cli: temperature fahrenheit
cli.sh log show 5
Shows 5 lines of log which is at (/var/log/syslog)
@treehouses/cli: temperature fahrenheit
cli.sh log max
log X: level set to max
cli.sh log ram
log2ram is off
force logs to be stored in ram and only writes to disk on shutdown
https://github.com/azlux/log2ram
Stores logs in 40M (Megabytes) in mount point in memory
cli.sh log ram on
Successfully enabled log2ram, please reboot
cli.sh log ram off
Successfully disabled log2ram
root@treehouses:~/cli# ./cli.sh log ram off
Sucessfully disabled log2ram
root@treehouses:~/cli# ./cli.sh log ram
log2ram is off
root@treehouses:~/cli# ./cli.sh log ram on
Successfully enabled log2ram, please reboot
root@treehouses:~/cli# ./cli.sh log ram
log2ram is off
root@treehouses:~/cli# |
treehouses log2ram 40M memory for log files (fixes #807)treehouses log ram [on|off] 40M memory for log files (fixes #807)
dogi
approved these changes
May 20, 2020
Member
|
@LordJashin32 nice one, but on second thought this is something for builder ... at least in parts |
Member
Author
|
updated for builder package instead. Test results are in main post up top @LordJashin32 |
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
treehouses/builder#717