[HowTo] FreeNAS 11.1 + RancherOS + Docker + RancherUI + PLEX

countach1

Cadet
Joined
Oct 23, 2017
Messages
5
i found out my Problem with the certifigate was because of the https and the IP address.
But it went a bit furder but still errors

Code:
INFO: Running Agent Registration Process, CATTLE_URL=http://10.147.42.130:8080/v1
INFO: Attempting to connect to: http://10.147.42.130:8080/v1
INFO: http://10.147.42.130:8080/v1 is accessible
INFO: Inspecting host capabilities
INFO: Boot2Docker: false
INFO: Host writable: true
INFO: Token: xxxxxxxx
INFO: Running registration
Traceback (most recent call last):
  File "./register.py", line 11, in <module>
	secret_key=os.environ['CATTLE_REGISTRATION_SECRET_KEY'])
  File "/usr/local/lib/python2.7/dist-packages/cattle.py", line 45, in from_env
	return gdapi.from_env(prefix=prefix, factory=Client, **kw)
  File "/usr/local/lib/python2.7/dist-packages/gdapi.py", line 613, in from_env
	return _from_env(prefix=prefix, factory=factory, **args)
  File "/usr/local/lib/python2.7/dist-packages/gdapi.py", line 632, in _from_env
	return factory(**result)
  File "/usr/local/lib/python2.7/dist-packages/cattle.py", line 12, in __init__
	super(Client, self).__init__(*args, **kw)
  File "/usr/local/lib/python2.7/dist-packages/gdapi.py", line 197, in __init__
	self._load_schemas()
  File "/usr/local/lib/python2.7/dist-packages/gdapi.py", line 315, in _load_schemas
	response = self._get_response(self._url)
  File "/usr/local/lib/python2.7/dist-packages/gdapi.py", line 264, in _get_response
	headers=self._headers)
  File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 501, in get
	return self.request('GET', url, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 488, in request
	resp = self.send(prep, **send_kwargs)
  File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 609, in send
	r = adapter.send(request, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 497, in send
	raise SSLError(e, request=request)
requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)

I'm getting the previous certificate error as well. How did you get yours to this point? I did find this post on creating a self-signed certificate "Using Self Signed Certs(BETA)

http://rancher.com/docs/rancher/v1.5/en/installing-rancher/installing-server/basic-ssl-config/
 

Yusuf Limalia

Patron
Joined
Apr 5, 2016
Messages
234

afmiller

Contributor
Joined
Dec 11, 2013
Messages
106
So running into an issue with the mounts. They don't want to work it seems. Got the VM running. Going into the NAS then doing the

cu -l /dev/nmdm4B (number for my current VM)

the RancherOS / linux 4.9.75-rancher screen pops up. I've logged into it, and bound a NIC to 192.168.1.124. I've tried your set up with the mount.yaml and making it stick after reboot, but it doesn't seem to do it. I've done the df -h and its not showing the mount. myusername and mypassword are the same credentials I use to login via window SMB. I've added the .124 to the allowed list of the SMBs. For some reason I am unable to ping .119 (FreeNAS Box) but I can ping google DNS and my default gateway fine. The bound IP address shows up in the ifconfig. Below is what I've tried in the mount.yaml then "sudo ros config merge -i mount.yaml". I've tried :x like you said as well as :wq!.


(I have multiple mounts, but tried just one to get it working)
mounts:
- - //192.168.1.119/TV
- /media/tv
- cifs
- username=myusername,password=mypassword,iocharset=utf8,_netdev

Update --
I am unable to ping anything inside my network, only the gateway which I can ping any outside IP address. Also the user account I am using to connect to the SMB shares is in the group wheel on my FreeNAS box and I have no issue connecting via windows


Thanks again
 

Yusuf Limalia

Patron
Joined
Apr 5, 2016
Messages
234
So running into an issue with the mounts. They don't want to work it seems. Got the VM running. Going into the NAS then doing the

cu -l /dev/nmdm4B (number for my current VM)

the RancherOS / linux 4.9.75-rancher screen pops up. I've logged into it, and bound a NIC to 192.168.1.124. I've tried your set up with the mount.yaml and making it stick after reboot, but it doesn't seem to do it. I've done the df -h and its not showing the mount. myusername and mypassword are the same credentials I use to login via window SMB. I've added the .124 to the allowed list of the SMBs. For some reason I am unable to ping .119 (FreeNAS Box) but I can ping google DNS and my default gateway fine. The bound IP address shows up in the ifconfig. Below is what I've tried in the mount.yaml then "sudo ros config merge -i mount.yaml". I've tried :x like you said as well as :wq!.


(I have multiple mounts, but tried just one to get it working)
mounts:
- - //192.168.1.119/TV
- /media/tv
- cifs
- username=myusername,password=mypassword,iocharset=utf8,_netdev

Update --
I am unable to ping anything inside my network, only the gateway which I can ping any outside IP address. Also the user account I am using to connect to the SMB shares is in the group wheel on my FreeNAS box and I have no issue connecting via windows


Thanks again

Can you do an

Code:
ifconfig


From RancherOS and paste the output here.

Can you ping your RancherOS box from the outside?

Thanks!
 

afmiller

Contributor
Joined
Dec 11, 2013
Messages
106

mow4cash

Contributor
Joined
Jan 20, 2017
Messages
132
Has rancher been stable for everyone? I tried to upgrade nfs/rancher and it just spins saving. Sometimes the rancher gui is inaccessible other time github authentication doesn't go through. Sometimes trying to get to the rancher shell it says all ports busy and I have to restart the Freenas host for rancher to work again.
 

Spencer Skinner

Contributor
Joined
Dec 22, 2016
Messages
179
So running into an issue with the mounts. They don't want to work it seems. Got the VM running. Going into the NAS then doing the

cu -l /dev/nmdm4B (number for my current VM)

the RancherOS / linux 4.9.75-rancher screen pops up. I've logged into it, and bound a NIC to 192.168.1.124. I've tried your set up with the mount.yaml and making it stick after reboot, but it doesn't seem to do it. I've done the df -h and its not showing the mount. myusername and mypassword are the same credentials I use to login via window SMB. I've added the .124 to the allowed list of the SMBs. For some reason I am unable to ping .119 (FreeNAS Box) but I can ping google DNS and my default gateway fine. The bound IP address shows up in the ifconfig. Below is what I've tried in the mount.yaml then "sudo ros config merge -i mount.yaml". I've tried :x like you said as well as :wq!.


(I have multiple mounts, but tried just one to get it working)
mounts:
- - //192.168.1.119/TV
- /media/tv
- cifs
- username=myusername,password=mypassword,iocharset=utf8,_netdev

Update --
I am unable to ping anything inside my network, only the gateway which I can ping any outside IP address. Also the user account I am using to connect to the SMB shares is in the group wheel on my FreeNAS box and I have no issue connecting via windows


Thanks again

Also having an identical issue, the whole of docker and rancher seem to work fine asides the fact that they cant mount or ping anything inside the network

EDIT: I can ping the gateway and the FreeNAS Host but nothing else

EDIT2:I managed to get to get rancher to connect to one of my shares which doesnt require a username or password to access, might be an auth issue?
 
Last edited:

tommu

Cadet
Joined
Dec 29, 2017
Messages
4
If I remember correctly, vikozo was hitting the wrong IP address hence all the issues.

Can you access RancherUI without https?

This is not an access control or user error. Self signed certs are not accepted. To resolve go to:
ADMIN -> This Sites Address: and change it from https://x.x.x.x to http://x.x.x.x
**note that you are obviously not encrypting traffic any more - lab use only!**

Weird that some people experience this and some do not. Version?
 

DigitalDaz

Cadet
Joined
Sep 5, 2014
Messages
3
I actually came across this cert error myself the other day installing Rancher on bare metal. My understanding is that in later versions of Rancher they expect that traffic will first hit a load balancer and thats where the SSL cert would be installed.
 

ByerRA

Dabbler
Joined
Feb 27, 2016
Messages
16
First off I want to give a big thumbs up for this writeup, it really put a few missing pieces in place trying to get the Plex docker going.

Having said that...

Has anyone had any stability issues running the Plex docker?

Currently I still have Plex running in a jail and it runs perfect and I've had no issues with it though my Roku boxes (currently three in the house). It runs fast and the dashboards come up quick.

Running the Plex docker, when it starts, it's starts off running fast, better than the Plex jail, but then over time just slows down and eventually just locks up. And I really notice this when I have it scan my music library. I have a LOT of albums in FLAC format (all my music is in FLAC format) and so far I've had to stop and restart the container three times because it locks up scanning my music files.

(I'm NOT running the Plex jail and Plex docker at the same time, I usually stop the Plex jail when I'm playing with the Plex docker)

My system is large enough, it's a 3U 12-drive bay rack with a SuperMicro X8DT3-LN4F motherboard with two Intel Xeon E5620 CPU's, 81GB RAM (I have another 48GB of RAM arriving this week), 4 Seagate 8TB IronWolf drives on a reflashed IBM M1015 RAID card in IT mode and using onboard Intel 82576 GB network adapter. I'm running FreeNAS 11.1-U4

I've set the rancher VM to have 8 CPU's and 16GB of RAM as I'll be running other containers later besides just Plex (and will probably add more CPU cores to it)

I was able to scan my 416 1080P MKV movie files just fine without issue and was able to scan all my TV show MKV files (all are 480i MKV files) just fine and the memory usage for the plex container never rose above 3GB of used RAM. But if I start scanning all my FLAC music, the RAM usage shoots up to 11GB of RAM used (or more) and it starts locking up and when I check the log I see a lot of "Sqlite3: Sleeping for 200ms to retry busy DB" messages.

When I first setup the container, was getting the "sleeping for 200ms to retry busy DB" messages A LOT when I was scanning my movies and TV shows, but then I set the VM network adapter from "Intel e82545 (e1000)" to "VirtIO" and that seemed to help resolve A LOT of the issues and now I'm only getting the "retry busy DB" message when the memory usage on the container is high and I'm scanning my music files.

Normally when I'm running the Plex jail, I don't have any swap utilization, but when I run the Plex container in the FreeNAS memory reporting I'm showing 2.7G of swap being used. I've not done any "autotune" so FreeNAS is all baseline.

Back during the "FreeNAS Corral" days I was running the Plex docker and had no issue at all so I'm a little stumped here as when I can get the plex docker container stable, it runs like a beast and I've been able to have 5 1080P MKV files streaming without issues in very little memory.

I will also add, that I am using the "plexpass" docker container since I have a plex pass so I'm not sure if that could be an issue or not.

My media files are shared via SMB as I couldn't get NFS working and everything seems fine there, the Plex docker sees all the files just fine, no permission error messages anywhere.

Any help would be appreciated on this.
 

Kristi

Dabbler
Joined
Apr 20, 2016
Messages
10
Hi,
I try to mount the storage and have some error. anybody can help ?


[rancher@rancher ~]$ vi mount.yaml
[rancher@rancher ~]$ sudo ros config merge -i mount.yaml
ERRO[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
 

ByerRA

Dabbler
Joined
Feb 27, 2016
Messages
16
Hi,
I try to mount the storage and have some error. anybody can help ?


[rancher@rancher ~]$ vi mount.yaml
[rancher@rancher ~]$ sudo ros config merge -i mount.yaml
ERRO[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
What's your "mount.yaml" file look like?
 

ByerRA

Dabbler
Joined
Feb 27, 2016
Messages
16
mounts:
- - //192.168.1.10//Films
- /media/Films
- cifs
- username=plex,password=plexpassword,iocharset=utf8,_netdev
I think the issue is that you have a double "/" between "192.168.1.10" and "Films". It should be just "//192.168.1.10/Films"
 

Kristi

Dabbler
Joined
Apr 20, 2016
Messages
10
I think the issue is that you have a double "/" between "192.168.1.10" and "Films". It should be just "//192.168.1.10/Films"

Hi,
thanks, that was a mistake, but I get the same error even I corrected it ....

sudo ros config merge -i mount.yaml
ERRO[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
FATA[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
 

ByerRA

Dabbler
Joined
Feb 27, 2016
Messages
16
Hi,
thanks, that was a mistake, but I get the same error even I corrected it ....

sudo ros config merge -i mount.yaml
ERRO[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
FATA[0000] yaml: [while scanning a simple key] could not find expected ':' at line 4, column 1
Check the "/var/lib/rancher/conf/cloud-config.yml" file to see if the "mounts:" section looks correct as that's the config file where your "mount.yaml" is merged with.
 

ideal2545

Dabbler
Joined
Jun 1, 2015
Messages
25
I cannot for the life of me get an NFS mount to mount automatically, I've basically been feeding this in, and then rebooting, but it will not mount on boot, any ideas?

sudo ros config set mounts '[["FREENASIPADDR:/mnt/NAS/OnlyOffice","/mnt/OnlyOfficeDocumentServer","nfs4", ""]]'

I've verified that I can mount manually, just not on boot automatically, its showing up in the get mounts view also... :(
 

dir_d

Explorer
Joined
Nov 9, 2013
Messages
55
This guide helped me apply it to Sonarr and Radarr. For people reading this wondering the same thing, i would suggest like another user said, make a Stack 1st then add the containers as services. PS...Cloning does not work.
 

Kristi

Dabbler
Joined
Apr 20, 2016
Messages
10
Check the "/var/lib/rancher/conf/cloud-config.yml" file to see if the "mounts:" section looks correct as that's the config file where your "mount.yaml" is merged with.

Hi,
did it and now I see the same error after starting rancher:

[ ] ros-sysinit:error: Failed to parse config file /var/lib/rancher/conf/cloud-config.yml: yaml: [while scanning a simple key] could not find expected ':' at line 77, column 1
[ ] ros-sysinit:error: Failed to parse config file /var/lib/rancher/conf/cloud-config.yml: yaml: [while scanning a simple key] could not find expected ':' at line 77, column 1

when I type df -h i get a lot of thing and at the end this:
df: /var/lib/docker/containers/d1fc59afd718eb082a858544c0ae7e0a8373c8685da12348974641637c51a837/shm: Permission denied
df: /var/run/docker/netns/7bfee228337d: Permission denied
 

Kroode

Cadet
Joined
May 13, 2018
Messages
1
Hi,
did it and now I see the same error after starting rancher:

[ ] ros-sysinit:error: Failed to parse config file /var/lib/rancher/conf/cloud-config.yml: yaml: [while scanning a simple key] could not find expected ':' at line 77, column 1
[ ] ros-sysinit:error: Failed to parse config file /var/lib/rancher/conf/cloud-config.yml: yaml: [while scanning a simple key] could not find expected ':' at line 77, column 1

when I type df -h i get a lot of thing and at the end this:
df: /var/lib/docker/containers/d1fc59afd718eb082a858544c0ae7e0a8373c8685da12348974641637c51a837/shm: Permission denied
df: /var/run/docker/netns/7bfee228337d: Permission denied
I'm having the exact same issue. Has anyone experienced this and resolved it?
 
Top