• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting Cant see NAS drive

     
    • 0 Vote(s) - 0 Average

    Cant see NAS drive

    Unable to see Mounted NAS drive Raspberry PI4
    DAFFY
    Offline

    Junior Member

    Posts: 10
    Threads: 2
    Joined: 2024 Jan
    Reputation: 0
    Country:United Kingdom
    #14
    2024-01-25, 10:34 PM
    Code:
    #!/bin/bash

    set -o errexit

    if [[ $EUID -ne 0 ]]; then
      echo "This script must be run as root (use sudo)" 1>&2
      exit 1
    fi

    sudo apt-get install cifs-utils

    echo ""
    read -r -p "Enter the address of the NAS folder that you want to mount: " nasaddress
    echo ""
    read -r -p "Enter the local path where you want to mount the NAS folder: " localaddress
    echo ""
    read -r -p "Enter the path to store credentials file: " credentialaddress
    echo ""
    if [ ! -d $localaddress ]; then
        sudo mkdir -p $localaddress
    fi
    if [ ! -d $credentialaddress ]; then
        sudo mkdir -p $credentialaddress
    fi
    echo ""
    read -r -p "Enter the username of the NAS: " nasusername
    echo ""
    read -r -p "Enter the NAS password: " naspassword
    echo ""

    sudo tee -a $credentialaddress/.NASCREDS <<_EOF_
    username=$nasusername
    password=$naspassword
    _EOF_

    echo ""
    echo "$nasaddress  $localaddress  cifs  credentials=$credentialaddress/.NASCREDS,uid=1000,gid=1000,vers=1.0  0  01" >> /etc/fstab
    echo ""
    echo ""
    echo "@reboot root /bin/bash -c 'sleep 10 && /bin/mount -a'" >> /etc/crontab
    echo ""
    echo "All done............................."
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    Messages In This Thread
    Cant see NAS drive - by DAFFY - 2024-01-25, 08:52 PM
    RE: Cant see NAS drive - by TheDreadPirate - 2024-01-25, 08:57 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 09:02 PM
    RE: Cant see NAS drive - by TheDreadPirate - 2024-01-25, 09:05 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 09:07 PM
    RE: Cant see NAS drive - by TheDreadPirate - 2024-01-25, 09:10 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 09:13 PM
    RE: Cant see NAS drive - by TheDreadPirate - 2024-01-25, 09:22 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 09:26 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 09:40 PM
    RE: Cant see NAS drive - by tmsrxzar - 2024-01-25, 09:49 PM
    RE: Cant see NAS drive - by TheDreadPirate - 2024-01-25, 09:56 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 10:28 PM
    RE: Cant see NAS drive - by DAFFY - 2024-01-25, 10:34 PM

    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode