From: Arne Fitzenreiter <arne_f@ipfire.org>
To: development@lists.ipfire.org
Subject: Re: vnstat 2.6 - testing
Date: Sun, 22 Mar 2020 16:32:51 +0100 [thread overview]
Message-ID: <5634157adebcc461a701794acaa99def@ipfire.org> (raw)
In-Reply-To: <02a44b78-6ca9-fbbf-0585-5a1046a75eb2@ipfire.org>
[-- Attachment #1: Type: text/plain, Size: 1468 bytes --]
Hi,
this works not as intended! If you start the vnstatd before creating the
ramdisk it
creates filehandles to the files on the disk so the ramdisk is not used
at all.
How large is the database and how have you created the traffic for the
test?
All readed files are put to the cache so it might be normal that the
cache is fuller
after ramdisk mount and copying.
Arne
Am 2020-03-22 14:16, schrieb Matthias Fischer:
> Hi,
>
> it seems that I found a (fast) solution for starting/stopping
> 'vnstatd':
>
> 1. In '/etc/init.d/vnstat' I changed:
>
> start)
> if use_ramdisk; then
> boot_mesg "Mounting vnstat ramdisk..."
> mount_ramdisk "${VNSTATLOG}"
> evaluate_retval
> fi
> ;;
>
> To:
>
> start)
> boot_mesg "Starting vnstatd..."
> loadproc /usr/sbin/vnstatd -d --alwaysadd
> sleep 2
> evaluate_retval
>
> if use_ramdisk; then
> boot_mesg "Mounting vnstat ramdisk..."
> mount_ramdisk "${VNSTATLOG}"
> evaluate_retval
> fi
> ;;
>
> 2. Changed:
>
> stop)
> umount_ramdisk "${VNSTATLOG}"
> ;;
>
> To:
>
> stop)
> boot_mesg "Stopping vnstatd..."
> killproc /usr/sbin/vnstatd
> sleep 2
> evaluate_retval
> umount_ramdisk "${VNSTATLOG}"
> ;;
>
> Tested. Worked.
>
> But this doesn't check whether the old interface files were imported
> correctly...
>
> Opinions?
>
> Best,
> Matthias
>
> P.S.:
> 'cached memory' is now at 90.42%.
> Used: 4.18%
> Buffered: 1.39%
> Free: 4.00%
> On a 2 GB / 32bit-machine (offline).
> Hm.
next prev parent reply other threads:[~2020-03-22 15:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <fec66a3e-fe99-c64e-f2e3-c96ed3877a1b@ipfire.org>
2020-03-22 13:16 ` Matthias Fischer
2020-03-22 15:32 ` Arne Fitzenreiter [this message]
2020-03-22 16:49 ` Matthias Fischer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5634157adebcc461a701794acaa99def@ipfire.org \
--to=arne_f@ipfire.org \
--cc=development@lists.ipfire.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox