Table of Contents

List Of Terminal Commands

This page will explain how commands can be entered in the 'terminal'. First let's explain what the terminal is: A terminal is simply a text-based interface to the computer. In a terminal, you can type commands, manipulate files, execute programs, and open documents. When working in a terminal, the current directory is called your working directory. Some computers have different names for the 'terminal' such as 'terminator' which is an open-source terminal emulator programmed in Java. It is available on Microsoft Windows, macOS, Linux and other Unix systems that use the X Window System.

Below is a picture of a terminal with two different commands entered:

The first command entered was 'cd qortal'. This first command is used to access the 'qortal' directory so that we can enter commands related to the Qortal Core. Notice how the second line in blue shows:

~/qortal $

This means that we are within the 'qortal' directory.

The second command that was entered was:

./start.sh

This is the command to start the Qortal Core. Notice that the third is showing confirmation that java has been checked for running, and the fourth line 'qortal running as pid#####' shows that the Qortal Core is running. The fifth line is showing the previous commands have completed, and the terminal is ready for the next command (any time you see this format ending with the dollar sign will indicated that the next command is ready for entry).

Now that you have a basic understanding of how a terminal works, below are a list of commands that can be entered:

How To Start and Stop The Core

Please note: if you purchased a QORTector from www.crowetic.com or have built your own Pi that has Crowetic's auto-start script, your device starts the Qortal Core when the device is powered on. The system tray does not display the Qortal Core icon in this instance, but it will display the icon if you stop the core, then start the core again. For these types of users, we suggest reviewing the QORTector Walkthrough guide. For users running the standard Brooklyn images for the Pi, as well as Windows, Mac, and Linux users, the Qortal Core does NOT start automatically so you will need to do this manually:

To start the core: open Terminator and enter the following separately:

 cd qortal
./start.sh

It will then say 'qortal running as pid xxxxx. You can then close the Terminator. Below is a screenshot of the entire process:

You will then see the Qortal Core startup indication:

To stop the core: open Terminator and enter the following separately:

 cd qortal
./stop.sh

It will then say 'Qortal ended gracefully' in green. You can then close the Terminator. Below is a screenshot of the entire process:

To stop and start the core in one window: open Terminator and enter the following separately:

 cd qortal
./stop.sh
./start.sh

Below is a screenshot of the entire process:

You will then see the Qortal Core startup indication:

To Shutdown Or Reboot The Device

Please note: the Qortal Core needs to be stopped BEFORE you shutdown/reboot your computer! Otherwise the core may be 'corrupted' and require additional steps later. Be sure to: 1) stop the core, then 2) you may shutdown/reboot your computer. If your core is corrupted, you can follow the How To Update Qortal & .jar File or the 'How To Update The Core' section below.

To shutdown the device in the terminal (outside of the Qortal directory - by simply opening a new terminal window or you can always enter 'cd' to get out of the Qortal directory:

sudo shutdown

To reboot the device in terminal (outside of the Qortal directory - by simply opening a new terminal window or you can always enter 'cd' to get out of the Qortal directory:

sudo reboot

How To Update The Core

This will remove all the log files and download the newest version of the qortal.jar, enter this in a new terminal:

cd && cd qortal && .stop.sh && rm qortal.jar && curl -L -O https://github.com/Qortal/qortal/releases/latest/download/qortal.jar && ./start.sh

How To Update Core & Bootstrap In One Command

If you’d like, you can simply replace the core and db (to bootstrap) all in one command, in a new terminal A bootstrap is a download of a database that is updated every 12 hours so that you only have to sync the remaining blocks from the latest bootstrap creation. You will notice several 0-100% processes during the popup screen, then you will need to wait for it to finish synchronizing which will continue after the popup has closed:

 cd && cd qortal && ./stop.sh && rm qortal.jar && rm -R db && curl -L -O https://github.com/Qortal/qortal/releases/latest/download/qortal.jar && ./start.sh

How To Produce The Latest Log

The log can be used to review what is happening with the Core, especially by those who are more familiar with these logs and assisting you with tech support. This needs to be entered inside of the Qortal directory by entering 'cd qortal' (as seen below in the first command):

The command to produce the log is:

tail -f log.txt.*

You will then see the log within the terminal like this:

How To Check Node Status

cd qortal && ./qort admin/status