before changing links
This commit is contained in:
@ -0,0 +1,48 @@
|
||||
Bootable versus non-bootable volumes on CloudFerro Cloud[](#bootable-versus-non-bootable-volumes-on-brand-name "Permalink to this headline")
|
||||
=============================================================================================================================================
|
||||
|
||||
Each volume has an indicator called **bootable** which shows whether an operating system can be booted from it or not. That indicator can be set up manually at any time. If you set it up on a volume that does not contain a bootable operating system and later try to boot a VM from it, you will see an error as a response.
|
||||
|
||||
In this article we will
|
||||
|
||||
> * explain practical differences between **bootable** and **non-bootable** volumes and
|
||||
> * provide procedures in Horizon and OpenStack CLI to check whether the volume **bootable** or not.
|
||||
|
||||
Bootable vs. non-bootable volumes[](#bootable-vs-non-bootable-volumes "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------------------
|
||||
|
||||
Bootable and non-bootable volumes share the following similarities:
|
||||
|
||||
> * **Data storage**: both types can store data (regardless of being bootable or not)
|
||||
> * **Persistance**: they can be retained even if an instance is removed
|
||||
> * **Snapshots**: they allow you to create snapshots which represent state of a volume at a particular point in time.
|
||||
|
||||
From a snapshot, you can spawn additional volumes so volumes act as a means of both conserving data and transferring of the data.
|
||||
|
||||
Bootable volumes usually serve as a boot drive for a virtual machine while non-bootable volumes typically function as data storage only. Bootable volumes can also contain data but one part of capacity will be devoted to the operating system that they contain.
|
||||
|
||||
On the other hand, non-bootable volumes can
|
||||
|
||||
> * add more storage space to an instance (especially for applications which require lots of data) and
|
||||
> * separate data from the operating system to make backups and data management easier.
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Which volumes appear when creating a virtual machine using Horizon dashboard?
|
||||
> * Attempting to create a virtual machine from non-bootable volume using OpenStack CLI
|
||||
> * Checking whether a volume is bootable
|
||||
> * Checking whether a volume snapshot was created from a bootable volume
|
||||
> * Modifying bootable status of a volume
|
||||
> * What happens if you launch a virtual machine from a volume which does not have a functional operating system?
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Account**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with access to the Horizon interface: <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 **OpenStack CLI client operational**
|
||||
|
||||
We assume you are familiar with OpenStack CLI client. If not, here are some articles to get you started:
|
||||
@ -0,0 +1,10 @@
|
||||
Ephemeral vs Persistent storage option Create New Volume on CloudFerro Cloud[](#ephemeral-vs-persistent-storage-option-create-new-volume-on-brand-name "Permalink to this headline")
|
||||
=====================================================================================================================================================================================
|
||||
|
||||
Volumes created in the **Volumes > Volumes** section are *persistent* storage. They can be attached to a virtual machine and then reattached to a different one. They survive the removal of the virtual machine to which they are connected. You can also clone them, which is a simple way of creating a backup. However, if you copy them, you might also be interested in [Volume snapshot inheritance and its consequences on CloudFerro Cloud](Volume-snapshot-inheritance-and-its-consequences-on-CloudFerro-Cloud.html).
|
||||
|
||||
If you follow the instructions in this article: [VM created with option Create New Volume Yes on CloudFerro Cloud](../cloud/VM-created-with-option-Create-New-Volume-Yes-on-CloudFerro-Cloud.html) and set **Delete Volume on Instance Delete** to **No**, the boot drive of such virtual machine will also be persistent storage. You can, for example, use this feature to perform various tests and experiments.
|
||||
|
||||
If you do not need persistent storage, use *ephemeral* storage. It cannot be reattached to a different machine and will be removed if the machine is removed. See the article [VM created with option Create New Volume No on CloudFerro Cloud](../cloud/VM-created-with-option-Create-New-Volume-No-on-CloudFerro-Cloud.html) on how to create a virtual machine with this type of storage.
|
||||
|
||||
You may find more information regarding this topic in [the official OpenStack documentation on design storage concepts](https://docs.openstack.org/arch-design/design-storage/design-storage-concepts.html).
|
||||
@ -0,0 +1,146 @@
|
||||
How To Attach Volume To Windows VM On CloudFerro Cloud[](#how-to-attach-volume-to-windows-vm-on-brand-name "Permalink to this headline")
|
||||
=========================================================================================================================================
|
||||
|
||||
In this tutorial, you will attach a volume to your Windows virtual machine. It increases the storage available for your files.
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Creating a new volume
|
||||
> * Attaching the new volume to a VM
|
||||
> * Preparing the volume to use with a VM
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with Horizon interface <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 **Windows VM**
|
||||
|
||||
You must operate a Microsoft Windows virtual machine running on CloudFerro Cloud cloud. You can access it using the webconsole ([How to access the VM from OpenStack console on CloudFerro Cloud](../cloud/How-to-access-the-VM-from-OpenStack-console-on-CloudFerro-Cloud.html)) or through RDP. If you are using RDP, we strongly recommend using a bastion host for your security: [Connecting to a Windows VM via RDP through a Linux bastion host port forwarding on CloudFerro Cloud](../windows/Connecting-to-a-Windows-VM-via-RDP-through-a-Linux-bastion-host-port-forwarding-on-CloudFerro-Cloud.html).
|
||||
|
||||
Step 1: Create a New Volume[](#step-1-create-a-new-volume "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------
|
||||
|
||||
Login to the Horizon panel available at <https://horizon.cloudferro.com>.
|
||||
|
||||
Go to the section **Volumes -> Volumes**:
|
||||
|
||||

|
||||
|
||||
Click **Create Volume**.
|
||||
|
||||
The following window should appear:
|
||||
|
||||

|
||||
|
||||
In it provide the **Volume Name** of your choice.
|
||||
|
||||
Choose the **Type** of your volume - SSD or HDD.
|
||||
|
||||
Enter the size of your volume in gigabytes.
|
||||
|
||||
When you’re done, click **Create Volume**.
|
||||
|
||||
You should now see the volume you just created. In our case it is called **data**:
|
||||
|
||||

|
||||
|
||||
Step 2: Attach the Volume to VM[](#step-2-attach-the-volume-to-vm "Permalink to this headline")
|
||||
------------------------------------------------------------------------------------------------
|
||||
|
||||
Now that you have created your volume, you can use it as storage for one of your VMs. To do that, attach the volume to a VM.
|
||||
|
||||
Shut down your VM if it is running.
|
||||
|
||||
In the **Actions** menu for that volume select the option **Manage Attachments**:
|
||||
|
||||

|
||||
|
||||
You should now see the following window:
|
||||
|
||||

|
||||
|
||||
Select the virtual machine to which the volume should be attached from the drop-down menu **Attach to Instance** and click **Attach Volume**.
|
||||
|
||||
Your volume should now be attached to the virtual machine:
|
||||
|
||||

|
||||
|
||||
Step 3: Format the Drive[](#step-3-format-the-drive "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------
|
||||
|
||||
Start your VM and access it using RDP or the webconsole (see Prerequisite 2). Right-click the Start button and from the context menu select **Disk Management**. You should receive the following window:
|
||||
|
||||

|
||||
|
||||
In its lower section are the drives currently connected to your virtual machine:
|
||||
|
||||

|
||||
|
||||
In this case (on the screenshot above), there are two drives:
|
||||
|
||||
> * the system drive with 32 GB space
|
||||
> * the attached volume with 2 GB of unallocated space
|
||||
|
||||
Right-click the section of the window in which the label **Not Initialized** exists:
|
||||
|
||||

|
||||
|
||||
From the context menu select **Initialize Disk**. You should receive the following window:
|
||||
|
||||

|
||||
|
||||
In this window you are asked which partition style do you want to use: MBR or GPT. If your volume has 2 TB or less space and you intend to use 4 primary partitions or less, you can use MBR, but if your requirements are higher, you should use GPT.
|
||||
|
||||
Choose either of these options and click **OK**.
|
||||
|
||||
Right-click the **Unallocated** space:
|
||||
|
||||

|
||||
|
||||
Choose **New Simple Volume**.
|
||||
|
||||
You should receive the following window:
|
||||
|
||||

|
||||
|
||||
Click **Next >**. The following window should appear:
|
||||
|
||||

|
||||
|
||||
If you want your volume to have only one partition, leave the default value in the text field. Otherwise, enter the size of the first partition of your volume.
|
||||
|
||||
You can choose to either assign a drive letter to your drive or mount it in an empty folder.
|
||||
|
||||
* If you want to assign a drive letter to that volume, choose the **Assign the following drive letter:** radio button. From the drop-down menu to its right choose a letter to which you wish to attach your volume. Confirm your choice by clicking **OK**.
|
||||
* If you want to mount the volume to an NTFS folder on your drive, choose **Mount in the following empty NTFS folder:**. Click **Browse…** and in the **Browse for Drive Path** window choose an empty folder in which you wish to mount it. Confirm your choice by clicking **OK**.
|
||||
|
||||
The following window should now appear:
|
||||
|
||||

|
||||
|
||||
Here you can choose the formatting settings. Keep the radio button **Format this drive with the following settings:** selected. You can now enter the name which Windows will show for your new volume - it can be different then the one you typed in **Step 1**. Keep **Perform a quick format** checkbox selected. Click **Next >**. You should get the following window containing the summary of your chosen settings:
|
||||
|
||||

|
||||
|
||||
Click **Finish**.
|
||||
|
||||
Once the formatting process is complete, you should see appropriate information about your volume in the **Disk Management** window:
|
||||
|
||||

|
||||
|
||||
Your volume should now be mounted. If you chose to assign a drive letter, it should be visible in the **This PC** window:
|
||||
|
||||

|
||||
|
||||
If you want to create more partitions, repeat right-clicking the **Unallocated** space and completing the wizard as previously explained.
|
||||
|
||||
What To Do Next[](#what-to-do-next "Permalink to this headline")
|
||||
-----------------------------------------------------------------
|
||||
|
||||
Once you have gathered some data on your volume, you can create its backup, as explained in this article:
|
||||
|
||||
[How to Create Backup of Your Volume From Windows Machine on CloudFerro Cloud](How-To-Create-Backup-Of-Your-Volume-From-Windows-Machine-on-CloudFerro-Cloud.html)
|
||||
@ -0,0 +1,156 @@
|
||||
How to Create Backup of Your Volume From Windows Machine on CloudFerro Cloud[](#how-to-create-backup-of-your-volume-from-windows-machine-on-brand-name "Permalink to this headline")
|
||||
=====================================================================================================================================================================================
|
||||
|
||||
In this tutorial you will learn how create a backup of your volume on CloudFerro Cloud cloud. It allows you to save its state at a certain point in time and, for example, perform some experiments on it. You can then restore the volume to its previous state if you are unhappy with the results.
|
||||
|
||||
Those backups are stored using object storage. Restoring a backup will delete all data added to a volume after backup was created.
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Disconnecting the volume from a Windows virtual machine
|
||||
> * Creating a backup of a volume
|
||||
> * Restoring a backup of a volume
|
||||
> * Reattaching a volume to your Windows virtual machine
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Account**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with access to the Horizon interface: <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 **Windows VM**
|
||||
|
||||
You must operate a Microsoft Windows virtual machine running on CloudFerro Cloud cloud. You can access it using the webconsole ([How to access the VM from OpenStack console on CloudFerro Cloud](../cloud/How-to-access-the-VM-from-OpenStack-console-on-CloudFerro-Cloud.html)) or through RDP. If you are using RDP, we strongly recommend using a bastion host for your security: [Connecting to a Windows VM via RDP through a Linux bastion host port forwarding on CloudFerro Cloud](../windows/Connecting-to-a-Windows-VM-via-RDP-through-a-Linux-bastion-host-port-forwarding-on-CloudFerro-Cloud.html).
|
||||
|
||||
No. 3 **Volume**
|
||||
|
||||
A volume must be connected to your Windows virtual machine.
|
||||
|
||||
Disconnecting the volume from a virtual machine[](#disconnecting-the-volume-from-a-virtual-machine "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
Before creating a backup of your volume, disconnect it.
|
||||
|
||||
On your virtual machine, right-click the Start menu and select **Disk Management**.
|
||||
|
||||

|
||||
|
||||
A window similar to this should appear:
|
||||
|
||||

|
||||
|
||||
Right-click your attached volume and select **Change Drive Letter and Paths…**. The following window should appear:
|
||||
|
||||

|
||||
|
||||
Select the drive letter or mount point of your drive and click **Remove**.
|
||||
|
||||
Note
|
||||
|
||||
If you receive the following warning:
|
||||
|
||||

|
||||
|
||||
make sure that the removal does not break your workflow and click **Yes**.
|
||||
|
||||
Shut down the virtual machine and return to the Horizon dashboard: <https://horizon.cloudferro.com>
|
||||
|
||||
Go to **Volumes** > **Volumes**. You should see your volume there:
|
||||
|
||||

|
||||
|
||||
Select **Manage Attachments** from the drop-down menu in the **Actions** column for your volume:
|
||||
|
||||

|
||||
|
||||
The following window should appear:
|
||||
|
||||

|
||||
|
||||
Click **Detach Volume** and confirm your choice.
|
||||
|
||||
Creating a Backup of Your Volume[](#creating-a-backup-of-your-volume "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------------------
|
||||
|
||||
Now that you have detached the volume from your virtual machine, you can make its backup by following these steps:
|
||||
|
||||
> * Go to **Volumes** > **Volumes**.
|
||||
> * Choose **Create Backup** from the drop-down menu in the **Actions** column for your volume. You should get the following window:
|
||||
|
||||

|
||||
|
||||
* Enter the chosen name for your backup in the **Backup Name** text field. Optionally, you can provide its description in the **Description** text field. Once you’re ready, click **Create Volume Backup**.
|
||||
|
||||
Clicking **Create Volume Backup** initializes the process of backup creation and moves you to the **Volumes** > **Backups** section of the Horizon dashboard. There you should see that your backup is being created.
|
||||
|
||||
The time it takes to create the backup will vary.
|
||||
|
||||
Once the process is over, you should see the status **Available** next to your backup:
|
||||
|
||||

|
||||
|
||||
Restoring the backup[](#restoring-the-backup "Permalink to this headline")
|
||||
---------------------------------------------------------------------------
|
||||
|
||||
There are two ways of restoring a backup:
|
||||
|
||||
> * You can overwrite an existing volume with the content of the backup. This will delete all data that currently resides on that volume.
|
||||
> * You can create a new volume based on the content of the backup.
|
||||
|
||||
Go to **Volumes** > **Backups** section of the Horizon dashboard. In the **Actions** column of the appropriate backup, choose **Restore Backup**. The following window should appear:
|
||||
|
||||

|
||||
|
||||
Use **Select Volume** drop-down list to select the volume which your backup will replace. You can also create a new volume from that backup by choosing **Create a New Volume**.
|
||||
|
||||
In either case, click **Restore Backup to Volume**. This will initialize the process of restoring backup and move you to the **Volumes** > **Volumes** section of the Horizon dashboard.
|
||||
|
||||
Once this operation is completed, you should see the status **Available** next to your volume:
|
||||
|
||||

|
||||
|
||||
You can now reattach the volume to your virtual machine.
|
||||
|
||||
Reattaching the volume to your virtual machine[](#reattaching-the-volume-to-your-virtual-machine "Permalink to this headline")
|
||||
-------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
In the **Volumes** > **Volumes** section of the Horizon dashboard, find the row containing your volume. Choose **Manage Attachments** from the drop-down menu in the **Actions** column for it. You should get the following window:
|
||||
|
||||

|
||||
|
||||
From the drop-down menu **Attach To Instance** choose the name of the virtual machine to which the volume was previously attached. Click **Attach Volume**.
|
||||
|
||||
Attaching should take up to a few seconds. Once it is completed, you should see appropriate information in the **Attached To** column for your volume:
|
||||
|
||||

|
||||
|
||||
Go to **Compute** > **Instances**. Choose **Start Instance** in the row with the virtual machine to which the volume has just been attached. Login to your Windows VM using RDP or the webconsole (see Prerequisite No. 2).
|
||||
|
||||
On your virtual machine, right-click the Start menu and select **Disk Management**. You should receive the following window:
|
||||
|
||||

|
||||
|
||||
Note
|
||||
|
||||
If at the bottom of the screen you see status **Offline** next to your attached volume, right-click it and choose **Online** from the context menu.
|
||||
|
||||

|
||||
|
||||
Right-click your attached volume and select **Change Drive Letter and Paths…**. The window titled **Change Drive Letter and Paths for New Volume** should appear:
|
||||
|
||||

|
||||
|
||||
Click **Add…**. The following window should appear:
|
||||
|
||||

|
||||
|
||||
You can choose to either assign a drive letter to your drive or mount it in an empty folder.
|
||||
|
||||
* If you want to assign a drive letter to that volume, choose the **Assign the following drive letter:** radio button. From the drop-down menu to its right choose a letter to which you wish to attach your volume. Confirm your choice by clicking **OK**.
|
||||
* If you want to mount the volume to an NTFS folder on your drive, choose **Mount in the following empty NTFS folder:**. Click **Browse…** and in the **Browse for Drive Path** window choose an empty folder in which you wish to mount it. Confirm your choice by clicking **OK**.
|
||||
|
||||
Your volume should now be mounted. If you chose to assign a drive letter, it should be visible in the **This PC** window:
|
||||
|
||||

|
||||
@ -0,0 +1,4 @@
|
||||
How many objects can I put into Object Storage container bucket on CloudFerro Cloud[](#how-many-objects-can-i-put-into-object-storage-container-bucket-on-brand-name "Permalink to this headline")
|
||||
===================================================================================================================================================================================================
|
||||
|
||||
It is highly advisable to put no more than 1 million (1 000 000) objects into one bucket (container). Having more objects makes listing of them very inefficient. We suggest to create many buckets with a small amount of objects instead of a small amount of buckets with many objects.
|
||||
@ -0,0 +1,277 @@
|
||||
How to attach a volume to VM less than 2TB on Linux on CloudFerro Cloud[](#how-to-attach-a-volume-to-vm-less-than-2tb-on-linux-on-brand-name "Permalink to this headline")
|
||||
===========================================================================================================================================================================
|
||||
|
||||
In this tutorial, you will create a volume which is smaller than 2 TB. Then, you will attach it to a VM and format it in the appropriate way.
|
||||
|
||||
Note
|
||||
|
||||
If you want to create and attach a volume that has more than 2 TB of storage, you will need to use different software for its formatting. If this is the case, please visit the following article instead: [How to attach a volume to VM more than 2TB on Linux on CloudFerro Cloud](How-to-attach-a-volume-to-VM-more-than-2TB-on-Linux-on-CloudFerro-Cloud.html).
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Creating a new volume
|
||||
> * Attaching the new volume to a VM
|
||||
> * Formatting and mounting of the new volume
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with Horizon interface <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 Linux VM running on the CloudFerro Cloud cloud
|
||||
|
||||
Instructions for creating and accessing a Linux VM using default images can be found here:
|
||||
|
||||
[How to create a Linux VM and access it from Linux command line on CloudFerro Cloud](../cloud/How-to-create-a-Linux-VM-and-access-it-from-Linux-command-line-on-CloudFerro-Cloud.html)
|
||||
|
||||
or here:
|
||||
|
||||
[How to create a Linux VM and access it from Windows desktop on CloudFerro Cloud](../cloud/How-to-create-a-Linux-VM-and-access-it-from-Windows-desktop-on-CloudFerro-Cloud.html).
|
||||
|
||||
The instructions included in this article are designed for Ubuntu 22.04 LTS.
|
||||
|
||||
No. 3 **Basic knowledge of the Linux terminal**
|
||||
|
||||
You will need basic knowledge of the Linux command line.
|
||||
|
||||
No. 4 **SSH access to the VM**
|
||||
|
||||
[How to connect to your virtual machine via SSH in Linux on CloudFerro Cloud](../networking/How-to-connect-to-your-virtual-machine-via-SSH-in-Linux-on-CloudFerro-Cloud.html).
|
||||
|
||||
Step 1: Create a Volume[](#step-1-create-a-volume "Permalink to this headline")
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
Login to the Horizon panel available at <https://horizon.cloudferro.com>.
|
||||
|
||||
Go to the section **Volumes -> Volumes**:
|
||||
|
||||

|
||||
|
||||
Click **Create Volume**.
|
||||
|
||||
The following window should appear:
|
||||
|
||||

|
||||
|
||||
In it provide the **Volume Name** of your choice.
|
||||
|
||||
Choose the **Type** of your volume - SSD or HDD.
|
||||
|
||||
Enter the size of your volume in gigabytes.
|
||||
|
||||
When you’re done, click **Create Volume**.
|
||||
|
||||
You should now see the volume you just created. In our case it is called **volume-small**:
|
||||
|
||||

|
||||
|
||||
Step 2: Attach the Volume to VM[](#step-2-attach-the-volume-to-vm "Permalink to this headline")
|
||||
------------------------------------------------------------------------------------------------
|
||||
|
||||
Now that you have created your volume, you can use it as storage for one of your VMs. To do that, attach the volume to a VM.
|
||||
|
||||
In the **Actions** menu for that volume select the option **Manage Attachments**:
|
||||
|
||||

|
||||
|
||||
You should now see the following window:
|
||||
|
||||

|
||||
|
||||
Select the virtual machine to which the volume should be attached:
|
||||
|
||||

|
||||
|
||||
Click **Attach Volume**.
|
||||
|
||||
Your volume should now be attached to the VM:
|
||||
|
||||

|
||||
|
||||
Step 3: Partition the Volume[](#step-3-partition-the-volume "Permalink to this headline")
|
||||
------------------------------------------------------------------------------------------
|
||||
|
||||
It is time to access your virtual machine to prepare the volume for data storage.
|
||||
|
||||
Connect to your virtual machine using SSH or the web console.
|
||||
|
||||
Execute the following command to make sure that the volume has been attached:
|
||||
|
||||
```
|
||||
lsblk
|
||||
|
||||
```
|
||||
|
||||
You should see the output similar to this:
|
||||
|
||||

|
||||
|
||||
In this example, the attached volume that was previously called **volume-small** is represented by the device file **sdb**. Its size is 100 GB. Memorize the name of the *device file* representing the drive you attached or write it somewhere down - it will be needed later during starting **fdisk**.
|
||||
|
||||
In order to be able to use the volume as storage, you will need to use **fdisk** to create a partition table.
|
||||
|
||||
Start **fdisk** (replace **sdb** with the name of the device file provided to you previously by the **lsblk** command):
|
||||
|
||||
```
|
||||
sudo fdisk /dev/sdb
|
||||
|
||||
```
|
||||
|
||||
You should now see the following prompt:
|
||||
|
||||
```
|
||||
Command (m for help):
|
||||
|
||||
```
|
||||
|
||||
Answer with **n** and press Enter. A series of prompts similar to the ones below will appear on screen - keep pressing Enter on your keyboard to accept the default values.
|
||||
|
||||
```
|
||||
Partition type
|
||||
p primary (0 primary, 0 extended, 4 free)
|
||||
e extended (container for logical partitions)
|
||||
Select (default p):
|
||||
|
||||
Using default response p.
|
||||
Partition number (1-4, default 1):
|
||||
First sector (2048-209715199, default 2048):
|
||||
Last sector, +/-sectors or +/-size{K,M,G,T,P} (2048-209715199, default 209715199):
|
||||
|
||||
```
|
||||
|
||||
You should now see the confirmation similar to this:
|
||||
|
||||
```
|
||||
Created a new partition 1 of type 'Linux' and of size 100 GiB.
|
||||
|
||||
```
|
||||
|
||||
After it you will see the following prompt again:
|
||||
|
||||
```
|
||||
Command (m for help):
|
||||
|
||||
```
|
||||
|
||||
This time, answer with **w**. You will see the following message:
|
||||
|
||||
```
|
||||
The partition table has been altered.
|
||||
Calling ioctl() to re-read partition table.
|
||||
Syncing disks.
|
||||
|
||||
```
|
||||
|
||||
Execute the following command again to confirm that the partition was created successfully:
|
||||
|
||||
```
|
||||
lsblk
|
||||
|
||||
```
|
||||
|
||||
The device file of the new partition should have the same name as the device file of the drive followed by the **1** digit. In this case, it will be **sdb1**. Memorize or write it somewhere down - it will be needed later during creation of the file system.
|
||||
|
||||

|
||||
|
||||
Step 5: Create the File System[](#step-5-create-the-file-system "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------------
|
||||
|
||||
In order to save data on this volume, create **ext4** filesystem on it. **ext4** is arguably the most popular filesystem on Linux distributions.
|
||||
|
||||
It can be created by executing the following command:
|
||||
|
||||
```
|
||||
sudo mkfs.ext4 /dev/sdb1
|
||||
|
||||
```
|
||||
|
||||
Replace **sdb1** with the name of the device file of the partition provided to you previously by the **lsblk** command.
|
||||
|
||||
This process should take less than a minute.
|
||||
|
||||
Step 6: Create the mount point[](#step-6-create-the-mount-point "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------------
|
||||
|
||||
You need to specify the location in the directory structure from which you will access the data stored on that volume. In Linux it is typically done in the **/etc/fstab** config file.
|
||||
|
||||
Below are the instructions for the **nano** text editor. If you prefer to use different software, please modify them accordingly.
|
||||
|
||||
Install **nano** if you haven’t already:
|
||||
|
||||
```
|
||||
sudo apt install nano
|
||||
|
||||
```
|
||||
|
||||
Open the **/etc/fstab** file using **nano**:
|
||||
|
||||
```
|
||||
sudo nano /etc/fstab
|
||||
|
||||
```
|
||||
|
||||
Add the below line to the end of that file. Remember to replace **sdb1** with the name of the device file of your partition (it was provided to you previously be the **lsblk** command) and **/my\_volume** with the directory in which you want to mount it - the mounting point.
|
||||
|
||||
```
|
||||
/dev/sdb1 /my_volume ext4 defaults 0 1
|
||||
|
||||
```
|
||||
|
||||

|
||||
|
||||
To save that file in **nano**, use the following combination of keys: CTRL+X, Y, Enter.
|
||||
|
||||
Warning
|
||||
|
||||
Unless you know what you’re doing, you should not modify the lines which you already found in the **/etc/fstab** file. This file contains important information. Some or all of it might be required for the startup of the operating system.
|
||||
|
||||
Next, create a new or use an existing directory to use as your mounting point. If you need to create it anew, the command would be:
|
||||
|
||||
```
|
||||
sudo mkdir /my_volume
|
||||
|
||||
```
|
||||
|
||||
Mount the volume to your system (replace **/my\_volume** with your mount point):
|
||||
|
||||
```
|
||||
sudo mount /my_volume
|
||||
|
||||
```
|
||||
|
||||
To check whether it was successfully mounted, execute:
|
||||
|
||||
```
|
||||
df -h
|
||||
|
||||
```
|
||||
|
||||
The output should look like this:
|
||||
|
||||

|
||||
|
||||
The volume is owned by **root**, so **eouser** does not have access without **sudo**. To make it accessible to **eouser**, execute this command:
|
||||
|
||||
```
|
||||
sudo chown eouser:eouser /my_volume
|
||||
|
||||
```
|
||||
|
||||
If you want everybody to have access to that directory (and you don’t care about security at all), use the following command:
|
||||
|
||||
```
|
||||
sudo chmod 777 /my_volume
|
||||
|
||||
```
|
||||
|
||||
During the next boot of your virtual machine, the volume should be mounted automatically.
|
||||
|
||||
What To Do Next[](#what-to-do-next "Permalink to this headline")
|
||||
-----------------------------------------------------------------
|
||||
|
||||
You have successfully created a volume and prepared it for use on a Linux virtual machine.
|
||||
|
||||
You can now copy files to your new volume. If you want to move the data, attach the volume to a different machine.
|
||||
@ -0,0 +1,289 @@
|
||||
How to attach a volume to VM more than 2TB on Linux on CloudFerro Cloud[](#how-to-attach-a-volume-to-vm-more-than-2tb-on-linux-on-brand-name "Permalink to this headline")
|
||||
===========================================================================================================================================================================
|
||||
|
||||
In this tutorial, you will create a volume which is larger than 2 TB. Then, you will attach it to a VM and format it in the appropriate way.
|
||||
|
||||
Note
|
||||
|
||||
If you want to create and attach a volume that has less than 2 TB of storage, you will need to use different software for its formatting. If this is the case, please visit the following article instead: [How to attach a volume to VM less than 2TB on Linux on CloudFerro Cloud](How-to-attach-a-volume-to-VM-less-than-2TB-on-Linux-on-CloudFerro-Cloud.html).
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Creating a new volume
|
||||
> * Attaching the new volume to a VM
|
||||
> * Formatting and mounting of the new volume
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with Horizon interface <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 Linux VM running on CloudFerro Cloud cloud
|
||||
|
||||
Instructions for creating and accessing a Linux VM using default images can be found here:
|
||||
|
||||
[How to create a Linux VM and access it from Linux command line on CloudFerro Cloud](../cloud/How-to-create-a-Linux-VM-and-access-it-from-Linux-command-line-on-CloudFerro-Cloud.html) or here:
|
||||
|
||||
[How to create a Linux VM and access it from Windows desktop on CloudFerro Cloud](../cloud/How-to-create-a-Linux-VM-and-access-it-from-Windows-desktop-on-CloudFerro-Cloud.html).
|
||||
|
||||
The instructions included in this article are designed for Ubuntu 20.04 LTS.
|
||||
|
||||
No. 3 **Basic knowledge of the Linux terminal**
|
||||
|
||||
You will need basic knowledge of the Linux command line.
|
||||
|
||||
No. 4 **SSH access to the VM**
|
||||
|
||||
[How to connect to your virtual machine via SSH in Linux on CloudFerro Cloud](../networking/How-to-connect-to-your-virtual-machine-via-SSH-in-Linux-on-CloudFerro-Cloud.html).
|
||||
|
||||
Step 1: Create a Volume[](#step-1-create-a-volume "Permalink to this headline")
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
Login to the Horizon panel available at <https://horizon.cloudferro.com>.
|
||||
|
||||
Go to the section **Volumes -> Volumes**:
|
||||
|
||||

|
||||
|
||||
Click **Create Volume**.
|
||||
|
||||
The following window should appear:
|
||||
|
||||

|
||||
|
||||
In it provide the **Volume Name** of your choice.
|
||||
|
||||
Choose the **Type** of your volume - SSD or HDD.
|
||||
|
||||
Enter the size of your volume in gigabytes.
|
||||
|
||||
When you’re done, click **Create Volume**.
|
||||
|
||||
You should now see the volume you just created. In our case it is called **my-files**:
|
||||
|
||||

|
||||
|
||||
Step 2: Attach the Volume to VM[](#step-2-attach-the-volume-to-vm "Permalink to this headline")
|
||||
------------------------------------------------------------------------------------------------
|
||||
|
||||
Now that you have created your volume, you can use it as storage for one of your VMs. To do that, attach the volume to a VM.
|
||||
|
||||
In the **Actions** menu for that volume select the option **Manage Attachments**:
|
||||
|
||||

|
||||
|
||||
You should now see the following window:
|
||||
|
||||

|
||||
|
||||
Select the virtual machine to which the volume should be attached:
|
||||
|
||||

|
||||
|
||||
Click **Attach Volume**.
|
||||
|
||||
Your volume should now be attached to the VM:
|
||||
|
||||

|
||||
|
||||
Step 3: Create the Partition Table[](#step-3-create-the-partition-table "Permalink to this headline")
|
||||
------------------------------------------------------------------------------------------------------
|
||||
|
||||
It is time to access your virtual machine to prepare the volume for data storage.
|
||||
|
||||
Connect to your virtual machine using SSH or the web console.
|
||||
|
||||
Execute the following command to make sure that the volume has been attached:
|
||||
|
||||
```
|
||||
lsblk
|
||||
|
||||
```
|
||||
|
||||
You should see the output similar to this:
|
||||
|
||||

|
||||
|
||||
In this example, the attached volume that was previously called **my-files** is represented by the device file **sdb**. Its size is 2.4 TB. Memorize the name of the *device file* or write it somewhere down; it will be needed in the next step, which involves starting **gdisk**.
|
||||
|
||||
In order to be able to use the volume as storage, you will need to use **gdisk** to create a partition table. If you do not have this program, you can install it using the following command:
|
||||
|
||||
```
|
||||
sudo apt update && sudo apt upgrade && sudo apt install gdisk
|
||||
|
||||
```
|
||||
|
||||
Start **gdisk** (replace **sdb** with the name of the device file provided to you previously by the **lsblk** command):
|
||||
|
||||
```
|
||||
sudo gdisk /dev/sdb
|
||||
|
||||
```
|
||||
|
||||
You should see the output similar to this:
|
||||
|
||||
```
|
||||
GPT fdisk (gdisk) version 1.0.8
|
||||
|
||||
Partition table scan:
|
||||
MBR: not present
|
||||
BSD: not present
|
||||
APM: not present
|
||||
GPT: not present
|
||||
|
||||
Creating new GPT entries in memory.
|
||||
|
||||
Command (? for help):
|
||||
|
||||
```
|
||||
|
||||
Answer with **n** and press Enter. A series of prompts similar to the ones below will appear on screen - keep pressing Enter on your keyboard to accept the default values.
|
||||
|
||||
```
|
||||
Command (? for help): n
|
||||
Partition number (1-128, default 1):
|
||||
First sector (34-5033164766, default = 2048) or {+-}size{KMGTP}:
|
||||
Last sector (2048-5033164766, default = 5033164766) or {+-}size{KMGTP}:
|
||||
Current type is 8300 (Linux filesystem)
|
||||
Hex code or GUID (L to show codes, Enter = 8300):
|
||||
Changed type of partition to 'Linux filesystem'
|
||||
|
||||
```
|
||||
|
||||
You will see the prompt **Command (? for help):** again. Answer it with **w**. You will now see the following question:
|
||||
|
||||
```
|
||||
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING
|
||||
PARTITIONS!!
|
||||
|
||||
Do you want to proceed? (Y/N):
|
||||
|
||||
```
|
||||
|
||||
Answer with **Y** to confirm. You should get the following confirmation:
|
||||
|
||||
```
|
||||
OK; writing new GUID partition table (GPT) to /dev/sdb.
|
||||
|
||||
```
|
||||
|
||||
In the end, you should receive this message:
|
||||
|
||||
```
|
||||
The operation has completed successfully.
|
||||
|
||||
```
|
||||
|
||||
Execute the following command again to confirm that the partition was created successfully:
|
||||
|
||||
```
|
||||
lsblk
|
||||
|
||||
```
|
||||
|
||||
The device file of the new partition should have the same name as the device file of the drive followed by the **1** digit. In this case, it will be **sdb1**. Memorize or write it somewhere down - it will be needed later during creation of the file system.
|
||||
|
||||

|
||||
|
||||
Step 5: Create the File System[](#step-5-create-the-file-system "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------------
|
||||
|
||||
In order to save data on this volume, create **ext4** filesystem on it. **ext4** is arguably the most popular filesystem on Linux distributions.
|
||||
|
||||
It can be created by executing the following command:
|
||||
|
||||
```
|
||||
sudo mkfs.ext4 /dev/sdb1
|
||||
|
||||
```
|
||||
|
||||
Replace **sdb1** with the name of the device file of the partition provided to you previously by the **lsblk** command.
|
||||
|
||||
This process took less than a minute for a 2,4 terabyte volume.
|
||||
|
||||
Step 6: Create the mount point[](#step-6-create-the-mount-point "Permalink to this headline")
|
||||
----------------------------------------------------------------------------------------------
|
||||
|
||||
You need to specify the location in the directory structure from which you will access the data stored on that volume. In Linux it is typically done in the **/etc/fstab** config file.
|
||||
|
||||
Below are the instructions for the **nano** text editor. If you prefer to use different software, please modify them accordingly.
|
||||
|
||||
Before using **nano**, create the directory in which you wish to mount your volume - your mount point - (if it doesn’t exist yet). In this example, we will use the **/my\_volume** directory which can be created using the following command:
|
||||
|
||||
```
|
||||
sudo mkdir /my_volume
|
||||
|
||||
```
|
||||
|
||||
Install **nano** if you haven’t already:
|
||||
|
||||
```
|
||||
sudo apt install nano
|
||||
|
||||
```
|
||||
|
||||
Open the **/etc/fstab** file using **nano**:
|
||||
|
||||
```
|
||||
sudo nano /etc/fstab
|
||||
|
||||
```
|
||||
|
||||
Add the below line to the end of that file. Remember to replace **sdb1** with the name of the device file of your partition (it was provided to you previously be the **lsblk** command) and **/my\_volume** with the directory in which you want to mount it - the mounting point.
|
||||
|
||||
```
|
||||
/dev/sdb1 /my_volume ext4 defaults 0 1
|
||||
|
||||
```
|
||||
|
||||

|
||||
|
||||
To save that file in **nano**, use the following combination of keys: CTRL+X, Y, Enter.
|
||||
|
||||
Warning
|
||||
|
||||
Unless you know what you’re doing, you should not modify the lines which you already found in the **/etc/fstab** file. This file contains important information. Some or all of it might be required for the startup of the operating system.
|
||||
|
||||
Mount the volume to your system (replace **/my\_volume** with the mount point you previously created):
|
||||
|
||||
```
|
||||
sudo mount /my_volume
|
||||
|
||||
```
|
||||
|
||||
To check whether it was successfully mounted, execute:
|
||||
|
||||
```
|
||||
df -h
|
||||
|
||||
```
|
||||
|
||||
The output should contain the line with the device file representing your volume and its mount point. It can look like this:
|
||||
|
||||

|
||||
|
||||
The volume is owned by **root**, so **eouser** does not have access without **sudo**. To make it accessible to **eouser**, execute this command:
|
||||
|
||||
```
|
||||
sudo chown eouser:eouser /my_volume
|
||||
|
||||
```
|
||||
|
||||
If you want everybody to have access to that directory (and you don’t care about security at all), use the following command:
|
||||
|
||||
```
|
||||
sudo chmod 777 /my_volume
|
||||
|
||||
```
|
||||
|
||||
During the next boot of your virtual machine, the volume should be mounted automatically.
|
||||
|
||||
What To Do Next[](#what-to-do-next "Permalink to this headline")
|
||||
-----------------------------------------------------------------
|
||||
|
||||
You have successfully created a volume larger than 2 TB and prepared it for use on a Linux virtual machine.
|
||||
|
||||
You can now copy files to your new volume. If you want to move the data, attach the volume to a different machine.
|
||||
@ -0,0 +1,17 @@
|
||||
How to create or delete volume snapshot on CloudFerro Cloud[](#how-to-create-or-delete-volume-snapshot-on-brand-name "Permalink to this headline")
|
||||
===================================================================================================================================================
|
||||
|
||||
Volume snapshot allows you to save the state of volume at a specific point in time. Here is how to create or delete volume snapshot using Horizon dashboard or OpenStack CLI client.
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with access to Horizon interface: <https://horizon.cloudferro.com>
|
||||
|
||||
No. 2 **A volume**
|
||||
|
||||
You need to have the volume which will serve as a source of your volume snapshot.
|
||||
|
||||
To prevent data corruption while creating a snapshot, the volume should not be connected to a virtual machine. If it is, disconnect it from the volume using one of these articles:
|
||||
@ -0,0 +1,21 @@
|
||||
How to create volume Snapshot and attach as Volume on Linux or Windows on CloudFerro Cloud[](#how-to-create-volume-snapshot-and-attach-as-volume-on-linux-or-windows-on-brand-name "Permalink to this headline")
|
||||
=================================================================================================================================================================================================================
|
||||
|
||||
To create a snapshot of a Volume:
|
||||
|
||||
* Click Volumes tab in Horizon and choose “Create Snapshot” from dropdown menu.
|
||||
* Unmap disk in Windows VM, then in Horizon click on option “Manage Attachments” -> “Detach Volume”
|
||||
|
||||
It is possible to create snapshot of attached volume but if any data are writen on it while creating snapshot, it might result in corrupted volume.
|
||||
|
||||
* Convert snapshot into Volume - “Volume Snapshots” -> “Create Volume”.
|
||||
* Map new Volume in your Windows VM.
|
||||
|
||||
For Linux systems you may mount that newly created Volume and access the data, the filesystem is the same as on the original Volume.
|
||||
|
||||
For example, if the Volume has one partition and is attached as **/dev/vdc**, do
|
||||
|
||||
```
|
||||
sudo mkdir /my_snapshot1 && sudo mount /dev/vdc1 /my_snapshot1
|
||||
|
||||
```
|
||||
@ -0,0 +1,123 @@
|
||||
How to export a volume over NFS on CloudFerro Cloud[](#how-to-export-a-volume-over-nfs-on-brand-name "Permalink to this headline")
|
||||
===================================================================================================================================
|
||||
|
||||
**Server configuration**
|
||||
|
||||
Update your system:
|
||||
|
||||
```
|
||||
sudo apt update && apt upgrade
|
||||
|
||||
```
|
||||
|
||||
Install necessary packages:
|
||||
|
||||
```
|
||||
sudo apt install nfs-kernel-server
|
||||
|
||||
```
|
||||
|
||||
Create a new folder, which will be exported by NFS, e.g.:
|
||||
|
||||
```
|
||||
sudo mkdir -p /mnt/<name of your folder>
|
||||
|
||||
```
|
||||
|
||||
Delete all access restrictions in the folder:
|
||||
|
||||
```
|
||||
sudo chown -R nobody:nogroup /mnt/<name of your folder>/
|
||||
|
||||
```
|
||||
|
||||
You can also replace permisssions of files in the folder with your own preferences.
|
||||
|
||||
e.g.
|
||||
|
||||
```
|
||||
sudo chmod 777 /mnt/<name of your folder>/
|
||||
|
||||
```
|
||||
|
||||
**Defining access permisions to NFS Server.**
|
||||
|
||||
In the file /etc/exports add the following line:
|
||||
|
||||
```
|
||||
/mnt/<name of your folder> <IP address of allowed client>(rw,sync,no_subtree_check)
|
||||
|
||||
```
|
||||
|
||||
where <IP address> is the address of the server allowed to access the folder /mnt/<name of your folder>
|
||||
|
||||
e.g.
|
||||
|
||||
```
|
||||
# /etc/exports: the access control list for filesystems which may be exported
|
||||
|
||||
# to NFS clients. See exports(5).
|
||||
|
||||
#
|
||||
|
||||
# Example for NFSv2 and NFSv3:
|
||||
|
||||
# /srv/homes hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check)
|
||||
|
||||
#
|
||||
|
||||
# Example for NFSv4:
|
||||
|
||||
# /srv/nfs4 gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check)
|
||||
|
||||
# /srv/nfs4/homes gss/krb5i(rw,sync,no_subtree_check)
|
||||
|
||||
#
|
||||
|
||||
/mnt/<name of your folder> <IP address of NFS server>(rw,sync,no_subtree_check)
|
||||
|
||||
```
|
||||
|
||||
You can also share your folder to more IP addresses:
|
||||
|
||||
```
|
||||
/mnt/<name of your folder> <IP address 1>(rw,sync,no_subtree_check)
|
||||
/mnt/<name of your folder> <IP address 2>(rw,sync,no_subtree_check)
|
||||
/mnt/<name of your folder> <IP address 3>(rw,sync,no_subtree_check)
|
||||
|
||||
```
|
||||
|
||||
You can also share the folder to all servers in a Subnet (instead of adding every IP address separately) by adding following line to /etc/exports (e.g. servers in 192.168.0.0/24):
|
||||
|
||||
```
|
||||
/mnt/<name of your folder> 192.168.0.0/24(rw,sync,no_subtree_check)
|
||||
|
||||
```
|
||||
|
||||
When the configuration file /etc/exports is saved, invoke the following commands:
|
||||
|
||||
```
|
||||
sudo exportfs -a
|
||||
sudo systemctl restart nfs-kernel-server
|
||||
|
||||
```
|
||||
|
||||
**IT IS NECESSARY TO OPEN THE PORT 2049 IN A SECURITY GROUP!**
|
||||
|
||||
(The FAQ about opening ports in a security group is available at [How can I open new ports for http for my service or instance on CloudFerro Cloud](../networking/How-can-I-open-new-ports-port-80-for-http-for-my-service-or-instance-on-CloudFerro-Cloud.html))
|
||||
|
||||
**Client Configuration**
|
||||
|
||||
Install required packages:
|
||||
|
||||
```
|
||||
sudo apt install nfs-common
|
||||
|
||||
```
|
||||
|
||||
Mount the NFS folder:
|
||||
|
||||
```
|
||||
sudo mount <IP address of your NFS server>:/mnt/<name of your folder in NFS server> <name of your folder in Client>/
|
||||
|
||||
```
|
||||
@ -0,0 +1,101 @@
|
||||
How to export a volume over NFS outside of a project on CloudFerro Cloud[](#how-to-export-a-volume-over-nfs-outside-of-a-project-on-brand-name "Permalink to this headline")
|
||||
=============================================================================================================================================================================
|
||||
|
||||
**Prerequisites**
|
||||
|
||||
Two Ubuntu servers in various projects (not in a private network) which all have a floating IP assigned.
|
||||
|
||||
```
|
||||
Host: 64.225.128.1
|
||||
Client: 64.225.128.2
|
||||
|
||||
```
|
||||
|
||||
On both servers we will create a directory /xdata, which will be shared.
|
||||
|
||||
**On the host**
|
||||
|
||||
```
|
||||
eouser@host:~$ sudo apt-get update
|
||||
eouser@host:~$ sudo apt-get install nfs-kernel-server
|
||||
eouser@host:~$ sudo mkdir /xdata
|
||||
eouser@host:~$ sudo chown nobody:nogroup /xdata
|
||||
eouser@host:~$ sudo nano /etc/exports
|
||||
|
||||
```
|
||||
|
||||
Add the line:
|
||||
|
||||
```
|
||||
/xdata 64.225.128.2(rw,sync,no_subtree_check)
|
||||
|
||||
```
|
||||
|
||||
Save the file.
|
||||
|
||||
Start the server:
|
||||
|
||||
```
|
||||
eouser@host:~$ sudo systemctl restart nfs-kernel-server
|
||||
|
||||
```
|
||||
|
||||
For Ubuntu, start the server with this command:
|
||||
|
||||
```
|
||||
eouser@host:~$ sudo service nfs-kernel-server start
|
||||
|
||||
```
|
||||
|
||||
Now go to <https://horizon.cloudferro.com/project/security_groups/>
|
||||
|
||||
Create new security group.
|
||||
|
||||
Give it a name (eg. allow\_nfs) and save by clicking “Create security group” button.
|
||||
|
||||
Click “manage rules”.
|
||||
|
||||
Click “add rule”
|
||||
|
||||
Choose:
|
||||
|
||||
Rule: Custom TCP Rule
|
||||
|
||||
Direction: Ingress
|
||||
|
||||
Openport: Port
|
||||
|
||||
Port: 2049
|
||||
|
||||
Remote: CIDR
|
||||
|
||||
CIDR: 64.225.128.2
|
||||
|
||||
Click “Add”
|
||||
|
||||
Go to <https://horizon.cloudferro.com/project/instances/>
|
||||
|
||||
From the drop-down menu on the right of the “Host” instance, choose “Edit Security Groups”.
|
||||
|
||||
Click on the “plus” sign on the “allow\_nfs” group.
|
||||
|
||||
This will move the group from “All Security Groups” to “Instance Security Groups”.
|
||||
|
||||
Click “Save”.
|
||||
|
||||
**On the Client**
|
||||
|
||||
```
|
||||
eouser@client:~$ sudo apt-get update
|
||||
eouser@client:~$ sudo apt-get install nfs-common
|
||||
eouser@client:~$ sudo mkdir /xdata
|
||||
eouser@client:~$ sudo mount 64.225.128.1:/xdata /xdata
|
||||
|
||||
```
|
||||
|
||||
You can check if the directory is mounted:
|
||||
|
||||
```
|
||||
eouser@client:~$ df -h
|
||||
|
||||
```
|
||||
@ -0,0 +1,137 @@
|
||||
How to extend the volume in Linux on CloudFerro Cloud[](#how-to-extend-the-volume-in-linux-on-brand-name "Permalink to this headline")
|
||||
=======================================================================================================================================
|
||||
|
||||
It is possible to extend a Volume from the Horizon dashboard.
|
||||
|
||||
Another method is to create a new volume, attach it to a VM, copy all the data from the old volume to the new one, check if all the data is properly copied, then detach and delete the old one. Not all filesystems are resizable.
|
||||
|
||||
Warning
|
||||
|
||||
1. It is strongly recommended to backup the volume by creating Volume Snapshot before proceeding with extending the volume.
|
||||
|
||||
Warning
|
||||
|
||||
2. If you have a volume < 2TB and you want to extend it above 2TB, please do not follow below instructions. Instead please create a new volume, format it according to another article: [How to attach a volume to VM more than 2TB on Linux on CloudFerro Cloud](How-to-attach-a-volume-to-VM-more-than-2TB-on-Linux-on-CloudFerro-Cloud.html), attach it to the VM, copy the data from the old volume to the new one, check if it is fully copied, detach and delete the old volume.
|
||||
|
||||
You may use following guide to backup the volume: [How to create volume Snapshot and attach as Volume on Linux or Windows on CloudFerro Cloud](How-to-create-volume-Snapshot-and-attach-as-Volume-on-Linux-or-Windows-on-CloudFerro-Cloud.html)
|
||||
|
||||
**Resizing the volume:**
|
||||
|
||||
In this tutorial we will resize a 1GB volume to 5GB.
|
||||
|
||||
First we need to extend the volume in Horizon.
|
||||
|
||||
Let’s say that we have a 1GB volume attached to our instance as /dev/vdb:
|
||||
|
||||

|
||||
|
||||
And we have it mounted in our Linux machine as /dev/vdb1:
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ df -kh
|
||||
Filesystem Size Used Avail Use% Mounted on
|
||||
udev 1.9G 0 1.9G 0% /dev
|
||||
tmpfs 394M 640K 393M 1% /run
|
||||
/dev/vda1 15G 2.7G 12G 19% /
|
||||
tmpfs 2.0G 0 2.0G 0% /dev/shm
|
||||
tmpfs 5.0M 0 5.0M 0% /run/lock
|
||||
tmpfs 2.0G 0 2.0G 0% /sys/fs/cgroup
|
||||
tmpfs 394M 0 394M 0% /run/user/1001
|
||||
tmpfs 394M 0 394M 0% /run/user/1000
|
||||
/dev/vdb1 991M 2.6M 922M 1% /my_volume
|
||||
|
||||
```
|
||||
|
||||
We already have some data on it, we don’t want to lose.
|
||||
|
||||
First we need to unmount it in Linux:
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo umount /dev/vdb1
|
||||
|
||||
```
|
||||
|
||||
Then detach it in Horizon by clicking “Manage Attachments” > “Detach Volume”:
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
After detaching we will have the “Extend Volume” option available.
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
We enter a new size, for example 5GB and click “Extend Volume”:
|
||||
|
||||

|
||||
|
||||
Our new volume size is 5GB.
|
||||
Reattach it to your Virtual Machine again.
|
||||
Now we need to extend our /dev/vdb partition in Linux.
|
||||
|
||||
Expand the modified partition using **growpart** (and note the unusual syntax of separating the device name from the partition number):
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo growpart /dev/vdb 1
|
||||
CHANGED: partition=1 start=2048 old: size=2095104 end=2097152 new: size=10483679 end=10485727
|
||||
|
||||
```
|
||||
|
||||
Next use resize2fs:
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo resize2fs /dev/vdb1
|
||||
resize2fs 1.45.5 (07-Jan-2020)
|
||||
Please run 'e2fsck -f /dev/vdb1' first.
|
||||
|
||||
```
|
||||
|
||||
Most of the time a filesystem check will be recommended by the system.
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo e2fsck -f /dev/vdb1
|
||||
e2fsck 1.45.5 (07-Jan-2020)
|
||||
Pass 1: Checking inodes, blocks, and sizes
|
||||
Pass 2: Checking directory structure
|
||||
Pass 3: Checking directory connectivity
|
||||
Pass 4: Checking reference counts
|
||||
Pass 5: Checking group summary information
|
||||
/dev/vdb1: 11/65536 files (0.0% non-contiguous), 8859/261888 blocks
|
||||
|
||||
```
|
||||
|
||||
After doing e2fsck we proceed with extending partition:
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo resize2fs /dev/vdb1
|
||||
resize2fs 1.45.5 (07-Jan-2020)
|
||||
Resizing the filesystem on /dev/vdb1 to 1310459 (4k) blocks.
|
||||
The filesystem on /dev/vdb1 is now 1310459 (4k) blocks long.
|
||||
|
||||
```
|
||||
|
||||
We can now mount our extended volume again.
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo mount /dev/vdb1
|
||||
|
||||
```
|
||||
|
||||
```
|
||||
eouser@vm-john-01:~$ sudo df -kh
|
||||
Filesystem Size Used Avail Use% Mounted on
|
||||
udev 1.9G 0 1.9G 0% /dev
|
||||
tmpfs 394M 640K 393M 1% /run
|
||||
/dev/vda1 15G 2.7G 12G 19% /
|
||||
tmpfs 2.0G 0 2.0G 0% /dev/shm
|
||||
tmpfs 5.0M 0 5.0M 0% /run/lock
|
||||
tmpfs 2.0G 0 2.0G 0% /sys/fs/cgroup
|
||||
tmpfs 394M 0 394M 0% /run/user/1001
|
||||
tmpfs 394M 0 394M 0% /run/user/1000
|
||||
/dev/vdb1 5.0G 4.0M 4.7G 1% /my_volume
|
||||
|
||||
```
|
||||
|
||||
The new size is now 5GB and the data that was previously there is intact.
|
||||
@ -0,0 +1,75 @@
|
||||
How to mount object storage in Linux on CloudFerro Cloud[](#how-to-mount-object-storage-in-linux-on-brand-name "Permalink to this headline")
|
||||
=============================================================================================================================================
|
||||
|
||||
S3 is a protocol for storing and retrieving data on and from remote servers. The user has their own S3 account and is identified by a pair of identifiers, which are called Access Key and Secret Key. These keys act as a username and password for your S3 account.
|
||||
|
||||
Usually, for desktop computers we refer to files within a directory. In S3 terminology, file is called “object” and its name is called “key”. The S3 term for directory (or folder) is “bucket”. To mount object storage in your Linux computer, you will use command **s3fs**.
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
Prerequisite No. 1 **Hosting**
|
||||
|
||||
To use s3 protocol, you need a CloudFerro Cloud hosting account. It comes with graphical user interface called Horizon: <https://horizon.cloudferro.com> but you can also use s3 commands from terminal in various operating systems.
|
||||
|
||||
Prerequisite No. 2 **Valid EC2 credentials**
|
||||
|
||||
The Access Key and Secret Key for access to an s3 account are also called the “EC2 credentials”. See article
|
||||
|
||||
[How to generate and manage EC2 credentials on CloudFerro Cloud](../cloud/How-to-generate-ec2-credentials-on-CloudFerro-Cloud.html)
|
||||
|
||||
At this point, you should have access to the cloud environment, using the OpenStack CLI client. It means that the command **openstack** is operational.
|
||||
|
||||
Check your credentials and save them in a file[](#check-your-credentials-and-save-them-in-a-file "Permalink to this headline")
|
||||
-------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
Check your credentials with the following command:
|
||||
|
||||
```
|
||||
openstack ec2 credentials list
|
||||
|
||||
```
|
||||
|
||||
where Access token and Secret token will be used in s3fs configuration:
|
||||
|
||||
```
|
||||
echo Access_token:Secret_token > ~/.passwd-s3fs
|
||||
|
||||
```
|
||||
|
||||
That command will store the credentials into a file called *passwd-s3fs*. Since it starts with a dot, it will be invisible to the usual searches under Linux.
|
||||
|
||||
The file will be created in the present directory, but you can also create it anywhere else, for instance, in /etc/ folder and the like.
|
||||
|
||||
Change permissions of the newly created file
|
||||
|
||||
```
|
||||
chmod 600 .passwd-s3fs
|
||||
|
||||
```
|
||||
|
||||
Code **600** means you can read and write the file or directory but that none of the other users on the local host will have access to it.
|
||||
|
||||
Enable 3fs[](#enable-3fs "Permalink to this headline")
|
||||
-------------------------------------------------------
|
||||
|
||||
Uncomment “user\_allow\_other” in *fuse.conf* file as root
|
||||
|
||||
```
|
||||
sudo nano /etc/fuse.conf
|
||||
|
||||
```
|
||||
|
||||
Now you are ready to mount your object storage to your Linux system. The command looks like:
|
||||
|
||||
```
|
||||
s3fs w-container-1 /local/mount/point - passwd_file=~/.passwd-s3fs -o url=https://s3.waw3-1.cloudferro.com -o use_path_request_style -o umask=0002 -o allow_other
|
||||
|
||||
```
|
||||
|
||||
What To Do Next[](#what-to-do-next "Permalink to this headline")
|
||||
-----------------------------------------------------------------
|
||||
|
||||
If you want to access s3 files without mounting to the local computer, use command **s3cmd**.
|
||||
|
||||
[How to access private object storage using S3cmd or boto3 on CloudFerro Cloud](../s3/How-to-access-private-object-storage-using-S3cmd-or-boto3-on-CloudFerro-Cloud.html)
|
||||
@ -0,0 +1,47 @@
|
||||
How to move data volume between two VMs using OpenStack Horizon on CloudFerro Cloud[](#how-to-move-data-volume-between-two-vms-using-openstack-horizon-on-brand-name "Permalink to this headline")
|
||||
===================================================================================================================================================================================================
|
||||
|
||||
Volumes are used to store data and those data can be accessed from a virtual machine to which the volume is attached. To access data stored on a volume from another virtual machine, you need to disconnect that volume from virtual machine to which it is currently connected, and connect it to another instance.
|
||||
|
||||
This article uses the Horizon dashboard to transfer volumes between virtual machines which are in the same project.
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with Horizon interface <https://horizon.cloudferro.com>.
|
||||
|
||||
No. 2 **Source virtual machine and volume**
|
||||
|
||||
We assume that you have a virtual machine (which we will call *source* virtual machine) to which a volume is attached.
|
||||
|
||||
No. 3 **Destination virtual machine**
|
||||
|
||||
We also assume that you want to access the data stored on volume mentioned in Prerequisite No. 2 from another instance which is in the same project - we will call that instance *destination* virtual machine.
|
||||
|
||||
What We Are Going To Cover[](#what-we-are-going-to-cover "Permalink to this headline")
|
||||
---------------------------------------------------------------------------------------
|
||||
|
||||
> * Ensure that the transfer is possible
|
||||
>
|
||||
> + Projects must be on the same cloud
|
||||
> + Volume cannot be used for booting an operating system
|
||||
> + File system compatibility
|
||||
> + Making sure that the source virtual machine does not try to access the volume
|
||||
> + Other volume and instance conditions for successful transfer
|
||||
> * Shutting down the source virtual machine
|
||||
> * Shutting down the source virtual machine using Horizon dashboard
|
||||
> * Disconnecting volume
|
||||
> * Attaching volume to destination virtual machine
|
||||
|
||||
Some parts of some screenshots in this article are greyed out for privacy reasons.
|
||||
|
||||
Ensure that the transfer is possible[](#ensure-that-the-transfer-is-possible "Permalink to this headline")
|
||||
-----------------------------------------------------------------------------------------------------------
|
||||
|
||||
Before the actual transfer, you have to examine the state of the volume and of the instances and conclude whether the transfer is possible right away or should you perform other operations first:
|
||||
|
||||
### Projects must be on the same cloud[](#projects-must-be-on-the-same-cloud "Permalink to this headline")
|
||||
|
||||
If the projects are not on the same cloud, do not use this article but see one of these articles instead:
|
||||
@ -0,0 +1,21 @@
|
||||
How to restore volume from snapshot on CloudFerro Cloud[](#how-to-restore-volume-from-snapshot-on-brand-name "Permalink to this headline")
|
||||
===========================================================================================================================================
|
||||
|
||||
In this article, you will learn how to restore volume from volume snapshot using Horizon dashboard or OpenStack CLI client.
|
||||
|
||||
This can be achieved by creating a new volume from existing snapshot. You can then delete the previous snapshot and, optionally, previous volume.
|
||||
|
||||
Prerequisites[](#prerequisites "Permalink to this headline")
|
||||
-------------------------------------------------------------
|
||||
|
||||
No. 1 **Hosting**
|
||||
|
||||
You need a CloudFerro Cloud hosting account with access to Horizon interface: <https://horizon.cloudferro.com>
|
||||
|
||||
No. 2 **A volume snapshot**
|
||||
|
||||
You need to have a volume snapshot which you want to restore.
|
||||
|
||||
No. 3 **OpenStack CLI client**
|
||||
|
||||
If you want to interact with CloudFerro Cloud cloud using the OpenStack CLI client, you need to have it installed. Check one of these articles:
|
||||
@ -0,0 +1,36 @@
|
||||
Volume snapshot inheritance and its consequences on CloudFerro Cloud[](#volume-snapshot-inheritance-and-its-consequences-on-brand-name "Permalink to this headline")
|
||||
=====================================================================================================================================================================
|
||||
|
||||
Performing a volume snapshot is a common form of securing your data against loss.
|
||||
There is nothing wrong with that, but you should remember what the consequences are.
|
||||
|
||||
To illustrate the situation, we will present it on an example:
|
||||
We have created a volume called “Volume A”.
|
||||
|
||||

|
||||
|
||||
Next we create an “SA” snapshot from the “VA” volume.
|
||||
|
||||

|
||||
|
||||
From the OpenStack dashboard we can create new volumes “Volume B” and “Volume C” based on the previously created snapshot “Snapshot A”.
|
||||
|
||||

|
||||
|
||||
At the moment we have two new volumes which are based on the “Snapshot A” snapshot. Suppose we no longer need the volume called “Volume A” and we want to delete it.
|
||||
|
||||

|
||||
|
||||
Unfortunately, its deletion will not be possible directly because to delete a given volume, we have to delete its snapshots.
|
||||
|
||||

|
||||
|
||||
So we must first delete the snapshot “Snapshot A” and then the volume “Volume A”.
|
||||
|
||||
However, this will also not be possible due to the fact that the “Snapshot A” snapshot is the source for 2 volumes “Volume B” and “Volume C”.
|
||||
|
||||
To delete a volume from which snapshots volumes were created, we must also delete all snapshots of this volume.
|
||||
|
||||
In conclusion, when creating new volumes from a snapshot, remember about inheritance. Snapshot “Snapshot A” is a parent for the volumes (children) “Volume B” and “Volume C” and if we want to delete the volume “Volume A”, we have to do it from the youngest generation (Volume B and Volume C).
|
||||
|
||||
Backups are another solution and they do not create such bonds as snapshots and may exist even after the volume from which the backup was created has been deleted. Please see [How to Backup an Instance and Download it to the Desktop on CloudFerro Cloud OpenStack Hosting](../openstackcli/How-to-backup-an-instance-and-download-it-to-the-desktop-on-CloudFerro-Cloud.html).
|
||||
2
docs/datavolume/datavolume.html.md
Normal file
2
docs/datavolume/datavolume.html.md
Normal file
@ -0,0 +1,2 @@
|
||||
DATA VOLUME[](#data-volume "Permalink to this headline")
|
||||
=========================================================
|
||||
Reference in New Issue
Block a user