Jump to content

PineAP Activity log not displayed after changing log location to /usb/logs/


steven5

Recommended Posts

Problem:

After changing the logging location for PineAP to /usb/logs/ and restarting the Wifi Pineapple (Mark 7), the activity logs are not displayed in the Logging->PineAP Activity section.

My analysis:

When checking the log location, the size date modified does change, so it seems like writing to the new log location is working.

root@mk7:/pineapple# ls -l /usb/logs/
-rwxrwxrwx    1 root     root       1273856 Feb  2 12:28 log.db
root@mk7:/pineapple# ls -l /usb/logs/
-rwxrwxrwx    1 root     root       1277952 Feb  2 12:32 log.db

Any ideas?

 

Link to comment
Share on other sites

It seems as if the location of the log (as you correctly have observed) actually moves to the new location, but the web UI doesn't read from that file. It's pretty obvious when testing different log options. When set to /tmp (the default), the page showing logs updates as it should. If moving the location to some alternative place, then the old log entries keeps on showing (those in /tmp), nothing from the new location. If the log file in /tmp is removed, the web UI gets empty again even though /tmp should be "out of scope". So, the web UI is obviously not fetching any log entries from the alternative location, but expects it to always be placed in /tmp. The file /tmp/pineap.conf changes and reflects the changes being made to the log location, but, as said, it's not used as it seems (also stored in the /etc/config/pineap file). When moving the log.db file from the alternative location to /tmp, the log entries that was saved to the alternative location is being shown in the logging tab of the web UI, so logging is truly being done to the alternative location.

Always stopping Pineap in the web UI before setting the new log location and then restarting it, and since the pineap process is started with the pineap.conf file, it should read the new location.

A workaround can be to create a symlink in /tmp to the alternative location where the log file actually is.

For example
cd /tmp
rm log.db
(or rename it if you want to keep it for some reason)
ln -s /usb/logs/log.db log.db

Be sure to be quick since the log.db file in /tmp is recreated if deleted (most likely not if PineAP is disabled when doing this).

Now the web UI should update from the alternative location. Not the correct way to do it, but it works. The symlink won't be persistent over reboots though since it's in /tmp.

Link to comment
Share on other sites

Thanks for the quick response dark_pyrro! The workaround does not seem to work for me. My steps:

  1. Stop PineAP
  2. Change logging location to /usb/logs/
  3. Remove /tmp/log.db
  4. Create symlink as you described (ln -s /usb/logs/log.db log.db)
  5. Start PineAP
  6. The logging section is still not showing logs

Is there a way for me to file a bug report so maybe in a future release this could be fixed?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...