Jump to content

Eventi Log


Recommended Posts

ciao, 

 

nel mio log di sistema ho un flood (ogni secondo) di un errore:

 

emhttpd: errore: share_luks_status, 6173: operazione non supportata (95): getxattr: /mnt/user/GoogleDrive

 

Immagine.png.d99cdcc116a9ba611f0472f17173c4a7.thumb.png.fd5b5b066a5393a15dd136a36ee0ec05.png

mi è stato detto che devo spostare la cartella su disk e non in user ma al momento per motivi di tempo e funzionalità non riesco a farlo

detto che lo stesso unassigned device non mi vede il disco "disk"

unraid.webp.aec4fa99e1b62468158937a3a4c64ce3.webp

 

Potrei provare con un script ulteriore, ma la idea di riconfigurare plex mi viene male

Il problema è che si riempe una partizione (quella di log) e devo riavviare.
volevo sapere si può cancellare il log/la partizione senza riavviare? o si può evitare di fare il logging di quell'errore?

 

Grazie

 

 

Link to comment
  • 2 weeks later...

al momento ho "tamponato" con questo script trovato nel forum che riduce ad 1 mb i file syslog

 

#!/bin/bash

size=1M

function trimLog
{
    file=$1
    temp="$file.$(date +%s%N).tmp"
    time=$(date --rfc-3339='seconds')
    before=$(du -sh "$file" | cut -f1)
    echo -n "$time: $file: $before=>"

    tail --bytes=$size "$file" > "$temp"
    chown $(stat -c '%U' "$file"):$(stat -c '%G' "$file") "$temp"
    chmod $(stat -c "%a" "$file") "$temp"
    mv "$temp" "$file"

    after=$(du -sh "$file" | cut -f1)
    echo "$after"
}

find /var/log -maxdepth 1 -type f -size +$size 2>/dev/null | sort -f |\
while read file; do trimLog "$file"; done

find "/boot/logs" "/var/lib/docker/containers" -name "*.log" -size +$size 2>/dev/null | sort -f |\
while read file; do trimLog "$file"; done

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...