# Release v0.1.20 - Cassini Testnet

## Update Deadline:

Please ensure that the update is completed by <mark style="color:red;">**August 5, 2024, at 12:00 PM UTC**</mark> (8:00 PM Beijing Time). Failure to do so will result in your node being forcibly taken offline.



## Update Details:

• **Integration of Titan L1 Nodes with Containers:** The Titan L1 nodes have been successfully integrated with container functionality, significantly enhancing resource efficiency and system performance.

• **New Network Ports:** Please ensure the following ports are open in your network settings to enable proper node operation and communication:

• <mark style="color:red;">80 TCP</mark>: For HTTP communication. <mark style="color:red;">**\[New]**</mark>

• <mark style="color:red;">443 TCP</mark>: For HTTPS communication. <mark style="color:red;">**\[New]**</mark>

• 9000 TCP: For inter-node communication.

• 2345 TCP/UDP: For node broadcasting and data synchronization.

\


Please confirm that all these ports are open to ensure seamless node operation and connectivity. 🌐



## Update Guide

### [For New Nodes: Check here for detailed setup instructions.](../l1-node-operation-tutorial)



### For Upgrading Existing Nodes

<details>

<summary>Pre-Installation Steps: Install K3s</summary>

#### 1. Install K3s: <a href="#id-1.-an-zhuang-k3s" id="id-1.-an-zhuang-k3s"></a>

Run the following command in your terminal to install K3s. This step will automatically download and install K3s while disabling unnecessary components:

{% code overflow="wrap" %}
```bash
curl -sfL https://get.k3s.io | INSTALL_K3S_EXEC="--disable=traefik" sh -s -
```
{% endcode %}



#### 2.Configure kubeconfig: <a href="#id-2.-pei-zhi-kubeconfig" id="id-2.-pei-zhi-kubeconfig"></a>

Configure access for the kubectl command-line tool:

```bash
mkdir ~/.kube
sudo cat /etc/rancher/k3s/k3s.yaml | tee ~/.kube/config >/dev/null
```



#### 3.Verify K3s Installation: <a href="#id-3.-yan-zheng-k3s-an-zhuang-cheng-gong" id="id-3.-yan-zheng-k3s-an-zhuang-cheng-gong"></a>

After installation, use the following command to confirm that K3s is installed and running correctly:

```bash
kubectl get nodes
```



#### 4.Install Helm: <a href="#id-4.-an-zhuang-helm-gong-ju" id="id-4.-an-zhuang-helm-gong-ju"></a>

Helm is a tool for managing Kubernetes applications. Install Helm with the following commands:

```bash
wget https://get.helm.sh/helm-v3.11.0-linux-amd64.tar.gz
tar -zxvf helm-v3.11.0-linux-amd64.tar.gz
install linux-amd64/helm /usr/local/bin/helm
```



#### 5.Install Ingress Nginx: <a href="#id-5.-an-zhuang-ingress-nginx" id="id-5.-an-zhuang-ingress-nginx"></a>

Use Helm to install Ingress Nginx, which adds HTTP routing rules for applications:

```bash
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
helm upgrade --install ingress-nginx ingress-nginx \
  --repo https://kubernetes.github.io/ingress-nginx \
  --namespace ingress-nginx --create-namespace
```



#### 6.Use Mounted Disk /mnt/storage: <a href="#id-6.-shi-yong-gua-zai-pan-mntstorage" id="id-6.-shi-yong-gua-zai-pan-mntstorage"></a>

* Remove the default local-path StorageClass label:

{% code overflow="wrap" %}
```bash
kubectl patch storageclass local-path -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"false"}}}'
```
{% endcode %}

* Create and set a new storage class as default:

Create a storageclass.yaml file and include the following content:

```bash
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: local-storage
  annotations:
    storageclass.kubernetes.io/is-default-class: "true"
provisioner: rancher.io/local-path
volumeBindingMode: WaitForFirstConsumer
reclaimPolicy: Delete
parameters:
  path: "/mnt/storage"
```



Apply the StorageClass to the K3s cluster:

```bash
kubectl apply -f storageclass.yaml
```



Update the ConfigMap path to /mnt/storage:

{% code overflow="wrap" %}
```bash
kubectl patch configmap local-path-config -n kube-system --type=json -p='[{"op": "replace", "path": "/data/config.json", "value":"{\n  \"nodePathMap\":[\n  {\n    \"node\":\"DEFAULT_PATH_FOR_NON_LISTED_NODES\",\n    \"paths\":[\"/mnt/storage\"]\n  }\n  ]\n}"}]'
```
{% endcode %}



</details>

<details>

<summary>For Upgrading Existing Nodes</summary>

#### **1. Remove the old version**

Remove the old version before downloading the new version.

```bash
rm $(which titan-l1-guardian)
```

#### 2. Download the latest version

Visit the following url to download the latest version of Titan Guardian software:

{% code overflow="wrap" %}
```bash
https://github.com/Titannet-dao/titan-node/releases/download/v0.1.20/titan-l1-guardian
```
{% endcode %}

#### 3. Move to the system directory and update the permissions

Move it to the system directory and ensure it has proper permissions

```bash
mv titan-l1-guardian /usr/local/bin/
chmod 0755 /usr/local/bin/titan-l1-guardian
```

_Note: If you have set the proper execute permission, you may skip this step._

#### 4. Start the new version

Start the new software.&#x20;

**Important Notes:**

* <mark style="color:red;">**Restart the node**</mark>: The new settings will take effect after updating and restarting the node.
* <mark style="color:red;">**New Network Ports:**</mark>
  * 80 TCP: For HTTP communication.
  * 443 TCP: For HTTPS communication.

</details>



<mark style="color:red;">**Verify the upgrade**</mark>: Run the following command to confirm the update was successful:

```
titan-l1-guardian -v
```



<figure><img src="https://3087894035-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6MWUoQBijnrc0tNWtAzG%2Fuploads%2FodinDjrzCMbxVxop8GgB%2Fimage.png?alt=media&#x26;token=44a0d0e3-c10a-4657-9232-1e1654d44b61" alt=""><figcaption><p>If the version information appears as shown in the image, the upgrade has been successfully completed.✅</p></figcaption></figure>



