Jump to content

jj_uk

Members
  • Posts

    367
  • Joined

  • Last visited

Posts posted by jj_uk

  1. Thanks for the reply. I came up with this, seems to work.

     

    #!/bin/sh
    
        # Destination folder that will be cleared and will receive the copied data:
        dest="/mnt/user/backup/CommunityApplicationsAppdataBackup/appdata-latest"
    
        # The expected path of the source data (for sanity checking)
        src_must_contain="/mnt/user/backup/CommunityApplicationsAppdataBackup/appdata/ab_"
    
        # Sent arguments: post-run, destination path, true|false (true on backup success, false otherwise)
         
        today=$(date +'%Y-%m-%d_%H%M%S')
        logfile="/mnt/user/backup/CommunityApplicationsAppdataBackup/appdata/port-run-$today.log"
    
    
    { # required for logging, see EOF for closing brace.
    
        src="$2"
        backup_status="$3"
    
        echo "log: $logfile"
        echo
        echo "params:"
        echo "param 1 = $1"
        echo "param 2 = $2"
        echo "param 3 = $3"
        echo
    
    
        if [ $1 != "post-run" ]; then
            echo "ERROR: param 1 not \"post-run\", exiting."
            exit 0
        fi
    
    
        # check param indicates the backup was successful:
        if [ $backup_status != "true" ]; then
            echo "ERROR: backup_status is not true, exiting."
            exit 0
        fi
    
    
        # check source path contains the expected path:
        if [[ $src != *"$src_must_contain"* ]]; then
            echo "ERROR: src path appears to be at an unexpected location, exiting."
            exit 0
        fi
    
    
        # check source is a directory:
        if [ -d $src ]; then
            echo "source: $src"
        else
            echo "ERROR: src is not a directory, exiting."
            exit 0
        fi
    
    
        # check destination is a directory:
        if [ -d $dest ]; then
            echo "dest:   $dest"
        else
            echo "ERROR: dest is not a directory, exiting."
            exit 0
        fi
    
    
        # empty destination directory:
        rm -rf $dest/*
    
        echo "Copying src to dest..."
        # copy source to destination
        cp -r $src/ $dest/
    
        echo
        
        echo
        echo "finished, exiting."
        exit 0
        
    } 2>&1 | tee -a $logfile

     

  2. I'd like to create a script to run after the backup has successfully completed. 

    The script needs to run only if the backup was successful, then:

     

    Empty the `/mnt/user/CommunityApplicationsAppdataBackup/appdata-latest/` folder.

    Copy the folder that was just created by the backup tool to the above path.

     

    I've not written any scripts before. Does anyone have any example scripts?

  3. I recently changed the fixed IP address that unraid is using to allow me to move it outside of the DCHP range.

    I've changed the proxy settings in radarr/sonarr to use the new unraid ip address:8118, and they can connect to the indexers again.

     

    But SAB can't connect to the downloader servers. Clicking the spanner in Sab, I see this:

     

    Local IPv4 address  10.27.4.254

    Public IPv4 address  Connection failed!

    IPv6 address  None

    Nameserver / DNS Lookup  OK

     

    Not sure what to do, I can't see a proxy setting in Sab to force the use of privoxy. Any idea?

  4. I've just turned on an unraid server that's been off for 3 years.

     

    when I go to the IP address of the server, it redirects to

     

    https://**removed**.unraid.net

     

    But there's an error page: 

     

    This site can’t be reached

    Check if there is a typo in **removed**.unraid.net.

    If spelling is correct, try running windows network Diagnostics.

    DNS_PROBE_FINISHED_NXDOMAIN

     

    It was working ok when the server was shut off a few years ago.  Any ideas?  I don't have a monitor cable to connect to the server at the moment, so no console.

  5. Hi- I'm trying to fix nextcloud following the instructions here: https://info.linuxserver.io/issues/2023-06-25-nextcloud/ but i'm stuck.

     

    I changed the repository back to lscr.io/linuxserver/nextcloud:version-24.0.12 and restarted.

     

    I had some warnings about /nextcloud/nginx/nginx.conf and /nextcloud/nginx/site-confs/default.conf being out of date, so i deleted them and restarted the container. They were recreated.

     

    The log file now shows only this:

    Quote

     

    Could not open input file: /app/www/public/cron.php

     

     

     

     

    When accessing the nextcloud webgui ip address, I get this:

     

    Quote

    Internal Server Error The server encountered an internal error and was unable to complete your request. Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report. More details can be found in the webserver log.

     

    When trying to update, I get this:

     

    image.thumb.png.324049d1434a46f89fbe514d4183fbc1.png

     

    I read my notes from past updates and run the command that I always use:

     

    sudo -u abc php /config/www/nextcloud/updater/updater.phar

     

    but get the same write permission error as above.

     

    Here's my nextcloud appdata, the user/group seems to be nobody/nogroup. I can't remember if this was user/group abc/abc previously?

     

    image.png.e83c8dbce0c252d5fc6a6d49977854ad.png

     

    I'm now stuck and don't know what to do to get nextcloud working again?  I've tried as much as I can, but this is beyond me.

     

    EDIT:

     

    I ran 

    chown -R abc:abc /config/www
    
    sudo -u abc php /config/www/nextcloud/updater/updater.phar
    

    The updater is now running. We'll see what happens.

     

    EDIT 2: 

     

    This is working for me. Nextcloud updated once and I was able to access the GUI.

     

     

  6. 40 minutes ago, Frank1940 said:

    IF that disk (that is to be removed) is still in the parity-protected array, make sure that you are copying disk-to-disk!  A copy operation between a disk (in the array) and a User Share can result in data loss.  Stated again, disk-to-Share (or Share-to-disk) can easily result in a data loss...

     

    It's copying from

    /mnt/disk2/MediaServer

    to 

    /mnt/disk1/MediaServer

     

    So that's disk to disk, right?

     

     

    /mnt/user/MediaServer   <-- is that a user share?

     

     

  7. The process of changing the parity drive to a 20T drive, and replacing a faulty disk has now completed.

     

    I've now replaced another small data disk with a 20T disk.  As I now have loads of free space on the server, I'd like to remove a disk. The process to remove a drive is to reset the config, choosing to preserve assignments, changing the disk to be removed to 'unassigned' then starting the array (in maintenance mode, for speed).

     

    As a disk has been removed, what happens here? Does Unraid try recreate the removed disk's data onto the remaining disks?  In my case, there will definitely be enough space for this to happen, but what happens if there's not enough space? What happens to the share settings if they're set to use, or exclude that disk?

     

    This isn't covered in the FAQ. https://wiki.unraid.net/Manual/Storage_Management#Removing_data_disk.28s.29

     

  8. I followed the procedure 'exactly' to perform the parity swap. The old parity drive was 8T, the new parity drive is 20T. I have the following drives (image below) :

    image.thumb.png.7ddc287a3fc789d1a334644caaea91db.png

     

    The parity swap process completed successfully.

     

    The last part of the instructions states that running a parity check is optional. So I chose to run it.

     

    There are literally millions of sync errors being corrected by the parity check!  - What's going on ?!

    The parity check position is past 8T (my largest data drive). Is this simply the parity drive being reset to a known state and nothing to worry about? The new parity drive was precleared before use. Should I be worried??

     

    image.thumb.png.0a43ec49d64ccfe5aa986667cebe35a4.png

    tower1-diagnostics-20221208-1820.zip

  9. I have a data disk that is showing smart errors. The disk is about 12 months old, and annoyingly a 3-cycle preclear didn't show any errors, but that's life. The drive was ripped from a USB backup box so it has no warranty. Bye bye cash.

     

    My server is running low on storage, so I've bought two 20TB drives (usb backup drives, currently connected via usb and preclearing 3x cycles).

     

    All data disks and the parity disk are currently 8TB.

     

    To insert the 20T disks, I'll also need to replace the cache drive as it must be >= the largest data disk.

    Would I be OK swapping out the parity drive with a 20T, rebuilding the array then swapping the failing drive with the old parity drive? 

     

    Or should I do a the parity swap procedure instead ? (https://wiki.unraid.net/The_parity_swap_procedure)

     

    image.thumb.png.57ca0e5e7470c4c7a2c6f505147f3f63.png

     

  10. I've had this problem for a while now. A long time ago, I renamed a share from CamelCase, to lowercase. Ever since doing that, the camel case share comes back at system reboot.

     

    For the old camel case share, I've deleted all the share's folders from all disks and the cache drive using MC, and i've deleted the share in the 'shares' tab UI, but upon reboot, the share re-appears - I just can't get rid of it, then fix common problems detects duplicate shares again.

     

    Any ideas how to delete the old share, forever?

  11. Both my servers are spiking CPU usage due to "find", about every 7 seconds. The CPU high load lasts about a second.

     

    What is "find" and why is it spiking the CPU so often?  It's not a problem on my "Tower 1" sever, but it is a problem on my low-power "microserver1".

     

     

    image.thumb.png.c351ef3297470426218ba5d76a72593d.png

     

     

     

     

    image.thumb.png.ab659987c7595ae0d789207550e25204.png

  12. Thanks guys. I've updated to rc3. changed settings -> docker -> `Docker custom network type` to `ipvlan`.

     

    I've scrubbed the cache disk and the docker volume, no errors found.

     

    Hopefully that'll fix it.  I have had a few issues with macvlan in the past taking down the server.

     

    • Like 1
×
×
  • Create New...