Moved to new server - stuck with daily.log

So I have had Libre running on Virtualbox for a few weeks now at work, awating real hardware. Installed Librenms on the new hardware, dumped the sql database on the old server and imported it to the new one, moved the rrd-folder and the .env-file etc.
So everything seemed fine until I had a the opurtunity to update Librenms online. Tried to run ./daily.sh and got stuck with “daily.log - no such file or folder” googled abit and found someone else who did the ol` touch daily.log - That did not help at all. Even tried to scp the old daily.log file from the old server to the new one, still no luck. The script daily.sh would not run at all.

So whats my next move?

Secondly, the fresh install noticed I had one old “poller not polling” Lets call it poller vdebian, and googled told med to have a look at global settings and remove it, but the global settings tab was all wonky and not readable at all. Other place I can remove the old poller?

Final note: The server is running in strictly offline network and so I cannot post any logs right now. But both poller and librenms.log all looked good, and validate.php only complained about the old poller not running.

Any pointers?

You should at least post the output of validate.php so we can see what’s being said there just in case.

I’d re-run the permission part of the install docs though, most likely something missed.

Thanks for the reply! I found where to delete the poller node eventually! Anyways, here is some screens from the main issue



I

Tried to run ./daily.sh today as well - still the same. While Librenms is running just fine as long as I don’t run a ./discovery.php -h all then it all crashes.

Little update: Did a git pull, ./scripts/composer_wrapper.php install --no-dev, /lnms migrate and finally the ./validate.php without any issues. Re-run the installer how, re-ran the ownerships of all the files. But still, ./daily.sh still not happy!

What does ls -alh /opt/librenms/logs/ show?

librenms@librenms:~$ ls -alh /opt/librenms/logs/
total 65M
drwxrwxr-x+ 2 librenms librenms 4.0K Mar 26 11:45 .
drwxrwx–x 30 librenms librenms 4.0K Mar 26 11:39 …
-rwxrwxrwx 1 librenms librenms 0 Mar 24 11:40 daily.log
-rw-rwxr-- 1 librenms librenms 522K Mar 26 13:03 discovery_wrapper.log
-rw-rwxr-- 1 librenms librenms 318K Mar 22 19:53 discovery_wrapper.log.1
-rw-rwxr-- 1 librenms librenms 71 Mar 20 12:21 .gitignore
-rw-rwxr-- 1 librenms librenms 23M Mar 26 15:00 librenms.log
-rw-rwxr-- 1 librenms librenms 13M Mar 22 23:55 librenms.log.1
-rw-rwxr-- 1 librenms librenms 7.3K Mar 23 01:12 maintenance.log
-rw-rw-r-- 1 librenms librenms 4.6M Mar 26 15:00 poller_wrapper.log
-rw-rwxr-- 1 librenms librenms 10M Mar 26 01:05 poller_wrapper.log.1
-rw-rwxr-- 1 librenms librenms 10M Mar 24 15:45 poller_wrapper.log.2
-rw-rwxr-- 1 librenms librenms 854K Mar 22 10:45 poller_wrapper.log.2.gz
-rw-rwxr-- 1 librenms librenms 3.4M Mar 22 23:55 poller_wrapper.log.3
-rw-rw-r-- 1 librenms librenms 13K Mar 26 15:00 service_wrapper.log

I just got this from my home setup as well - just now when I ran ./daily.sh

librenms@nms:~$ ./daily.sh 
Updating to latest codebase                       ./daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
./composer.json has been updated
Running composer update dot-mike/nmsdevicelinks
> LibreNMS\ComposerHelper::preUpdate
Loading composer repositories with package information
Updating dependencies
Lock file operations: 1 install, 0 updates, 0 removals
  - Locking dot-mike/nmsdevicelinks (1.0.0)
Writing lock file
Package influxdb/influxdb-php is abandoned, you should avoid using it. No replacement was suggested.
Package web-token/jwt-key-mgmt is abandoned, you should avoid using it. Use web-token/jwt-library instead.
Package web-token/jwt-signature is abandoned, you should avoid using it. Use web-token/jwt-library instead.
Package web-token/jwt-signature-algorithm-ecdsa is abandoned, you should avoid using it. Use web-token/jwt-library instead.
Package web-token/jwt-util-ecc is abandoned, you should avoid using it. Use web-token/jwt-library instead.
75 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
> Illuminate\Foundation\ComposerScripts::postUpdate
No security vulnerability advisories found.
Updating Composer packages                        /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
@Updated from 857e8fdf0 to 2edcaaed9               /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Updating SQL-Schema                               /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Updating submodules                               /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Cleaning up DB                                    /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Fetching notifications                            /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Caching PeeringDB data                            /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
librenms@nms:~$ ./validate.php 
===========================================
Component | Version
--------- | -------
LibreNMS  | 25.3.0-78-g2edcaaed9 (2025-04-01T08:11:59+02:00)
DB Schema | 2025_03_19_205700_fix_ospfv3_ports_table (332)
PHP       | 8.3.19
Python    | 3.9.2
Database  | MariaDB 10.5.28-MariaDB-0+deb11u1
RRDTool   | 1.7.2
SNMP      | 5.9
===========================================

[OK]    Composer Version: 2.8.6
[OK]    Dependencies up-to-date.
[OK]    Database connection successful
[OK]    Database connection successful
[WARN]  Your database schema has extra migrations (2025_02_05_15000_create_snmp_commands_table). If you just switched to the stable release from the daily release, your database is in between releases and this will be resolved with the next release.
[OK]    SQL Server meets minimum requirements
[OK]    lower_case_table_names is enabled
[OK]    MySQL engine is optimal
[OK]    MySQL and PHP time match
[OK]    Active pollers found
[OK]    Dispatcher Service not detected
[OK]    Locks are functional
[OK]    Python poller wrapper is polling
[OK]    Redis is unavailable
[OK]    rrd_dir is writable
[OK]    rrdtool version ok

And here I was preparing for updating my raspian bullseye to bookworm and migrating Librenms.

Is this all on raspian os?

Sadly no, started with Debian 12 - and followed me to Raspbian

SELinux enabled?

Nope - and that raspian install is now history. Just updated to latest Raspbian based to Debian Bookworm and going to install Librenms and import database backup.

So to clear things up:
At work Debian 12 running Libre
At home Raspian bases on Debian 12 (just updated today) and I get this as well:

librenms@raspberrypi:~$ ./daily.sh 
Updating to latest codebase                       ./daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Updating Composer packages                        /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Updating SQL-Schema                               /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Updating submodules                               /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Cleaning up DB                                    /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Fetching notifications                            /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK
Caching PeeringDB data                            /opt/librenms/daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 65: @/opt/librenms/logs/daily.log: No such file or directory
/opt/librenms/daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory
 OK

The only things they have in common is that they both are using databases that have been migrated from one install to another.
At work: Debian 12 virtual image while waiting for server → Migrated .sql
At home: Raspbian 11 updated to Raspbian 12 → Migrated .sql

Follow the offical Librenms install howto on both, and this migration howto:

What about if you run echo "test" >> /opt/librenms/logs/daily.log as the librenms user yourself?

That worked just fine, but “test” is the only thing in the file. But I just noticed a strange @ here there.

librenms@raspberrypi:~$ echo “test” >> /opt/librenms/logs/daily.log
librenms@raspberrypi:~$ cat logs/daily.log | grep test
test
librenms@raspberrypi:~$ cat logs/daily.log
test
librenms@raspberrypi:~$ ./daily.sh
Updating to latest codebase
./daily.sh: line 62: @/opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 65: @ /opt/librenms/logs/daily.log: No such file or directory
./daily.sh: line 66: @/opt/librenms/logs/daily.log: No such file or directory

Could be correct, but! Look at the screenshot, this @ appears atleast on user prefs and global settings (global settings is not working)

Edit: Found that pesky @! located in config.php :blush:

1 Like

I hope you don’t mind me laughing about this :slight_smile: :joy:

How the heck didn’t validate pick that up. Can you show me how it appeared in config.php?

librenms@raspberrypi:~$ cat config.php | grep @
@<?php
librenms@raspberrypi:~$ ./validate.php
===========================================
Component | Version
--------- | -------
LibreNMS  | 25.3.0-87-g044adb6c9 (2025-04-03T07:49:31+02:00)
DB Schema | 2025_03_19_205700_fix_ospfv3_ports_table (332)
PHP       | 8.2.28
Python    | 3.11.2
Database  | MariaDB 10.11.11-MariaDB-0+deb12u1
RRDTool   | 1.7.2
SNMP      | 5.9.3
===========================================

[OK]    Composer Version: 2.8.6
[OK]    Dependencies up-to-date.
[OK]    Database connection successful
[OK]    Database connection successful
[WARN]  Your database schema has extra migrations (2025_02_05_15000_create_snmp_commands_table). If you just switched to the stable release from the daily release, your database is in between releases and this will be resolved with the next release.
[OK]    SQL Server meets minimum requirements
[OK]    lower_case_table_names is enabled
[OK]    MySQL engine is optimal
[OK]    MySQL and PHP time match
[OK]    Active pollers found
[OK]    Dispatcher Service not detected
[OK]    Locks are functional
[OK]    Python poller wrapper is polling
[OK]    Redis is unavailable
[OK]    rrdtool version ok
[OK]    Connected to rrdcached
librenms@raspberrypi:~$

just put a @ at the top before the <?php
The good news is that ./daily.sh is working at my home raspbian server, the bad news is that rrdcached is stuffed, and I´m really stuck again!

Tried to run the rrd-tool command as the librenms user and got this:
ERROR: realpath(192.168.1.50/sensor-temperature-lmsensors-1.rrd): No such file or directory

Global settings says rrd lives in /opt/librenms/rrd

:roll_eyes:

Edit: What a day! Librenms is running on a rpi - found out that I needed rrdcached:armhf for this to work!

So basicly what is left to fix now: Make ./daily.sh work on the server at work.

We actually do a check for the first line in config.php but only that <?php is on that line so anything before or after it won’t fail the check.

However, if do @<?php my install breaks completely as it can’t load config.php.

Anyway, let us know how you get on with your work install