1
0
mirror of https://github.com/azlux/log2ram.git synced 2023-10-10 13:37:24 +02:00
Commit Graph

175 Commits

Author SHA1 Message Date
azlux
9ac0af973c
Better README
Improved readability of the readme and comment in the config file
2017-12-19 18:36:30 +01:00
Henri de Jong
3e7185d210 Improved readability of the readme and comment in the config file 2017-12-18 18:23:23 +00:00
Nathan Huizinga
dc8c788e05 Added logrotate support 2017-12-16 20:33:20 +01:00
azlux
9f60f97849
fix readme, add fecture
Added:
- check on install
- clear old folder on install
- better uninstall script
- use systemctl instead of manually call script in the cron
2017-12-16 12:15:39 +01:00
Nathan Huizinga
4f7c1a33a2 Bug fix: avoid installing when still installed 2017-12-16 11:42:37 +01:00
Nathan Huizinga
0e76e8d655 Fixed: supporting a previous log2ram version again 2017-12-11 08:55:38 +01:00
Nathan Huizinga
1ffd89c70e Fixed: use systemctl reload to write changes to disk and to the log 2017-12-10 22:53:48 +01:00
Nathan Huizinga
8e52dfe231 Revert "Added start, write and stop logging"
This reverts commit 4479c11a41.
2017-12-10 22:37:51 +01:00
Nathan Huizinga
4479c11a41 Added start, write and stop logging 2017-12-07 20:56:57 +01:00
Nathan Huizinga
658161bb04 Fixed consistent naming of /var/hdd.log 2017-12-07 17:42:40 +01:00
azlux
db049c32eb
No error when remove log2ram log
use rm -f instead of rm
2017-11-06 11:36:40 +01:00
Sailing74
585432f0fa
use rm -f instead of rm
Suppresses an error message, if the file does not exist.
2017-11-06 08:32:45 +01:00
azlux
b45e8e95a6 Update log2ram.service 2017-10-09 13:33:20 +02:00
azlux
a31ba4927f Remove old folder 2017-10-02 20:48:02 +02:00
azlux
b7c725f47d Fix for #28
The init is useless and the mount was async.
2017-10-02 20:37:46 +02:00
azlux
5a47ec1e5a issue 2017-10-02 00:50:31 +02:00
azlux
71ff96ad2a Merge pull request #27 from MegaV0lt/master
Update uninstall.sh
2017-08-27 20:29:08 +02:00
MegaV0lt
f339cd25a1 Update uninstall.sh
Fix typo on line 9
2017-08-23 14:18:50 +02:00
azlux
18c009a6dd Uninstall script
As asked into #23 #21
2017-07-27 20:13:51 +02:00
azlux
ded0d7b895 Merge pull request #22 from lpirl/master
make hourly Cron job quiet
2017-07-25 11:09:28 +02:00
Lukas Pirl
d72b910700 make hourly Cron job quiet
otherwise, systems that are able to send mails would send the uninteresting output every hour to the admin
2017-07-25 10:05:03 +02:00
azlux
2e55fa7bed mail if error 2017-07-18 00:46:54 +02:00
azlux
150136da42 Merge pull request #19 from Sailing74/fixoutofram
unmount tmpfs if RAM too small to prevent corruption of logdir
2017-07-18 00:38:50 +02:00
Sailing74
da1950989f unmount tmpfs if RAM too small to prevent corruption of logdir 2017-07-14 08:51:22 +02:00
azlux
bd1b669ed9 Stupid I am
Log on disk wasn't copy on install, so the shutdown destroy everything.
#18 #17
2017-06-11 20:59:57 +02:00
azlux
9d76a1b082 /me trying to fixe apache2 2017-06-11 20:14:35 +02:00
azlux
1e18687475 REBOOT after install
It's maybe the pb of #17
2017-06-02 19:56:57 +02:00
azlux
ea486efb5f bash error
source function not available into every /bin/sh
2017-05-02 15:13:05 +02:00
azlux
b232b00950 bad copy/paste ? 2017-05-02 14:47:59 +02:00
azlux
a54aee856d Configuration file added 2017-05-02 00:43:37 +02:00
azlux
931054c8d9 Typo 2017-04-27 11:24:05 +02:00
azlux
c7870156ec Merge pull request #14 from Sailing74/checkdirsize
Added check of tmpfs size before syncing HDD to RAM.
2017-04-19 13:13:35 +02:00
Sailing74
df63737eac Added check of tmpfs size before syncing HDD to RAM. 2017-04-18 15:53:36 +02:00
azlux
18ace5438f typo 2017-04-12 13:29:54 +02:00
azlux
d8080fe551 Update
Don't need the section "before" anymore.
Upgrade the license to a valid one.
2017-04-12 13:28:56 +02:00
azlux
05a31e0e35 Merge pull request #12 from zador-blood-stained/master
Update service dependencies to start on early boot
2017-04-11 21:21:42 +02:00
zador-blood-stained
01632f9cb1 Update service dependencies to start on early boot
This changes log2ram dependencies to start as early as possible, before other
services that may require access to /var/log, including rsyslog and
systemd-journald.

Additional dependencies on shutdown.target are required to ensure that
the service will be stopped at shutdown/reboot when DefaultDependencies
is set to "no" [1].

RequiresMountsFor declares dependency on /var mount when it is a mount point.

IgnoreOnIsolate prevents stopping the service when isolating another unit.

[1]: https://www.freedesktop.org/software/systemd/man/systemd.service.html
2017-04-11 20:47:02 +03:00
azlux
13e694c56b Warning added 2017-04-11 18:57:52 +02:00
azlux
7d4a20084b Update for the new default feature 2016-12-02 18:34:50 +01:00
Nick Daly
6d57e5fcef Remove log2ram log on startup, add usage. (#9)
Remove log2ram log on startup.
2016-12-02 01:26:09 +01:00
azlux
0435ec3abb Merge pull request #8 from NickDaly/hourly-cron
Sync the ramlog back to disk, hourly.
2016-12-01 01:27:33 +01:00
Nick Daly
e9b190983d Write sync status to HDD_LOG/log2ram.log. (#7)
* Write sync status to HDD_LOG/log2ram.log.

- Store sync status directly in the HDD log, to make sure we know
  about it if something fails.  This won't help if the HDD_LOG
  variable is borked, but it'll help with everything else.

- Made sync a function to avoid repeating five lines three times.

- log2ram now requires (cp or rsync) and tee, mount, umount.

* Split sync into syncFromDisk and syncToDisk.

- After restarting, I realized that I had combined both types of sync
  into one line, when the syncing failed.  This fixes that bug.

* Exclude log2ram.log from rsync so rsync doesn't delete it on sync.
2016-12-01 01:27:06 +01:00
Nick Daly
8d440eab6c Exclude log2ram.log from rsync so rsync doesn't delete it on sync. 2016-11-30 13:09:39 -06:00
Nick Daly
ac75c3dac1 Merge in the split-sync changes from master. 2016-11-30 12:29:28 -06:00
Nick Daly
e238849069 Sync the ramlog back to disk, hourly.
- Since the cron job could be called before the user reboots after
  install (or if log2ram is disabled), we check that the hdd log
  location exists before syncing.

- Copy the log2ram.hourly sync script to cron's hourly directory on
  install.
2016-11-30 11:41:41 -06:00
Nick Daly
7d825982ae Write sync status to HDD_LOG/log2ram.log.
- Store sync status directly in the HDD log, to make sure we know
  about it if something fails.  This won't help if the HDD_LOG
  variable is borked, but it'll help with everything else.

- Made sync a function to avoid repeating five lines three times.

- log2ram now requires (cp or rsync) and tee, mount, umount.
2016-11-30 11:24:41 -06:00
azlux
edd77da64e Update README.md 2016-10-20 12:47:56 +02:00
azlux
83be051ed8 oneshot add
From @datenklause
With Type=oneshot, systemd waits until the start action has completed
before it considers the unit to be active, so dependencies start only
after the start action has succeeded. With Type=simple, dependencies
will start immediately after the start action has been dispatched.
2016-10-20 12:41:47 +02:00
azlux
5e0014c848 for dash compatibility 2016-10-18 10:25:27 +02:00
azlux
e54ed85681 if condition issue 2016-10-18 00:32:27 +02:00