Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Script fails in TrueNAS 12.2 #17

Open
calperin opened this issue Mar 20, 2022 · 7 comments
Open

Script fails in TrueNAS 12.2 #17

calperin opened this issue Mar 20, 2022 · 7 comments

Comments

@calperin
Copy link

After follow the procedure in a new TrueNAS 12.2 install, i get

root@truenas12[/truenas-plex/freenas-iocage-plex]# ./plex-jail.sh
Netmask not set, defaulting to /24 (255.255.255.0)
Plex metadata path not set, defaulting to /mnt/Data/plex_data
Plex media path not set, please mount media directory manually when done
Not configuring hardware transcode
Using stable-release plexmediaserver code
Creating jail pms. This may take a minute, please be patient.
pms successfully created!
No default gateway found for ipv6.

  • Starting pms
  • Stopping pms
    • Executing prestop OK
    • Stopping services OK
    • Tearing down VNET OK
    • Removing devfs_ruleset: 1000 OK
    • Removing jail process OK
    • Executing poststop OK
      Destroying pms

I have the plex-config

JAIL_IP="192.168.1.19"
DEFAULT_GW_IP="192.168.1.1"
POOL_PATH="/mnt/Data"

and ran the ./plex-jail.sh from the directory I created for the download from git

My server has different NICs (Total 8), and the IP is in the same subnet of my Default Gateway.

I believe that this should be related to the pkg install problem, but not sure since I don't know your script

@calperin
Copy link
Author

I 'm reading your script, and it is reporting for FreeNAS 11.x. It should work in TrueNAS 12?

@GJSchaller
Copy link

I am having a similar issue on TrueNAS 13:

Verifying signature with trusted certificate pkg.freebsd.org.2013102301... done
[pms] Installing pkg-1.17.5_1...
[pms] Extracting pkg-1.17.5_1: 100%
Updating FreeBSD repository catalogue...
pkg: http://pkg.freebsd.org/FreeBSD:13:amd64/latest/meta.txz: No address record
repository FreeBSD has no meta file, using default settings
pkg: http://pkg.freebsd.org/FreeBSD:13:amd64/latest/packagesite.pkg: No addressrecord
pkg: http://pkg.freebsd.org/FreeBSD:13:amd64/latest/packagesite.txz: No addressrecord
Unable to update repository FreeBSD
Error updating repositories!
Command: pkg install plexmediaserver failed!
Failed to install plexmediaserver package
* Stopping pms
  + Executing prestop OK
  + Stopping services OK
  + Tearing down VNET OK
  + Removing devfs_ruleset: 1004 OK
  + Removing jail process OK
  + Executing poststop OK
Destroying pms
root@TrueNAS[/mnt/data/scripts/freenas-iocage-plex]#

@danb35
Copy link
Owner

danb35 commented May 31, 2022

I either missed or overlooked the original issue, likely because there's no such thing as TrueNAS 12.2. But the problem, both in the OP and for @GJSchaller, is networking for the jail in question.

@GJSchaller
Copy link

My config is simple, and works for other Jails / scripts with the same network settings:

JAIL_IP="10.0.0.245"
DEFAULT_GW_IP="10.0.0.1"
POOL_PATH="/mnt/data"

@GJSchaller
Copy link

As a test, I created several Jails and tried to run "pkg install plex" on them.

Base jail, 13.1, hardcoded IP address - pkg would not install
Base jail, 13.1, using DHCP - pkg installed without issue
Clone jail, 13.1, using DHCP - pkg installed without issue

I'm guessing something about the jail creation is not picking up DNS?

@GJSchaller
Copy link

GJSchaller commented May 31, 2022

I tried modifying the script a bit - with the following changes, it successfully installs pkg, but then fails when updating the manifest. I'm trying to compare the script to other, working scripts (like Nextcloud) to see why one works, and one does not, if that will help clear things up.

JAIL_IP=""
JAIL_INTERFACES=""
DEFAULT_GW_IP=""
INTERFACE="vnet0"
VNET="on"
POOL_PATH=""
JAIL_NAME="plex"
USE_HW_TRANSCODE="0"
PLEX_CONFIG_PATH=""
PLEX_MEDIA_PATH=""
USE_BETA=0
# USE_BASEJAIL="-b"
PLEXPKG=""
HW_TRANSCODE_RULESET="10"
DEVFS_RULESET=""
RULESET_SCRIPT="/root/scripts/plex-ruleset.sh"

@GJSchaller
Copy link

OK, I tired adding some comments to the script to see where it failed. After doing this, the script ran, created the jail, and completed without error - I got the final message to browse to the IP and configure Plex. Once I browsed to the URL, I got the UI and was able to log into Plex. My modified script is attached, if that helps clear things up.

plex-jail.sh.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants