Skip to content
View in the app

A better way to browse. Learn more.

Froxlor Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Fehlermeldung bei Erstellung der awstats Statistiken seit 2.3.15

Featured Replies

Seit derm Update auf 2.3.15 bekomme ich nachts eine E-Mail des Cronjobs mit Zeilen wie diese:

ln: /home/kunden/web1/awstats/domain1.de/2026-10/: das Überschreiben des Verzeichnisses ist nicht möglic


Jetzt habe ich das auf der Console mit --debug ausgeführt:

# /usr/bin/php8.3 -q /var/www/froxlor/bin/froxlor-cli froxlor:cron 'traffic' --debug
Checking froxlor file permissions...OK
Running "traffic" job (debug)
[information] Traffic run started...
[information] http traffic for web1 started...
[information] Running awstats_buildstaticpages.pl for domain 'domain1.de' (Output: '/home/kunden/web1/awstats/domain1.de/2026-10/')
ln: /home/kunden/web1/awstats/domain1.de/2026-10/: das Überschreiben des Verzeichnisses ist nicht möglich
[information] Gathering traffic information from '/home/kunden/web1/awstats/domain1.de/awstats102026.domain1.de.txt'
[information] Running awstats_buildstaticpages.pl for domain 'domain2.de' (Output: '/home/kunden/web1/awstats/domain2.de/2026-10/')
ln: /home/kunden/web1/awstats/domain2.de/2026-10/: das Überschreiben des Verzeichnisses ist nicht möglich
[information] Gathering traffic information from '/home/kunden/web1/awstats/domain2.de/awstats102026.domain2.de.txt'
[information] ftp traffic for web1 started...
[information] mail traffic usage for web1 started...
[information] total traffic for web1 started
[information] calculating webspace usage for web1
[information] calculating mailspace usage for web1
[information] calculating mysqlspace usage for web1
[information] http traffic for web2 started...
[information] Running awstats_buildstaticpages.pl for domain 'domain3.de' (Output: '/home/kunden/web2/awstats/domain3.de/2026-10/')
ln: /home/kunden/web2/awstats/domain3.de/2026-10/: das Überschreiben des Verzeichnisses ist nicht möglich
[information] Gathering traffic information from '/home/kunden/web2/awstats/domain3.de/awstats102026.domain3.de.txt'
[information] ftp traffic for web2 started...
[information] mail traffic usage for web2 started...
[information] total traffic for web2 started
[information] calculating webspace usage for web2
[information] calculating mailspace usage for web2
[information] calculating mysqlspace usage for web2

Die Dateien werden aber angelegt / aktualisiert:

-rw-r--r--   1 web2 web2  11172  6. Okt 16:12 awstats.domain3.de.alldomains.html
-rw-r--r--   1 web2 web2  30572  6. Okt 16:12 awstats.domain3.de.allhosts.html
-rw-r--r--   1 web2 web2   7870  6. Okt 16:12 awstats.domain3.de.allrobots.html
-rw-r--r--   1 web2 web2  28704  6. Okt 16:12 awstats.domain3.de.browserdetail.html
-rw-r--r--   1 web2 web2   5469  6. Okt 16:12 awstats.domain3.de.downloads.html

Hat sich im Bereich des Cronjobs bzw der Erstellung der Statistiken etwas verändert oder wie bekomme ich die Fehlermeldung wieder los?

Solved by d00p

vermutlich eher bzgl diverser "security" fixes was symlinks etc. angeht, muss ich mal debuggen, danke für die info

  • Solution

Probiere mal folgendes Patch, der sollte das Problem beheben:

diff --git a/lib/Froxlor/FileDir.php b/lib/Froxlor/FileDir.php
index 9bd3327e..e1520708 100644
--- a/lib/Froxlor/FileDir.php
+++ b/lib/Froxlor/FileDir.php
@@ -482,12 +482,19 @@ class FileDir
                        if (substr($filename_to_check, 0, strlen($fixed_homedir)) != $fixed_homedir) {
                                throw new Exception("Target path/file not within the required customer home directory");
                        }
-                       // check whether file is symlink itself
+                       // check whether file is symlink itself - only validate where it points to, but keep
+                       // returning the path of the link (callers like 'ln -fTs' or unlink() need the link
+                       // itself, not its target)
                        if (is_link($filename)) {
-                               $filename = readlink($filename);
-                               $check_dir = FileDir::makeCorrectDir(dirname($filename), $fixed_homedir);
+                               $link_target = readlink($filename);
+                               if (substr($link_target, 0, 1) != '/') {
+                                       // relative target, resolve against the directory containing the link
+                                       $link_target = dirname($filename) . '/' . $link_target;
+                               }
+                               $link_target = self::resolveDotSegments($link_target);
+                               $check_dir = FileDir::makeCorrectDir(dirname($link_target), $fixed_homedir);
                                if (substr($check_dir, 0, strlen($fixed_homedir)) != $fixed_homedir) {
-                                       throw new Exception("Found symlink pointing outside of customer home directory: " . substr($filename, strlen($fixed_homedir)));
+                                       throw new Exception("Found symlink pointing outside of customer home directory: " . substr($link_target, strlen($fixed_homedir)));
                                }
                        }
                }
  • Author

Danke für die schnelle Hilfe. Habs eingebaut und geb dir dann Rückmeldung ob der Cronjob wieder eine Mail rausschickt.
Auf der Console läuft es mit Debug sauber durch.

Edited by Shortie
Console ergänzt

  • Author

Es lief auch heute Nacht wieder ohne Fehlermeldung durch. Nochmals Danke für die schnelle Lösung

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.