Bisq on TAILS - wiki needs updating

Hi all. I’ve successfully installed Bisq on TAILS, but I ran into a few minor issues along the way.

I want to update the wiki. There’s a link to log in, but no way to register. Am I able to get permission to update the wiki? Or can someone make the changes for me?

Essentially:

  • The command service onion-grater restart must be replaced with systemctl restart onion-grater.service

  • The command “mv ~/.local/share/Bisq/* /live/persistence/TailsData_unlocked/dotfiles/.local/share/Bisq” will fail. This can be fixed by running these two commands first:
    sudo mkdir -p /live/persistence/TailsData_unlocked/dotfiles/.local/share/Bisq
    sudo chown amnesia:amnesia /live/persistence/TailsData_unlocked/dotfiles/.local/share/Bisq

  • The use of “dotfiles” in TAILS can be confusing for newbies. It would be helpful to include a link to the TAILS documentation:
    Tails - Persistent Storage

  • The Bisq wiki says that user data only needs to be moved to the dotfiles after running it for the first time. However, if Bisq ever creates any NEW files, they will be lost on reboot unless they are also copied to the dotfiles.

(The persistent dotfiles directory in TAILS only creates links for files, not directories. Newly created files are not automatically made persistent just because they are part of Bisq’s directory structure.)

Example:

  1. User installs Bisq in Tails according to the wiki.
  2. User runs Bisq, waits for it to sync, exits, and copies user data to dotfiles.
  3. User reboots, runs Bisq and creates a wallet password.
  4. Bisq creates new wallet files in non-persistent home directory.
  5. User reboots, and finds that Bisq has lost all wallet data.

For that reason, I think it’s necessary to move user data to the dotfiles before rebooting EVERY time that Bisq has been used. This can be done by running the above mv command again. It will cause errors for files/links that already exist, which can be safely ignored:

mv /home/amnesia/.local/share/Bisq/* /live/persistence/TailsData_unlocked/dotfiles/.local/share/Bisq

Hope that helps someone.

1 Like

EDIT:

I forgot to post the link to the wiki page I’m talking about. Here it is:
https://bisq.wiki/Running_Bisq_on_Tails

Also, the mv command in the second-to-last line of my last post isn’t ideal. The following cp command is better as it only copies files that aren’t already symlinked in the user’s home directory (thus no errors):

cp -arnv /home/amnesia/.local/share/Bisq/. /live/persistence/TailsData_unlocked/dotfiles/.local/share/Bisq/

Attributes for cp command:
-a = archive. Do not follow links. Preserve timestamps, ownership, etc.
-r = recursive. Copy subdirectories and their contents too.
-n = no-clobber. Do not overwrite existing files (as they will already be using dotfile links).
-v = verbose. List any new files that were copied.

I had doubts about giving you access to the wiki or trying to prove the page myself. Since accessing the wiki could take too much time, I tried to do my best.
https://bisq.wiki/index.php?title=Running_Bisq_on_Tails&type=revision&diff=3047&oldid=2961

1 Like

Hi Mnm. I completely understand and thank you for for taking the time to update the wiki!

Can I suggest a few further changes?

==============

Fairly Important:

  • In the “Installation Script” section (right at the bottom of the page), the command service onion-grater restart also needs to be changed to systemctl restart onion-grater.service
  • The old “Existing User” section was correct. The options and locations used in the cp command I suggested don’t apply here. Could you swap that whole section out so it is exactly as it was before?

Very trivial:

  • In the contents, sections “6 Existing user” and “7 Installation Script” should probably be indented/renumbered as sub-sections 5.2 and 5.3.
  • In “Persistent Data Directory” > “New User” section, the sentence:
    “Create persistent file and change file ownership” could be changed to:
    “Create persistent directory and change directory ownership”
  • The two commands that immediately follow would look better separated with a line-break.

==============

One final suggestion (important to prevent data loss):

Whilst testing Bisq, I lost user data by forgetting to run the cp command to make Bisq’s user data persistent before reboot. It’s easy to do, and hardware/power failure would pose the same problem. A simple solution is to run cp in an endless loop whenever Bisq is running.

Let me think, and I’ll return with some text to copy/paste to keep your wiki edits quick and easy.

==============

I finally trusted Bisq enough to load the wallet with coins and make some trades, knowing my user data was safely being “persisted”. Bisq worked perfectly and I had no further issues.

Again, thanks for your efforts in updating the wiki. I will be recommending Bisq on TAILS to others, who will also really appreciate the wiki updates.

Back soon,

HeadsAndTails

Hi again. Sorry for the delay.

As I mentioned, Tails persistent “dotfiles” only links files, not folders. Bisq constantly creates new files in the default (amnesiac) data directory, which then have to be copied to the persistent dotfiles location. This defeats the purpose of using persistent “dotfiles”.

A better solution is to move Bisq’s data directory to a persistent (non-dotfile) location, then create a single directory symlink to it in Bisq’s default (amnesiac) data directory. Symlink creation can be automated in the installation script.


I made a copy of the wiki page source code, and edited it to include all my suggestions. I’ll post it separately below. I thought it’s the easiest way to explain everything?

I’m acting in good faith and just want to help “fix” the wiki. I’m happy to explain/discuss this further, or provide this information another way.

Let me know your thoughts.

Thanks,
HeadsAndTails

To '''run Bisq on the Tails OS''', a few manual steps are required.

__TOC__

== Preparations ==

* Configure an [https://tails.boum.org/doc/first_steps/welcome_screen/administration_password/ administration password]
* Configure [https://tails.boum.org/doc/first_steps/persistence/index.en.html persistence]

{{Admonition_Warn|Tails does not persist user data by default. Even with persistence enabled, '''all data in Bisq's default [[data directory]] will be erased as soon as you reboot'''. This means you will lose your Bisq keys, wallet data, and everything else.

To avoid data loss, make sure that persistence is enabled, and that Bisq user data is stored in a persistent directory before shutting down Tails.}}

== Download ==

After restarting Tails, go to https://github.com/bisq-network/bisq/releases using your Tor Browser and download the <code>Bisq-64bit-[version].deb</code> and <code>.asc</code> files.

You may have to use <code>wget</code>, because <code>curl</code> may not use Tor and could be blocked from using the internet.

=== Verify your download ===

* <code>wget <nowiki>https://bisq.network/pubkey/[keyid].asc</nowiki></code> should result in a file <code>[keyid].asc</code> in your working directory. See "Verification" section of [https://github.com/bisq-network/bisq/releases/latest release notes] for the exact key ID you should use (it's <code>29CDFD3B</code> as of this writing) to verify your download.
* Import the key to gpg by <code>gpg --import [keyid].asc</code>
* Check the signature with <code>gpg --digest-algo SHA256 --verify [yourbinaryhere]{.asc*,}</code> which should give you something like this:
<pre>
[snip]
gpg: Good signature from "Christoph Atteneder...
[snip]
</pre>

== Install ==

Do a simple <code>sudo dpkg -i [yourbinaryhere]</code>.

=== Configure ===

* Make authcookie readable:
<code>sudo chmod o+r /var/run/tor/control.authcookie</code>

* Configure <code>onion-grater</code>.

Create a file <code>/etc/onion-grater.d/bisq.yml</code> with contents:

<pre>
---
- apparmor-profiles:
    - '/opt/bisq/bin/Bisq'
  users:
    - 'amnesia'
  commands:
    AUTHCHALLENGE:
      - 'SAFECOOKIE .*'
    SETEVENTS:
      - 'CIRC WARN ERR'
      - 'CIRC ORCONN INFO NOTICE WARN ERR HS_DESC HS_DESC_CONTENT'
    GETINFO:
      - 'net/listeners/socks'
    ADD_ONION:
      - pattern:     'NEW:(\S+) Port=9999,(\S+)'
        replacement: 'NEW:{} Port=9999,{client-address}:{}'
      - pattern:     '(\S+):(\S+) Port=9999,(\S+)'
        replacement: '{}:{} Port=9999,{client-address}:{}'
    DEL_ONION:
      - '.+'
    HSFETCH:
      - '.+'
  events:
    CIRC:
      suppress: true
    ORCONN:
      suppress: true
    INFO:
      suppress: true
    NOTICE:
      suppress: true
    WARN:
      suppress: true
    ERR:
      suppress: true
    HS_DESC:
      response:
        - pattern:     '650 HS_DESC CREATED (\S+) (\S+) (\S+) \S+ (.+)'
          replacement: '650 HS_DESC CREATED {} {} {} redacted {}'
        - pattern:     '650 HS_DESC UPLOAD (\S+) (\S+) .*'
          replacement: '650 HS_DESC UPLOAD {} {} redacted redacted'
        - pattern:     '650 HS_DESC UPLOADED (\S+) (\S+) .+'
          replacement: '650 HS_DESC UPLOADED {} {} redacted'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH redacted redacted'
        - pattern:     '650 HS_DESC RECEIVED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC RECEIVED {} NO_AUTH redacted redacted'
        - pattern:     '.*'
          replacement: ''
    HS_DESC_CONTENT:
      suppress: true
</pre>

Then restart the <code>onion-grater</code> service with <code>sudo systemctl restart onion-grater.service</code>.

* In <code>/usr/share/applications/Bisq.desktop</code>, replace:

<code>Exec=/opt/bisq/bin/Bisq</code>

with:

<code>Exec=/opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth</code>

== Persistent Data Directory ==

Tails will delete all new files when shutting down, unless they are in a persistent storage location.

First, move the Bisq binary you downloaded to a persistent directory:

<code>mkdir /home/amnesia/Persistent/bisq/
mv /path/to/[yourbinaryhere] /home/amnesia/Persistent/bisq/</code>

Then, link Bisq's default [[data directory]] to a persistent data directory:

<code>mkdir /home/amnesia/Persistent/bisq/Bisq/
ln -s /home/amnesia/Persistent/bisq/Bisq /home/amnesia/.local/share/Bisq</code>

=== Existing user ===

To import user data from another Bisq installation or backup, copy it to the persistent data directory:

<code>cp -r /[yourdirectoryhere]/Bisq/* /home/amnesia/Persistent/bisq/Bisq/</code>

N.B. In this example, the correct path to your <code>btc_mainnet</code> directory should be:

<code>/home/amnesia/Persistent/bisq/Bisq/btc_mainnet</code>

== Run Bisq ==

Click <code>Applications</code> > <code>Internet</code> > <code>Bisq</code>.

Or via terminal:

<code>/opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth</code>

== Installation Script ==

Because Tails doesn't persist the Bisq installation [https://bisq.wiki/Running_Bisq_on_Tails#Install_Bisq] or configuration [https://bisq.wiki/Running_Bisq_on_Tails#Configure], they must be repeated after every restart. To make life easier, you can automate this in a bash script. Make sure the script is saved somewhere in the Tails persistent directory.

* Create script file:
<code>touch ~/Persistent/bisq/install-bisq.sh</code>
* Make script executable:
<code>chmod +x ~/Persistent/bisq/install-bisq.sh</code>
* Edit and save file: 
<pre>
#!/bin/bash

dpkg -i /home/amnesia/Persistent/bisq/[yourbinaryhere]
echo "Change access rights of /var/run/tor/control.authcookie ..."
chmod o+r /var/run/tor/control.authcookie
echo "Create /etc/onion-grater.d/bisq.yml ..."
echo "---
- apparmor-profiles:
    - '/opt/bisq/bin/Bisq'
  users:
    - 'amnesia'
  commands:
    AUTHCHALLENGE:
      - 'SAFECOOKIE .*'
    SETEVENTS:
      - 'CIRC WARN ERR'
      - 'CIRC ORCONN INFO NOTICE WARN ERR HS_DESC HS_DESC_CONTENT'
    GETINFO:
      - 'net/listeners/socks'
    ADD_ONION:
      - pattern:     'NEW:(\S+) Port=9999,(\S+)'
        replacement: 'NEW:{} Port=9999,{client-address}:{}'
      - pattern:     '(\S+):(\S+) Port=9999,(\S+)'
        replacement: '{}:{} Port=9999,{client-address}:{}'
    DEL_ONION:
      - '.+'
    HSFETCH:
      - '.+'
  events:
    CIRC:
      suppress: true
    ORCONN:
      suppress: true
    INFO:
      suppress: true
    NOTICE:
      suppress: true
    WARN:
      suppress: true
    ERR:
      suppress: true
    HS_DESC:
      response:
        - pattern:     '650 HS_DESC CREATED (\S+) (\S+) (\S+) \S+ (.+)'
          replacement: '650 HS_DESC CREATED {} {} {} redacted {}'
        - pattern:     '650 HS_DESC UPLOAD (\S+) (\S+) .*'
          replacement: '650 HS_DESC UPLOAD {} {} redacted redacted'
        - pattern:     '650 HS_DESC UPLOADED (\S+) (\S+) .+'
          replacement: '650 HS_DESC UPLOADED {} {} redacted'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH redacted redacted'
        - pattern:     '650 HS_DESC RECEIVED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC RECEIVED {} NO_AUTH redacted redacted'
        - pattern:     '.*'
          replacement: ''
    HS_DESC_CONTENT:
      suppress: true" > /etc/onion-grater.d/bisq.yml
echo "Restart onion-grater service ..."
systemctl restart onion-grater.service
echo "Edit Bisq executable file ..."
sed -i 's+Exec=/opt/bisq/bin/Bisq+Exec=/opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth+' /usr/share/applications/bisq-Bisq.desktop
ln -s /home/amnesia/Persistent/bisq/Bisq /home/amnesia/.local/share/Bisq
echo "Bisq installed successfully."
</pre>

Now you can run this script to install and configure Bisq after a Tails restart:
<code>sudo /home/amnesia/Persistent/bisq/install-bisq.sh</code>

[[Category:Guides]]

^^ The forum has applied some strange color formatting. But it has not altered the text I posted.

Thank you for your help, me and MnM briefly discussed this matter of updating the wiki; both of us do not have the resources to test it at this time, but I thought we could still add your edits to the wiki, presenting them as “alternative method” and giving credit to you. I will discuss this idea in our support chat.

1 Like

No problem, and thank you both too.

Listing my “alternative method” would be great. I can point my new users to that until you have time to fully verify/test it. :slight_smile:


If you’re going to keep the “original method”, could I suggest the fixes I mentioned in post 4:

  • In the “Installation Script” section (right at the bottom of the page), the command service onion-grater restart also needs to be changed to systemctl restart onion-grater.service
  • The old “Existing User” section (before MnM’s recent edit) was correct. Could you swap that whole section out so it is exactly as it was before?

Thanks again, and let me know if there’s anything else I can do/explain.

HeadsAndTails

You sound like a good fellow, I went out on a limb here and just published 100% of your edits:
https://bisq.wiki/Running_Bisq_on_Tails

1 Like

Amazing! I hope it helps someone out there.
Tails and Bisq work together perfectly like this. :slight_smile:


Just one last thing (I promise!) - the commands in the “Persistent Data Directory” section aren’t separated on new lines.

If you have the time/patience, it would be helpful to insert the two missing line breaks indicated by ** NEWLINE ** in the quote below:

First, move the Bisq binary you downloaded to a persistent directory:

mkdir /home/amnesia/Persistent/bisq/ **NEWLINE** mv /path/to/[yourbinaryhere] /home/amnesia/Persistent/bisq/

Then, link Bisq’s default data directory to a persistent data directory:

mkdir /home/amnesia/Persistent/bisq/Bisq/ **NEWLINE** ln -s /home/amnesia/Persistent/bisq/Bisq /home/amnesia/.local/share/Bisq

That’s all! Thanks again. :slight_smile:
HaT

right, code tags are sometimes pesky like that, it has been fixed

Sorry to bother you again.

Annoyingly, the latest versions of both Bisq AND Tails change some details in the wiki. So a few more updates are needed.

In short, I have rewritten the wiki from scratch. It’s EXACTLY the same technical method, which I FULLY stand by. But I believe I’ve explained the process better to make the wiki page easier to understand. And easier to maintain in future (which won’t be necessary unless Bisq or Tails change significantly).

I have tested my new version VERY thoroughly. (Except the markup tags, as I edited in plain text. I’m fairly sure they’re correct, but can’t check or see what the finished page looks like.)

I hope this is helpful, and that my improvements speak for themselves (they’re simple, nothing fancy). I’ll post separate messages below with my new wiki page, and details of the changes (which are fairly self-explanatory anyway).

I realise you’re busy, so let me know if I should contact someone else instead, or can do anything else to help.

Thanks for your time,
HaT

REQUIRED UPDATES:

I fixed one last typo:

  1. I missed out the “sh” after “sudo” on the command at the very bottom of the page. It should be:
    sudo sh /home/amnesia/Persistent/bisq/install-bisq.sh

Tails changes:

  1. Tails have renamed “Persistence” to “Persistent Storage” and broken the old documentation URLs. Persistent Storage can now be enabled from the Welcome Screen, and does not require a reboot. The “Persistent Folder” option must be enabled in the settings.
    OLD BROKEN URL: https://tails.boum.org/doc/first_steps/persistence/
    NEW WORKING URL: Tails - Persistent Storage

Bisq PGP key change:

  1. The latest version of Bisq is signed with a new PGP key. The “Verify your download” section refers to the old key. This section can be removed and replaced with a link to the “Downloading and installing” wiki page, which is actively maintained with up-to-date PGP information.

==========

READABILITY IMPROVEMENTS:

  1. Start the wiki with an “Overview” of how Persistent Storage will be used and the need for an installation script, so the rest of the wiki is more intuitive.

  2. The “Install” and “Run” sections will be undone when Tails reboots. They only exist to explain the “Installation Script”. A small note about the script and the new “Overview” section make them redundant.

  3. Give explicit examples to import/export user data. Warn that user data is not in Bisq’s default location. Warn not to mix user data (i.e. must only import/export to empty directory).

  4. Backups made from within the Bisq app use a folder prefixed “bisq_backup”. For consistency, use the same folder prefix in import/export examples.

  5. Add a step to connect to the Tor network BEFORE running the “Installation Script”. (Otherwise future attempts to connect to the Tor network will fail.)

  6. New “Upgrade Bisq…” section. Returning users can see at-a-glance how to upgrade Bisq without reading the whole wiki page.

==========

VERY MINOR CODE CHANGES:

Changes to cp (copy) commands:

  1. Add the -a (archive) attribute to preserve timestamps (for easier/sensible version control).

  2. Use the “dot directory” instead of asterisk glob (best practise to avoid issues with esoteric filenames?)
    (e.g. /dir1/. instead of /dir1/*)

Script changes:

  1. Use the following variables for the Bisq installer and data directories. This makes it really clear how to update the script to the latest Bisq version, or use non-default directories:

BisqInstaller=/home/amnesia/Persistent/bisq/[yourdownload.deb]
DataDirectory=/home/amnesia/Persistent/bisq/Bisq

  1. The message “Bisq installed successfully” appeared regardless of whether installation was successful. I changed this to “Installation complete”.
__TOC__

== Overview ==

Unlike most operating systems, [https://tails.boum.org/about/ Tails runs ''entirely'' in memory]. When Tails shuts down, memory contents are deleted, restoring the OS to its original state. Only files saved to the [https://tails.boum.org/doc/persistent_storage/ Persistent Storage] survive a reboot.

Therefore, Bisq must be reinstalled (and configured) after every boot. More importantly, Bisq's [[data directory|default data directory]] must be relocated to the '''Persistent Storage''' so that your wallet, keys, etc. are not lost every time Tails shuts down.

This is easy to automate with an installation script.

== Preparations ==

=== Configure Tails ===

On the Tails [https://tails.boum.org/doc/first_steps/welcome_screen/ Welcome Screen]:
* [https://tails.boum.org/doc/first_steps/welcome_screen/administration_password/ Set up an administration password].
* [https://tails.boum.org/doc/persistent_storage/create/ Create Persistent Storage].

Once Persistent Storage has been created, a settings window will open automatically. You can also open it from the desktop menu:  <code>Applications</code> > <code>Tails</code> > <code>Persistent Storage</code>.
* Enable the '''Persistent Folder''' in the above settings.

=== Configure the Persistent Folder ===

* Create a directory to store the Bisq installer (and installation script):
:<code>mkdir /home/amnesia/Persistent/bisq/</code>
* Create a '''persistent data directory''' for your Bisq user data:
:<code>mkdir /home/amnesia/Persistent/bisq/Bisq/</code>

==== Import user data from backup ====

{{Admonition_Warn|'''WARNING:''' Ensure that the [[#Configure_the_Persistent_Folder|persistent data directory] is EMPTY before importing. Do NOT mix user data from different sessions.}}

To import user data from a previous Bisq installation or backup, copy it into the [[#Configure_the_Persistent_Folder|persistent data directory]:
:<code>cp -ra /[backupdirectory]/bisq_backup_version001/. /home/amnesia/Persistent/bisq/Bisq/</code>

N.B. The correct path to your <code>btc_mainnet</code> directory should now be:
:<code>/home/amnesia/Persistent/bisq/Bisq/btc_mainnet</code>

=== Download Bisq ===

* [https://bisq.network/downloads/ Download] and [[Downloading_and_installing#Verify_installer_file|verify]] the Debian (.deb) version of the Bisq installer.
* Move the installer file to the [[#Configure_the_Persistent_Folder|Bisq installer directory]]:
:<code>mv /path/to/[yourdownload.deb] /home/amnesia/Persistent/bisq/</code>

=== Create installation script ===

'''NOTE:''' The script below will install Bisq, configure Tor, and redirect user data to the [[#Configure_the_Persistent_Folder|persistent data directory] (by creating a 'symbolic link'). Every step in the script is explained via 'echo' commands.

* Create a new script file:
:<code>touch /home/amnesia/Persistent/bisq/install-bisq.sh</code>
* Make the file executable:
:<code>chmod +x /home/amnesia/Persistent/bisq/install-bisq.sh</code>
* Edit the file, and save the script below.
* On the second line, replace [yourdownload.deb] with the filename of the [[#Download_Bisq|Bisq installer you downloaded]].

<pre>
#!/bin/bash
BisqInstaller=/home/amnesia/Persistent/bisq/[yourdownload.deb]
DataDirectory=/home/amnesia/Persistent/bisq/Bisq

echo "Install Bisq ..."
dpkg -i $BisqInstaller
echo "Change access rights of /var/run/tor/control.authcookie ..."
chmod o+r /var/run/tor/control.authcookie
echo "Create /etc/onion-grater.d/bisq.yml ..."
echo "---
- apparmor-profiles:
    - '/opt/bisq/bin/Bisq'
  users:
    - 'amnesia'
  commands:
    AUTHCHALLENGE:
      - 'SAFECOOKIE .*'
    SETEVENTS:
      - 'CIRC WARN ERR'
      - 'CIRC ORCONN INFO NOTICE WARN ERR HS_DESC HS_DESC_CONTENT'
    GETINFO:
      - 'net/listeners/socks'
    ADD_ONION:
      - pattern:     'NEW:(\S+) Port=9999,(\S+)'
        replacement: 'NEW:{} Port=9999,{client-address}:{}'
      - pattern:     '(\S+):(\S+) Port=9999,(\S+)'
        replacement: '{}:{} Port=9999,{client-address}:{}'
    DEL_ONION:
      - '.+'
    HSFETCH:
      - '.+'
  events:
    CIRC:
      suppress: true
    ORCONN:
      suppress: true
    INFO:
      suppress: true
    NOTICE:
      suppress: true
    WARN:
      suppress: true
    ERR:
      suppress: true
    HS_DESC:
      response:
        - pattern:     '650 HS_DESC CREATED (\S+) (\S+) (\S+) \S+ (.+)'
          replacement: '650 HS_DESC CREATED {} {} {} redacted {}'
        - pattern:     '650 HS_DESC UPLOAD (\S+) (\S+) .*'
          replacement: '650 HS_DESC UPLOAD {} {} redacted redacted'
        - pattern:     '650 HS_DESC UPLOADED (\S+) (\S+) .+'
          replacement: '650 HS_DESC UPLOADED {} {} redacted'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH'
        - pattern:     '650 HS_DESC REQUESTED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC REQUESTED {} NO_AUTH redacted redacted'
        - pattern:     '650 HS_DESC RECEIVED (\S+) NO_AUTH \S+ \S+'
          replacement: '650 HS_DESC RECEIVED {} NO_AUTH redacted redacted'
        - pattern:     '.*'
          replacement: ''
    HS_DESC_CONTENT:
      suppress: true" > /etc/onion-grater.d/bisq.yml
echo "Restart onion-grater service ..."
systemctl restart onion-grater.service
echo "Edit Bisq executable file ..."
sed -i 's+Exec=/opt/bisq/bin/Bisq+Exec=/opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth+' /usr/share/applications/bisq-Bisq.desktop
echo "Redirect user data to Tails Persistent Storage ..."
ln -s $DataDirectory /home/amnesia/.local/share/Bisq
echo "Installation complete."
</pre>

== Run Bisq ==

'''NOTE:''' Your user data is safely stored in the [[#Configure_the_Persistent_Folder|persistent data directory]]. However, the Bisq application is 'uninstalled' every time Tails shuts down.

To install Bisq:

* Connect to the Tor network, via the desktop menu:
:<code>Applications</code> > <code>Internet</code> > <code>Tor Connection</code>
* Run the [[#Create_installation_script|installation script]]:
:<code>sudo sh /home/amnesia/Persistent/bisq/install-bisq.sh</code>

Once Bisq has been installed, you can either start it from the desktop menu:
:<code>Applications</code> > <code>Internet</code> > <code>Bisq</code>
Or via terminal:
:<code>/opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth</code>

== Maintenance ==

=== Backup user data ===

==== While Bisq is running ====

You can [[Backing_up_application_data#While_Bisq_is_running|backup while Bisq is running]], as normal.

==== While Bisq is closed ====

You can also backup while Bisq is closed, by copying your user data to a backup location. However:

{{Admonition_Warn|'''REMEMBER:''' Your user data is stored in the [[#Configure_the_Persistent_Folder|persistent data directory]], and '''NOT''' Bisq's [[data directory|default data directory]].

'''WARNING:''' Only backup data into an EMPTY directory. Do NOT mix user data from different sessions.}}

To backup, first create a new (empty) directory for the backup, then copy the [[#Configure_the_Persistent_Folder|persistent data directory]]. For example:
:<code>mkdir /[backupdirectory]/bisq_backup_version001</code>
:<code>cp -ra /home/amnesia/Persistent/bisq/Bisq/. /[backupdirectory]/bisq_backup_version001</code>

=== Upgrade Bisq to the latest version ===

* [[#Download_Bisq|Download Bisq]] to <code>/home/amnesia/Persistent/bisq/</code>
* Update the <code>BisqInstaller=</code> line of the [[#Create_installation_script|installation script]] with the filename of the new version.

[[Category:Guides]]

The forum has added some strange bold and red formatting again, which can be ignored. The text itself posted correctly.

Hello @HeadsAndTails
w000000t is not following support anymore, but me and a few other agents have stepped in since then.

I have reviewed your previous exchange, and noticed how you were published already, so I went ahead and verified your source to the best of my knowledge (which is not stellar). It doesn’t look like anything malicious has been sneaked in (not that I suspected anything of the likes in the first place) and the rest of the commands “check out”, I believe that being bisq the open platform it is, if anyone else has any issues with the edits, they will come forward and notify me or anyone else from support.

Thank you very, very much for the time you spent to make our wiki better, Tails is not used by many I think, but those who do use it, will find your tutorial very useful.

I will proceed to update the wiki article momentarily.

Thanks @suddenwhipvapor :slight_smile:

I’m reassured to hear that you’ve checked for anything malicious! The edits I’ve made aren’t technical or complicated. And I’ve tested all the steps thoroughly, so I’m optimistic that no one will have any issues.

I know the new wiki page will help me when I forget how Bisq works on Tails. Hopefully it will help others too.

I’ll try to log in here occasionally, and am happy to answer any questions.

Thanks again,
HaT

1 Like

Hello @HeadsAndTails,
I too appreciate your contribution.
I have used the explanation and it worked a treat.
Until the last upgrade to tails 5.13 :roll_eyes:.
I think for one, the control port changed from 9051 to 9052 (I am a newbie, but from looking at the torrc I believe that was changed).
But even when using 9052 as the control port, I still get a connection refused exception.
Happy to help with any additional information or tests, and will appreciate any help/suggestions.

Cheers

Hi @Ishl,

Yes - after upgrading to Tails 5.13, Bisq no longer connects to Tor. Aaaaaaarrgg!

My previous wiki fixes only needed a basic understanding of Linux. Unfortunately I’m also a newbie when it comes to Tails/Tor network configuration. :frowning:

Thanks for reporting possible differences with torrc. I don’t have much spare time now, so can I quickly dump some newbie ideas below. I am investigating as time allows, but my experimenting is clutching at straws really. Sorry I can’t be more helpful.

If anyone has any more ideas or can find any useful documentation, please post below and maybe we can figure this out between us.

HaT

Q1. IS THIS AN ISSUE WITH THE TOR AUTHCOOKIE?

  • The Bisq installation script (on the wiki page) uses chmod to add read permissions to the file: /var/run/tor/control.authcookie

  • The command to run Bisq is:
    /opt/bisq/bin/Bisq --torControlPort 9051 --torControlCookieFile=/var/run/tor/control.authcookie --torControlUseSafeCookieAuth

Is there now some kind of issue with the authcookie or (as you suggest) the control port?

The Arch Linux wiki has possibly useful information:
https://wiki.archlinux.org/title/Tor#Set_a_Tor_Control_cookie_file

N.B. After making changes to torrc you will probably need to restart the Tor service with:
$ systemctl restart tor@default.service

I think a problem here is the most likely cause. But my quick experiments didn’t get me anywhere. :frowning:

Q2. IS A BISQ.YML CONFIG CHANGE NEEDED?

Q3. IS TAILS 5.13 MORE STRICT WHEN INSTALLING NON-REPO PACKAGES?

Bisq is installed via the dpkg command in the installation script.
The Tails wiki only explains how to install additional software using synaptic and apt. Apt is a frontend for dpkg, and Syanptic is a GUI frontend.

The link below, step 5 says that in Tails, Synaptic ‘calculates the additional changes for your package to work’: Tails - Installing additional software

I think this means dependencies. But is it possible that Synaptic/apt also run some additional Tor network configuration script, that dkpg does’t? If we create a dummy repo to install Bisq using Synaptic/apt, would it be automatically configured for Tor access?

Probably not, but I haven’t tried, or compared dkpg to apt.

Q4. CAN WE COLLECT ANY OTHER USEFUL DOCUMENTATION?

I can’t find any other useful documentation that could help us. Nothing below seems useful unless I missed something.

Tails v5.13 changelog:

Tails Additional software packages:
https://tails.boum.org/contribute/design/additional_software_packages/

Tails Tor network configuration:
https://tails.boum.org/contribute/design/Tor_network_configuration/

2 Likes