× NETGEAR will be terminating ReadyCLOUD service by July 1st, 2023. For more details click here.
Orbi WiFi 7 RBE973
Reply

Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

ChunkySocks
Guide

Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

Hi all,

I am attempting to install Syncthing on my RN212 but having a couple of issues. I have already posted about them in the Syncthing forum but have been advised that these aren't issues to do with Syncthing hence posting this thread here.

 

I previously had Syncthing installed on an older ReadyNAS Ultra 2 but had installed it with root priviliges which wasn't a wise thing to do so after migrating my date to this RN212 unit, I am attempting to do it properly.

 

So after setting up another user, I SSH’d into the ReadyNAS as that user and attempted the install using the instructions on the Debian / Ubuntu Packages page to see if it worked as the ReadyNAS OS (version 6.10.6) is apparently a modified version of Debian.

 

This is using the following commands:

# Add the release PGP keys:
sudo curl -s -o /usr/share/keyrings/syncthing-archive-keyring.gpg https://syncthing.net/release-key.gpg
# Add the "stable" channel to your APT sources:
echo "deb [signed-by=/usr/share/keyrings/syncthing-archive-keyring.gpg] https://apt.syncthing.net/ syncthing stable" | sudo tee /etc/apt/sources.list.d/syncthing.list
# Update and install syncthing:
sudo apt-get update
sudo apt-get install syncthing

however, I get two errors.

 

The first is a Server Certificate Verification Failed error, this eventuality is covered in the troubleshooting area and you are advised to run:

sudo apt-get update

sudo apt-get upgrade ca-certificates

 

to make sure you have the latest version of the ca-certificates package but that seems to result in a different error referencing the nfs-kernel-server.

 

Some more context from Terminal:

NewUser@NewNas:~$ sudo apt-get update
Hit:1 http://security.debian.org jessie/updates InRelease
Ign:2 http://mirrors.edge.kernel.org/debian jessie InRelease                   
Ign:3 https://apt.syncthing.net syncthing InRelease
Hit:4 http://mirrors.edge.kernel.org/debian jessie Release                     
Hit:5 https://apt.readynas.com/packages/readynasos 6.10.6 InRelease
Ign:7 https://apt.syncthing.net syncthing Release
Ign:8 https://apt.syncthing.net syncthing/stable armel Packages
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Ign:8 https://apt.syncthing.net syncthing/stable armel Packages
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Ign:8 https://apt.syncthing.net syncthing/stable armel Packages
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Ign:8 https://apt.syncthing.net syncthing/stable armel Packages
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Ign:8 https://apt.syncthing.net syncthing/stable armel Packages
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Err:8 https://apt.syncthing.net syncthing/stable armel Packages
  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
Ign:9 https://apt.syncthing.net syncthing/stable armhf Packages
Ign:10 https://apt.syncthing.net syncthing/stable all Packages
Reading package lists... Done
W: The repository 'https://apt.syncthing.net syncthing Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch https://apt.syncthing.net/dists/syncthing/stable/binary-armel/Packages  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
E: Some index files failed to download. They have been ignored, or old ones used instead.
NewUser@NewNas:~$ sudo apt-get install syncthing
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package syncthing
NewUser@NewNas:~$ sudo apt-get upgrade ca-certificates
Reading package lists... Done
Building dependency tree       
Reading state information... Done
ca-certificates is already the newest version (20141019+deb8u4).
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up nfs-kernel-server (1:1.2.8-9+deb8u1) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
update-rc.d: error: initscript does not exist: /etc/init.d/nfs-kernel-server
dpkg: error processing package nfs-kernel-server (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 nfs-kernel-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
NewUser@NewNas:~$ sudo dpkg --configure -a
Setting up nfs-kernel-server (1:1.2.8-9+deb8u1) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
update-rc.d: error: initscript does not exist: /etc/init.d/nfs-kernel-server
dpkg: error processing package nfs-kernel-server (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 nfs-kernel-server

On more investigation

The certificate issue. As per Debian / Ubuntu Packages:

Especially for older distributions, your system TLS certificate store might be outdated. Since October 2021, a newer Let’s Encrypt root certificate must be installed

So, from what I can gather I can’t update the certificate beyond 20141019+deb8u4 because the OpenSSL needs to be upgraded on the NAS? I found the following thread on the Let’s Encrypt website: Debian8 impact question

 

I’m not sure how to go about that.

 

I’m also not sure if the error with the nfs-kernel-server is related to the above, although I suspect it isn’t and I need to do something else to resolve that.

 

Thanks in advance for any assistance, advice or links to instructions that help.

 

Model: RN212|2 BAY Desktop ReadyNAS Storage
Message 1 of 9
Sandshark
Sensei

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)


@ChunkySocks wrote:

 

I previously had Syncthing installed on an older ReadyNAS Ultra 2 but had installed it with root priviliges which wasn't a wise thing to do so after migrating my date to this RN212 unit, I am attempting to do it properly.

 

Thanks in advance for any assistance, advice or links to instructions that help.

 


You actually did it in another completely "proper" way when you installed as root.  On the command you are using, the leading sudo temporarilly makes you root, so the end result is exactly the same.  So, you can try installing it again as root, though I don't really think that's your problem.

 

Since Netgear has failed to update the Linux core of ReadyNAS OS, updates of apps are becoming more and more difficult as the OS does not meet and cannot be updated to a required minimum version of a dependancy to the app.  There is a ReadyNAS specific version avaiolable for a very reasonable price at rnxtras.com/ .

Message 2 of 9
ChunkySocks
Guide

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

Thanks for replying.

 


@Sandshark wrote:

You actually did it in another completely "proper" way when you installed as root.  On the command you are using, the leading sudo temporarilly makes you root, so the end result is exactly the same.  So, you can try installing it again as root, though I don't really think that's your problem.

Not according to the installation. If you install as root you get this warning whenever you start up Syncthing:

Syncthing should not run as a privileged or system user. Please consider using a normal user account.

Hence my desire to do it "properly" this time. I also asked about the warning in a separate thread in the Syncthing support forums (Attempting to install & use Syncthing on a ReadyNAS) and was advised that the reason to not install as root was because:

There are many risks, we introduce a bug and wipe all your data, even in the system directories, bricking your machine. We introduce a bug in the protocol which allows an attacker to escape syncthing process and get a shell, a root shell in this case, etc, etc.

Someone pinged me from another thread there, where they had grabbed & installed Syncthing from Syncthing (R6x86) — RNXtras.com where it installed and runs as root, and included instructions on how to remedy that: HowTo: Syncthing on ReadyNas (not as root) 

 

but I didn't go along that route as I found this info on RNXtras.com:

I downloaded and installed the fix and then was able to install Syncthing successfully. The only additional step I had to perform was amending some file / folder permissions so my non-root user could run Syncthing.

 

Hope the above will help someone.

Thanks to RNExtras for providing the fix free of charge, I will sling a donation their way soon.

Message 3 of 9
Sandshark
Sensei

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)


@ChunkySocks wrote:

Thanks for replying.

 


@Sandshark wrote:

You actually did it in another completely "proper" way when you installed as root.  On the command you are using, the leading sudo temporarilly makes you root, so the end result is exactly the same.  So, you can try installing it again as root, though I don't really think that's your problem.

Not according to the installation. If you install as root you get this warning whenever you start up Syncthing:

Syncthing should not run as a privileged or system user. Please consider using a normal user account.

Nothing on a ReadyNAS will run under a "normal user account".  I stand by my statement.  This incorrect assumption by the author(s) may be a part of your problem.  On a ReadyNAS, the proper way to access SSH and install anything is as rootsudo isn't even installed by default.

Message 4 of 9
ChunkySocks
Guide

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

OK, thanks.
I've no skin in this, just relaying conflicting advice and not especially knowledgeable or skilled at using the CLI. Hence my questions and queries as I'm open to learning and for this to be helpful to anyone coming after who may wish to do the same.
Message 5 of 9
Sandshark
Sensei

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

Sorry if I came off sounding harsh (it seems that way to me, now that I re-read it).  I just wanted to let you know you are probably going down a rabbit hole looking for the problem there.

Message 6 of 9
ChunkySocks
Guide

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

Hey no worries, it's all good.
There's no problem since I managed to get it installed. The only (minor) issue is that I would like Syncthing to update itself automatically but that was easy enough to do manually.
Message 7 of 9
Sandshark
Sensei

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

If there was any secret sauce involved in getting it installed, please share it.

Message 8 of 9
ChunkySocks
Guide

Re: Trying to install Syncthing on ReadyNAS (Debian / Ubuntu packages)

No secret sauce, I wrote upthread how I managed to get it installed.

Message 9 of 9
Top Contributors
Discussion stats
  • 8 replies
  • 2826 views
  • 3 kudos
  • 2 in conversation
Announcements