You are not logged in.
I have this modprobed.db gathering all the info of ever-used modules, except it doesn't.
The problem is, that although it does seem to retain the loaded module information for some time, if I leave it be and check it after few weeks, the modules that were used some are no longer listed. I thought this was supposed to only add new positions to the module list as the laptop is being used and not detract, regardless of how long ago given module was used.
Offline
Moving to AUR Issues...
Offline
I didn't see this post originally. What is your root user's crontab?
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
# SYSTEM DAILY/WEEKLY/... FOLDERS
@hourly ID=sys-hourly /usr/sbin/run-cron /etc/cron.hourly
@daily ID=sys-daily /usr/sbin/run-cron /etc/cron.daily
@weekly ID=sys-weekly /usr/sbin/run-cron /etc/cron.weekly
@monthly ID=sys-monthly /usr/sbin/run-cron /etc/cron.monthly
*/5 * * * * /usr/bin/modprobed_db store &> /dev/null
55 * * * * sh /home/juha/.scripts/empty_vartmp.bash
Offline
That looks right. What is the output if you execute that with the redirect to null?
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
No output.
But the problem is it does work and lists all the loaded modules. However, the modules that were not loaded for a week, or three - they disappear from the db fike, even though they were there before.
Offline
No output.
That's not right; it should return usage info:
$ modprobed_db
Usage: /usr/bin/modprobed_db {list|recall|store}
See manpage for additional details
And, on my system at least:
$ modprobed_db store
The db currently contains this many records: 204
But the problem is it does work and lists all the loaded modules. However, the modules that were not loaded for a week, or three - they disappear from the db fike, even though they were there before.
So it sounds like the db file is getting overwritten??
Please post the output of the following which you do NOT need to run as the root user:
pacman -Q modprobed_db
. /etc/modprobed_db.conf && ls -l "$dbpath"/modprobed*
Last edited by graysky (2012-09-15 22:21:48)
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
Well, if I execute those commands, I get the same outputs as you. I was talking about the crontab line.
$ pacman -Q modprobed_db
modprobed_db 2.0-2
$ ls -l "$dbpath"/modprobed*
-rw-r--r-- 1 root root 888 Sep 16 00:22 /var/log/modprobed.db
-rw-r--r-- 1 root root 888 Sep 16 00:22 /var/log/modprobed.long
Offline
Well, if I execute those commands, I get the same outputs as you. I was talking about the crontab line.
OK.. try them now as your root user (or via a sudo prefix):
# modprobed_db store
Or
$ sudo modprobed_db store
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
The db currently contains this many records: 108
New modules detected. Updating db...
The db now contains this many records: 108
Offline
@Lockheed - That looks normal. I do not understand what is deleting your log files. From what you've posted, both you and your root user can call the script... I wonder if your logrotate is moving it?
Try this:
# find /var/log -name "modprobed.db"
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
/var/log/modprobed.db
Offline
There is no native function within modprobed_db that would do this, so there must be something external on your system responsible. Do you run anything that would sweep /var/log like bleachbit perhaps? Please manually move the two db files form /var/log to an alternative location. In your case, root owns them so let's try /root to see if they are safe there.
# mv /var/log/modprobed.* /root
Now edit /etc/modprobed_db.conf changing the 'dbpath' variable as well:
dbpath="/root"
If it they get deleted from /root and you or another user on your system did not do it, you have been hacked
Last edited by graysky (2012-09-16 10:15:36)
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
Ok, I did as you said and here's what's happening:
1. None is hacking me
2. I am the only user of the system
3. the module names still disappear from /root
Offline
@Lockheed - I am out of ideas as to what would be clearing your entries. There is nothing in the script itself to overwrite the db files.
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
But they have to be overwritten to add new entries, no? So in the process it must sometimes just overwrite the file with currently running list, instead of appending it.
Offline
Try version 2.10 and let me know. Only thing I can think of is that the /tmp/.tempfiles are getting deleted half way through somehow.
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
I think my tmp is deleted upon reboot. Could this happen if the module list update process is interrupted by a reboot?
Offline
All of our /tmp dirs are deleted on reboot. This is by design. The process that modprobed_db uses to compare a sorted list of the db + what is memory to what is in memory should only take nano seconds even on older hardware. Did version 2.10 solve the problem for you?
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
I have no idea. It can take few weeks to find out.
Offline
Please update this thread in a month or so, good or bad.
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline