- Install checkra1n on your Ubuntu.
$ deb "https://assets.checkra.in/debian" / | sudo tee -a /etc/apt/sources.list
$ sudo apt-key adv --fetch-keys https://assets.checkra.in/debian/archive.key
$ sudo apt update
$ sudo apt install checkra1n
- Install some iPhone device drivers on your Ubuntu.
$ sudo apt-get install ideviceinstaller
$ sudo apt-get install python-imobiledevice
$ sudo apt-get install libimobiledevice-utils
$ sudo apt-get install python-plist
$ sudo apt-get install ifuse
$ sudo apt-get install usbmuxd
$ sudo apt-get install libusbmuxd-tools
- Run checkra1n
$ sudo checkra1n

For Command Mode:
$ sudo checkra1n -c -v
- Go Options and check "Safe mode".
- Hit "Start".
- Follow the instructions: Get into DFU mode.
- On DFU mode, checkra1n put a jailbreak code. The iPhone's screen shows checkra1n.
If it does not go well, try this.
e.g. USBMUX Error (error code: -79) or USB Error (error code: -77).
- Go to your iPhone.
- iPhone automatically reboots.
- You will find checkra1n on your home.
- Run Checkraln and install Cydia.
If you have an error of "unable to fetch bootstraps", which
means you don't have an internet connection. Try a VPN if you
are sure that you have an internet connection.