JottaCloud Install Guide

Valantar

Dabbler
Joined
Apr 11, 2021
Messages
26
So I think I got it working properly :) Once again, thanks for a great guide. Worked perfectly even for a command line novice like myself!

One thing: to gain access to my data so that Jottacloud can actually back it up, I added my datasets as mount point for the jail under jotta/root/mnt. (Came across this in a guide for another, unrelated plugin.) Is this the right way to do this? And does this mean that the jail is accessing these datasets from the root user? If so, is there any reason to change this to another user with less privileges?

Also, my jotta-cli tells me there's an update available for it whenever I enter a command:
Code:
 A new version of Jotta Cli is available.
 Please update from 0.10.42740 to version 0.10.44059

 To update jotta-cli just download and install
 most recent build from

 https://repo.jotta.us/archives/freebsd/[ARCH]/

If I wanted to update this (I won't be doing this until my uploads are done, at the very least), how would I go about doing this? Is it as simple as re-running the installation but replacing 0.10.42740 with 0.10.44059 in this line?
Code:
cd / && wget https://repo.jotta.us/archives/freebsd/amd64/jotta-cli-0.10.42740_freebsd_amd64.tar.gz
 

gt2416

Patron
Joined
Feb 4, 2018
Messages
262
Great you got it working !
I think after you download the upgrade you only need to copy 2 files and adjust permission on them so

First delete the old jotta tar file, cd / && rm jotta-cli*.tar.gz
cd / && wget https://repo.jotta.us/archives/freebsd/amd64/jotta-cli-0.10.42740_freebsd_amd64.tar.gz
tar -xvf jotta-cli*.tar.gz
cp /usr/bin/jottad /usr/local/bin/
cp /usr/bin/jotta-cli /usr/local/bin/
chmod +x /usr/local/bin/jottad
chmod +x /usr/local/bin/jotta-cli

The way you mounted the files is correct, since Jotta is not writing any files only reading the files and pushing them to a server, running it as root should be fine.
 

Valantar

Dabbler
Joined
Apr 11, 2021
Messages
26
Unfortunately something seems to have broken. According to the Jottacloud account page the system was 'last seen' 3 days ago, which doesn't quite add up with it having uploaded ~2.5TB of data after being set up on Friday. Anyhow, I can't seem to get jottad running any more. I restarted the TrueNAS system yesterday, might that have messed something up? Otherwise I haven't touched the jail since setting it up, though there have been some configuration changes to the TrueNAS system.

On trying to start jottad, this happens:
Code:
root@jotta:/ # service jottad start
Starting jottad
root@jotta:/ # [16482] creating logger @ /usr/local/etc/jottad/jottabackup.log
Error parsing syslog info: section 'syslog' does not exist

jotta-cli status returns an error asking if the service is running. There is a 'syslog.d' in /etc/ though I have no idea if that is what it's looking for (what precisely does 'section' mean here? Is it missing a folder? File? Section within a file? Something else?).

Any idea what this might mean? I can't find any mention of it in the jottacloud online guides at least.

Edit: I'm thinking I've broken something in the configuration of the jail through changing the network settings and HTTPS settings of the NAS, though that's pure guesswork on my part. When entering the jail settings ("edit" from the jails list) I get the error
Code:
HTTPSConnectionPool(host='www.freebsd.org', port=443): Max retries exceeded with url: /security/unsupported.html (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 65] No route to host'))

Among things that have changed since I set up the jail, I've configured a static IP for the web interface locally (rather than from my router settings) and enabled HTTP-HTTPS redirecting (since disabled again) - both were done as I was having some weird issues connecting to the web UI, which were resolved by setting the static IP for the interface. The IP is the same as previously.
 
Last edited:

gt2416

Patron
Joined
Feb 4, 2018
Messages
262
I get the same error about syslog but everything works, whats the output of sockstat -4 ? You run that after you start the jotta service.
You can also use the command tail -f /usr/local/etc/jottad/jottabackup.log to see the latest time stamp of activity.
Also sometimes i get the same error using jotta-cli status, instaed I use jotta-cli observe the problem with that is that pressing cntr + c or q does not seem to quit the interface lol, so I got to close my cmd promt and re ssh into freenas.
 

Valantar

Dabbler
Joined
Apr 11, 2021
Messages
26
I get the same error about syslog but everything works, whats the output of sockstat -4 ? You run that after you start the jotta service.
You can also use the command tail -f /usr/local/etc/jottad/jottabackup.log to see the latest time stamp of activity.
Also sometimes i get the same error using jotta-cli status, instaed I use jotta-cli observe the problem with that is that pressing cntr + c or q does not seem to quit the interface lol, so I got to close my cmd promt and re ssh into freenas.
sockstat -4 returns what looks like a table with no entries:
Code:
root@jotta:~ # sockstat -4
USER     COMMAND    PID   FD PROTO  LOCAL ADDRESS         FOREIGN ADDRESS

For the record, when trying to start the jail I get the error "Error: [EFAULT] No default interface found", which is ... weird. The jail settings say it's configured to vnet0:bridge0, with the IP and default router being the same as the NAS is set to.

tail -f ... returns
Code:
pid:2221 2021/05/24 10:24:11 jottad.appdata     /usr/local/etc/jottad/settings.dat (1621797207|213)
pid:2221 2021/05/24 10:24:11 Daemon stopped
pid:16283 2021/05/24 10:29:07 Starting /usr/local/bin/jottad version 0.10.42740as 0(root)/0 (freebsd:amd64)
pid:16283 2021/05/24 10:29:07 listen tcp 127.0.0.1:14443: bind: can't assign requested address
pid:16290 2021/05/24 10:29:33 Starting /usr/local/bin/jottad version 0.10.42740as 0(root)/0 (freebsd:amd64)
pid:16290 2021/05/24 10:29:33 listen tcp 127.0.0.1:14443: bind: can't assign requested address
pid:16482 2021/05/24 10:37:25 Starting /usr/local/bin/jottad version 0.10.42740as 0(root)/0 (freebsd:amd64)
pid:16482 2021/05/24 10:37:25 listen tcp 127.0.0.1:14443: bind: can't assign requested address
pid:17067 2021/05/24 10:53:46 Starting /usr/local/bin/jottad version 0.10.42740as 0(root)/0 (freebsd:amd64)
pid:17067 2021/05/24 10:53:46 listen tcp 127.0.0.1:14443: bind: can't assign requested address

jotta-cli observe returns the same error as status.
 

gt2416

Patron
Joined
Feb 4, 2018
Messages
262
Seems like networking is broken in your jail.
Im not sure how to fix that right now as I am away from my server and accidently updated my pfsense remotely, now I dont have access to my network :/ Ill get back to you when I do.
 

Valantar

Dabbler
Joined
Apr 11, 2021
Messages
26
Seems like networking is broken in your jail.
Im not sure how to fix that right now as I am away from my server and accidently updated my pfsense remotely, now I dont have access to my network :/ Ill get back to you when I do.
No problem, I really appreciate the help! I was considering the nuclear option of just deleting the jail and starting over, but being able to fix it would both (potentially) teach me how to fix things in the future and avoid the work of setting everything up again.
 

Valantar

Dabbler
Joined
Apr 11, 2021
Messages
26
I finally got around to trying to fix this properly. I think the issue was that I had changed the network settings for my NAS (I had initially configured it with a static IP from my router rather than in TrueNAS, which led to all kinds of weird behaviour), which thanks to me not paying enough attention in turn left it without DNS settings. Derp. As is usually the case, PEBKAC. Of course I didn't figure this out until I had already deleted the jail, so I had to set it up again. But at least now I'm up to date! The client even recognized my NAS when logging in and prompted me if I wanted to resume backups to the same device in Jottacloud (despite generating a new login token and running in a brand new jail), which was nice.
 
Top