Commit Graph

399 Commits

Author SHA1 Message Date
Joshua Moody
43318cd24f enhancements: Add LEP for backupstore file locks
The idea is to implement a locking mechanism that utilizes the backupstore,
to prevent the following dangerous cases of concurrent operations.
1. prevent backup deletion during backup restoration
2. prevent backup deletion while a backup is in progress
3. prevent backup creation during backup deletion
4. prevent backup restoration during backup deletion

The locking solution shouldn't unnecessary block operations, so the
following cases should be allowed.
1. allow backup creation during restoration
2. allow backup restoration during creation

The locking solution should have a maximum wait time for lock acquisition,
which will fail the backup operation so that the user does not have to wait
forever.

The locking solution should be self expiring, so that when a process dies
unexpectedly, future processes are able to acquire the lock.

The locking solution should guarantee that only a single type of lock is
active at a time.

The locking solution should allow a lock to be passed down into async
running go routines.

Longhorn #612

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-07 10:09:24 -07:00
Phan Le
1a58855f0d dev/scripts, deploy, chart/templates: change imagePullPolicy to IfNotPresent for manager, ui, driver deployer. Also add a bash script to update the image pull policy to be Always
We changed the imagePullPolicy to IfNotPresent so that user can easily
install Longhorn in air-gap instalation.
Also add a bash script for the developer to quickly change all the
imagePullPolicies back to Always so that k8s always pull the
lastest images. This will be useful when dev use the tag such as master.

Longhorn #1491

Signed-off-by: Phan Le <phan.le@rancher.com>
2020-07-02 10:35:18 -07:00
Michael William Le Nguyen
063db2bc5d enhancements: Add LEP for Volume deletion logic
Signed-off-by: Michael William Le Nguyen <michael@mail.ttp.codes>
2020-07-01 12:20:02 -07:00
Joshua Moody
aec2021833 Add rwx-test deployment (append only log)
The test deployment creates 4 replicas that continously, write the
current date time once a second into the file `/mnt/nfs-test/test.log`

This is a good test for an rwx volume. Since it replicates an append
only log that is used by multiple pods.

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-01 12:16:34 -07:00
Joshua Moody
23f9cc18b3 Hardcode nfs service cluster ip
So that on a delete & recreate of the service the previous pv's still
point to this nfs-provisioner. We cannot use the hostname since the actual
host doesn't know how to resolve service addresses inside of the cluster.

To support this would require the installation of kube-dns and
modification to the /etc/resolve.conf file on each host.

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-01 12:16:34 -07:00
Joshua Moody
f70ee1063d Add noresvport to the nfs mount options
This makes the nfs client use a new src port for each tcp reconnect.
This way after a crash the faulty connection isn't kept alive in the
connection cache (nat). This should allow to resolve the cluster ip to
the new destination pod ip.

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-01 12:16:34 -07:00
Joshua Moody
8969d829f2 Add quicker failover for nfs
Add tolerations so that nfs provisioner pod gets evicted from a failing
node after 60 second + 30 grace period (relevant for va recovery policy).
Add liveness + readyness probe, so that no traffic gets routed to a failed
nfs server. Disable device based fsids (major:minor) since our block device
mapping can change from node to node, which makes the id's unstable.

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-01 12:16:34 -07:00
Joshua Moody
51d693b42d Add example deployment of nfs on top of a longhorn volume
This can be used to support RWX scenarios by exposing the longhorn volume via the nfs provisioner. The nfs-provisioner we use can be found at:
https://github.com/kubernetes-incubator/external-storage/tree/master/nfs

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-07-01 12:16:34 -07:00
dmayle
5f775a7488 Update README.md to specify NFS version is v4
Attempting to use longhorn with NFSv3 for backuip causes errors related to rpc.statd, which is not managed by longhorn processes.  Longhorn works properly with NFSv4 servers only.

Signed-off-by: Douglas Mayle <dmayle@dmayle.com>
2020-06-25 17:09:11 -07:00
Bo Tao
809578d983 chart: Add downgrade warning and highlight namespace requirement
Longhorn #1454

Signed-off-by: Bo Tao <bo.tao@rancher.com>
2020-06-04 11:52:18 -07:00
Sheng Yang
2218629598 Update README.md
Remove mention of beta quality.

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-06-02 06:29:27 -07:00
Sheng Yang
3b051eb0fd
Merge pull request #1438 from longhorn/v1.0.0
v1.0.0 to master
2020-05-30 10:20:55 -07:00
Sheng Yang
6d9f02a8c7 Longhorn v1.0.0 release
See https://github.com/longhorn/longhorn/releases/tag/v1.0.0 for the
release note.

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-30 10:03:43 -07:00
Sheng Yang
af389e60a9 Update version to v1.0.0
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-30 10:03:43 -07:00
Sheng Yang
92bbd62958 Sync with manager
commit 1c1bb3571c25378bc8e3680bed72ef3ce61c4360
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Sat May 30 08:55:06 2020 -0700

    Longhorn v1.0.0 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-30 10:03:43 -07:00
Sheng Yang
acb80c4660 Update version to v1.0.0-rc3
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-28 15:20:01 -07:00
Sheng Yang
905c507717 Sync with Longhorn manager:
commit 50524bd046eae4e6702a153115fdf6f82aa0eb3a
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Thu May 28 14:38:29 2020 -0700

    Longhorn v1.0.0-rc3 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-28 15:20:01 -07:00
Sheng Yang
6bb4abd5f7 Update version to v1.0.0-rc2
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-23 13:35:29 -07:00
Sheng Yang
385c7ea54d Sync with manager:
commit fdd34f4f1986da6db3bac1b53c385c23203b0775
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Sat May 23 13:00:11 2020 -0700

    Longhorn v1.0.0-rc2 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-23 13:35:29 -07:00
Shuo Wu
e6e313d0a6 chart: Update settings
Longhorn #1349

Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-05-22 22:00:16 -07:00
Joshua Moody
d008aad816 Fix Instance Manager Image Tag Chart Label
Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
2020-05-21 21:59:30 -07:00
Shuo Wu
fa5e6501f6 chart: Update instance manager image tag
Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-05-19 19:56:35 -07:00
Sheng Yang
3e17410f0c Update version to Longhorn v1.0.0-rc1
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-19 17:03:42 -07:00
Sheng Yang
ff17f15259 Sync with manager:
commit cdca4692898b817472d71aded45ec7ed0a2b8b84
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Tue May 19 16:18:53 2020 -0700

    Longhorn v1.0.0-rc1 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-05-19 17:03:42 -07:00
Aaron Spettl
1867b85110 Set securityContext for deployer and ui
When pod security policies are used, the default restricted policy does
not allow root permissions. Even when a more permissive policy is
assigned to the service account, we need to inform k8s that we need root
permissions so that the correct policy can be selected.

Signed-off-by: Aaron Spettl <aaron@spettl.de>
2020-05-17 23:33:09 -07:00
Thulio Ferraz Assis
5e67c380a8 fix: use quote fn instead of YAML quotes
Signed-off-by: Thulio Ferraz Assis <thulio.assis@suse.com>
2020-05-14 18:52:33 -07:00
Thulio Ferraz Assis
6741a5f003 fix: use explicit nil YAML values
Signed-off-by: Thulio Ferraz Assis <thulio.assis@suse.com>
2020-05-14 18:52:33 -07:00
Mohamed Eldafrawi
fe93b7ac14 fix typo in chart questions
Signed-off-by: Mohamed Eldafrawi <mohamed.eldafrawi@rancher.com>
2020-05-14 17:23:19 -07:00
Thulio Ferraz Assis
2c54009ff4 feat: add csi.resizerReplicaCount to chart values
Signed-off-by: Thulio Ferraz Assis <thulio.assis@suse.com>
2020-05-14 11:01:36 -07:00
Mohamed Eldafrawi
f473ae48f1 Hide the customized default setting by default in Rancher chart
Signed-off-by: Mohamed Eldafrawi <mohamed.eldafrawi@rancher.com>
2020-05-11 13:29:08 -07:00
Sheng Yang
66f26a9c3d
Merge pull request #1272 from longhorn/v0.8.1
v0.8.1
2020-04-28 19:06:06 -07:00
Sheng Yang
318fbc347b Longhorn v0.8.1 release
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-28 17:52:48 -07:00
Sheng Yang
673d99a6aa deploy: Update version to v0.8.1
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-28 17:52:48 -07:00
Sheng Yang
c915b1c511 Sync with Longhorn manager
commit ed3409b4c1bf53bbdda94d7a75399a73a617660e
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Tue Apr 28 15:50:17 2020 -0700

    Longhorn v0.8.1 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-28 17:52:48 -07:00
Shuo Wu
dfd438a28c chart: v0.8.1 release
Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-04-28 17:34:38 -07:00
Shuo Wu
ef1ba9accd chart: Update deployment files
Longhorn #1163

Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-04-28 17:34:38 -07:00
Shuo Wu
7978692614 chart: Update links in the docs
Longhorn #1229

Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-04-28 17:34:38 -07:00
Sheng Yang
e39dece7a7 Longhorn v0.8.1-rc3 release
Update version tags.

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-24 15:07:05 -07:00
Sheng Yang
85ab7c8d9d Sync with manager
commit 91bb47d8095238efc1249153341f8a57a4fd8f92
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Fri Apr 24 13:35:53 2020 -0700

    Longhorn v0.8.1-rc3 release

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-24 15:07:05 -07:00
Sheng Yang
340ed789f2 chart: Update questions.yaml to v0.8.1-rc2
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-21 17:50:14 -07:00
Sheng Yang
c02f69d6f7 Sync with manager and update chart tags
commit 364ff6b1bbb9bd5d3f20757304fd27f3f583feb4
Author: Sheng Yang <sheng.yang@rancher.com>
Date:   Tue Apr 21 15:49:31 2020 -0700

    Longhorn v0.8.1-rc2 release

    Signed-off-by: Sheng Yang <sheng.yang@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-21 17:50:14 -07:00
meldafrawi
c67fc8060e add Longhorn and CSI use default image question
Signed-off-by: Mohamed Eldafrawi <mohamed.eldafrawi@rancher.com>
2020-04-21 11:52:09 -07:00
Sheng Yang
ed571836d7 chart: Update questions.yaml to v0.8.1-rc1
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-15 21:01:06 -07:00
Sheng Yang
5b141bcaf9 Sync with manager and update chart tags
commit 83bf32dc586bf99314fcd3efa396da676cb4cd55
Author: Shuo Wu <shuo@rancher.com>
Date:   Wed Apr 15 17:19:05 2020 +0800

    Add 'FromReplica' for 'RebuildStatus'

    Longhorn #1167

    Signed-off-by: Shuo Wu <shuo@rancher.com>

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-15 21:01:06 -07:00
meldafrawi
6b990aea63 Add airgap support to chart
Signed-off-by: meldafrawi <mohamed.eldafrawi@rancher.com>
2020-04-15 21:01:06 -07:00
Catherine Luse
57785d98b8 Remove longhorn.io docs from longhorn/longhorn
Signed-off-by: Catherine Luse <catherine.luse@gmail.com>
2020-04-14 14:53:53 -07:00
Sheng Yang
eb5301b62a chart: Change default setting for storage related options
Longhorn #1068

Overprovision factor to 200%.
Minimal available disk to 25%.

Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-04-02 12:45:30 -07:00
Shuo Wu
8029c17658 doc: Update live upgrade support in upgrade.md
Signed-off-by: Shuo Wu <shuo@rancher.com>
2020-04-01 23:30:26 -07:00
Sheng Yang
c3bf0238ac enhancement: Add API Changes in the template
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-03-31 16:45:38 -07:00
Sheng Yang
92bb35b2f3 enhancement: replace filesystem ID key in Disk map
Signed-off-by: Sheng Yang <sheng.yang@rancher.com>
2020-03-31 16:42:19 -07:00