mirror of
https://github.com/minio/minio.git
synced 2024-12-24 06:05:55 -05:00
docs: Fix and reword FreeBSD documentation. (#4145)
This commit is contained in:
parent
f4dac979a2
commit
402a5e3bea
12
README.md
12
README.md
@ -61,6 +61,16 @@ minio.exe server D:\Photos
|
|||||||
```
|
```
|
||||||
|
|
||||||
## FreeBSD
|
## FreeBSD
|
||||||
|
### Port
|
||||||
|
Install minio packages using [pkg](https://github.com/freebsd/pkg)
|
||||||
|
|
||||||
|
```sh
|
||||||
|
pkg install minio
|
||||||
|
sysrc minio_enable=yes
|
||||||
|
sysrc minio_disks=/home/user/Photos
|
||||||
|
service minio start
|
||||||
|
```
|
||||||
|
|
||||||
### Binary Download
|
### Binary Download
|
||||||
| Platform| Architecture | URL|
|
| Platform| Architecture | URL|
|
||||||
| ----------| -------- | ------|
|
| ----------| -------- | ------|
|
||||||
@ -70,8 +80,6 @@ chmod 755 minio
|
|||||||
./minio server ~/Photos
|
./minio server ~/Photos
|
||||||
```
|
```
|
||||||
|
|
||||||
You can run Minio on FreeBSD with FreeNAS storage-backend - see [here](https://docs.minio.io/docs/how-to-run-minio-in-freenas) for more details.
|
|
||||||
|
|
||||||
## Install from Source
|
## Install from Source
|
||||||
|
|
||||||
Source installation is only intended for developers and advanced users. If you do not have a working Golang environment, please follow [How to install Golang](https://docs.minio.io/docs/how-to-install-golang).
|
Source installation is only intended for developers and advanced users. If you do not have a working Golang environment, please follow [How to install Golang](https://docs.minio.io/docs/how-to-install-golang).
|
||||||
|
@ -1,35 +1,25 @@
|
|||||||
# Minio FreeBSD Quickstart Guide [![Slack](https://slack.minio.io/slack?type=svg)](https://slack.minio.io)
|
# Minio FreeBSD Quickstart Guide [![Slack](https://slack.minio.io/slack?type=svg)](https://slack.minio.io)
|
||||||
|
|
||||||
### Minio with ZFS backend - FreeBSD
|
### Minio with ZFS backend - FreeBSD
|
||||||
|
This example assumes that you have a FreeBSD 11.x running
|
||||||
|
|
||||||
This example assumes that you have a FreeBSD 10.x running
|
#### Start ZFS service
|
||||||
|
|
||||||
#### Step 1.
|
|
||||||
|
|
||||||
As root on the FreeBSD edit `/etc/rc.conf`
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
zfs_enable="YES"
|
sysrc zfs_enable="YES"
|
||||||
```
|
```
|
||||||
|
|
||||||
Start ZFS service
|
Start ZFS service
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
service zfs start
|
service zfs start
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Configure a loopback device on the `/zfs` file.
|
||||||
```sh
|
```sh
|
||||||
dd if=/dev/zero of=/zfs bs=1M count=4000
|
dd if=/dev/zero of=/zfs bs=1M count=4000
|
||||||
```
|
|
||||||
|
|
||||||
Configure a loopback device on the `/zfs` file.
|
|
||||||
|
|
||||||
```sh
|
|
||||||
mdconfig -a -t vnode -f /zfs
|
mdconfig -a -t vnode -f /zfs
|
||||||
```
|
```
|
||||||
|
|
||||||
Create zfs pool
|
Create zfs pool
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
zpool create minio-example /dev/md0
|
zpool create minio-example /dev/md0
|
||||||
```
|
```
|
||||||
@ -41,72 +31,47 @@ minio-example 7872440 38 7872402 0% /minio-example
|
|||||||
```
|
```
|
||||||
|
|
||||||
Verify if it is writable
|
Verify if it is writable
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
touch /minio-example/testfile
|
touch /minio-example/testfile
|
||||||
ls -l /minio-example/testfile
|
ls -l /minio-example/testfile
|
||||||
-rw-r--r-- 1 root wheel 0 Apr 26 00:51 /minio-example/testfile
|
-rw-r--r-- 1 root wheel 0 Apr 26 00:51 /minio-example/testfile
|
||||||
```
|
```
|
||||||
|
|
||||||
Now you have successfully created a ZFS pool for further reading please refer to [ZFS Quickstart Guide](https://www.freebsd.org/doc/handbook/zfs-quickstart.html)
|
Now you have successfully created a ZFS pool for further reading please refer [ZFS Quickstart Guide](https://www.freebsd.org/doc/handbook/zfs-quickstart.html)
|
||||||
|
|
||||||
However, this pool is not taking advantage of any ZFS features, so let's create a ZFS filesytem on this pool with compression enabled. ZFS supports many compression algorithms: lzjb, gzip, zle, lz4. LZ4 is often the most performant algorithm in terms of compression of data versus system overhead.
|
|
||||||
|
|
||||||
|
|
||||||
|
However, this pool is not taking advantage of any ZFS features. So let's create a ZFS filesytem on this pool with compression enabled. ZFS supports many compression algorithms: [`lzjb`, `gzip`, `zle`, `lz4`]. `lz4` is often the most performant algorithm in terms of compression of data versus system overhead.
|
||||||
```sh
|
```sh
|
||||||
zfs create minio-example/compressed-objects
|
zfs create minio-example/compressed-objects
|
||||||
zfs set compression=lz4 minio-example/compressed-objects
|
zfs set compression=lz4 minio-example/compressed-objects
|
||||||
```
|
```
|
||||||
|
|
||||||
To keep monitoring your pool use
|
To monitor if your pools are healthy.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
zpool status
|
zpool status -x
|
||||||
pool: minio-example
|
all pools are healthy
|
||||||
state: ONLINE
|
|
||||||
scan: none requested
|
|
||||||
config:
|
|
||||||
|
|
||||||
NAME STATE READ WRITE CKSUM
|
|
||||||
minio-example ONLINE 0 0 0
|
|
||||||
md0 ONLINE 0 0 0
|
|
||||||
|
|
||||||
errors: No known data errors
|
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Step 2.
|
#### Start Minio service
|
||||||
|
Install [Minio](https://minio.io) from FreeBSD port.
|
||||||
Now start minio server on the ``/minio-example/compressed-objects``, change the permissions such that this directory is accessibly by a normal user
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
chown -R minio-user:minio-user /minio-example/compressed-objects
|
pkg install minio
|
||||||
```
|
```
|
||||||
|
|
||||||
Now login as ``minio-user`` and start minio server.
|
Enable minio and configure minio to use ZFS volume mounted at `/minio-example/compressed-objects`.
|
||||||
|
```
|
||||||
```sh
|
sysrc minio_enable=yes
|
||||||
curl https://dl.minio.io/server/minio/release/freebsd-amd64/minio > minio
|
sysrc minio_disks=/minio-example/compressed-objects
|
||||||
chmod 755 minio
|
|
||||||
./minio server /minio-example/compressed-objects
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Point your browser to http://localhost:9000 and login with the credentials displayed on the command line.
|
Start minio.
|
||||||
|
```
|
||||||
Now you have a S3 compatible server running on top of your ZFS backend which transparently provides disk level compression for your uploaded objects.
|
service minio start
|
||||||
|
|
||||||
Thanks for using Minio, awaiting feedback :-)
|
|
||||||
|
|
||||||
|
|
||||||
#### Building Minio Server From Source
|
|
||||||
|
|
||||||
It is possible to build the minio server from source on FreeBSD. To do this we will used the golang distribution provided by the FreeBSD pkg infrastructure.
|
|
||||||
|
|
||||||
We will need to install golang and GNU make:
|
|
||||||
|
|
||||||
```sh
|
|
||||||
sudo pkg install go gmake
|
|
||||||
```
|
```
|
||||||
Now we can proceed with the normal build process of minio server as found [here](https://github.com/minio/minio/blob/master/CONTRIBUTING.md). The only caveat is we need to specify gmake (GNU make) when building minio server as the current Makefile is not BSD make compatible:
|
|
||||||
|
|
||||||
|
Now you have an Minio running on top of your ZFS backend which transparently provides disk level compression for your uploaded objects, please visit http://localhost:9000 to open Minio Browser.
|
||||||
|
|
||||||
From here you can start the server as you would with a precompiled minio server build.
|
#### Stop Minio service
|
||||||
|
In-case you wish to stop Minio service.
|
||||||
|
```sh
|
||||||
|
service minio stop
|
||||||
|
```
|
Loading…
Reference in New Issue
Block a user