Merge remote-tracking branch 'LCTT/master'

This commit is contained in:
Xingyu.Wang 2019-03-20 22:04:22 +08:00
commit 74aef63b0a
9 changed files with 1015 additions and 67 deletions

View File

@ -1,58 +0,0 @@
[#]: collector: (lujun9972)
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Get started with CryptPad, an open source collaborative document editor)
[#]: via: (https://opensource.com/article/19/1/productivity-tool-cryptpad)
[#]: author: (Kevin Sonney https://opensource.com/users/ksonney (Kevin Sonney))
Get started with CryptPad, an open source collaborative document editor
======
Securely share your notes, documents, kanban boards, and more with CryptPad, the fifth in our series on open source tools that will make you more productive in 2019.
![](https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/web_browser_desktop_devlopment_design_system_computer.jpg?itok=pfqRrJgh)
There seems to be a mad rush at the beginning of every year to find ways to be more productive. New Year's resolutions, the itch to start the year off right, and of course, an "out with the old, in with the new" attitude all contribute to this. And the usual round of recommendations is heavily biased towards closed source and proprietary software. It doesn't have to be that way.
Here's the fifth of my picks for 19 new (or new-to-you) open source tools to help you be more productive in 2019.
### CryptPad
We already talked about [Joplin][1], which is good for keeping your own notes but—as you may have noticed—doesn't have any sharing or collaboration features.
[CryptPad][2] is a secure, shareable note-taking app and document editor that allows for secure, collaborative editing. Unlike Joplin, it is a NodeJS app, which means you can run it on your desktop or a server elsewhere and access it with any modern web browser. Out of the box, it supports rich text, Markdown, polls, whiteboards, kanban, and presentations.
![](https://opensource.com/sites/default/files/uploads/cryptpad-1.png)
The different document types are robust and fully featured. The rich text editor covers all the bases you'd expect from a good editor and allows you to export files to HTML. The Markdown editor is on par with Joplin, and the kanban board, though not as full-featured as [Wekan][3], is really well done. The rest of the supported document types and editors are also very polished and have the features you'd expect from similar apps, although polls feel a little clunky.
![](https://opensource.com/sites/default/files/uploads/cryptpad-2.png)
CryptPad's real power, though, comes in its sharing and collaboration features. Sharing a document is as simple as getting the sharable URL from the "share" option, and CryptPad supports embedding documents in iFrame tags on other websites. Documents can be shared in Edit or View mode with a password and with links that expire. The built-in chat allows editors to talk to each other (note that people with View access can also see the chat but can't comment).
![](https://opensource.com/sites/default/files/pictures/cryptpad-3.png)
All files are stored encrypted with the user's password. Server administrators can't read the documents, which also means if you forget or lose your password, the files are unrecoverable. So make sure you keep the password in a secure place, like a [password vault][4].
![](https://opensource.com/sites/default/files/uploads/cryptpad-4.png)
When it's run locally, CryptPad is a robust app for creating and editing documents. When run on a server, it becomes an excellent collaboration platform for multi-user document creation and editing. Installation took less than five minutes on my laptop, and it just worked out of the box. The developers also include instructions for running CryptPad in Docker, and there is a community-maintained Ansible role for ease of deployment. CryptPad does not support any third-party authentication methods, so users must create their own accounts. CryptPad also has a community-supported hosted version if you don't want to run your own server.
--------------------------------------------------------------------------------
via: https://opensource.com/article/19/1/productivity-tool-cryptpad
作者:[Kevin Sonney][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/ksonney (Kevin Sonney)
[b]: https://github.com/lujun9972
[1]: https://opensource.com/article/19/1/productivity-tool-joplin
[2]: https://cryptpad.fr/index.html
[3]: https://opensource.com/article/19/1/productivity-tool-wekan
[4]: https://opensource.com/article/18/4/3-password-managers-linux-command-line

View File

@ -0,0 +1,84 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Emacs for (even more of) the win)
[#]: via: (https://so.nwalsh.com/2019/03/01/emacs)
[#]: author: (Norman Walsh https://so.nwalsh.com)
Emacs for (even more of) the win
======
I use Emacs every day. I rarely notice it. But when I do, it usually brings me joy.
>If you are a professional writer…Emacs outshines all other editing software in approximately the same way that the noonday sun does the stars. It is not just bigger and brighter; it simply makes everything else vanish.
Ive been using [Emacs][1] for well over twenty years. I use it for writing almost anything and everything (I edit Scala and Java in [IntelliJ][2]). I read my email in it. If it can be done in Emacs, thats where I prefer to do it.
Although Ive used Emacs for literally decades, I realized around the new year that very little about my use of Emacs had changed in the past decade or more. New editing modes had come along, of course, Id picked up a package or two, and I did adopt [Helm][3] a few years ago, but mostly it just did all the heavy lifting that I required of it, day in and day out without complaining or getting in my way. On the one hand, thats a testament to how good it is. On the other hand, thats an invitation to dig in and see what Ive missed.
At about the same time, I resolved to improve several aspects of my work life:
* **Better meeting management.** Im lead on a couple of projects at work and those projects have meetings, both regularly scheduled and ad hoc; some of them I run, some of them, I only attend.
I realized Id become sloppy about my participation in meetings. Its all too easy sit in a room where theres a meeting going on but actually read email and work on other items. (I strongly oppose the “no laptops” rule in meetings, but thats a topic for another day.)
There are a couple of problems with sloppy participation. First, its disrespectful to the person who convened the meeting and the other participants. Thats actually sufficient reason not to do it, but I think theres another problem: it disguises the cost of meetings.
If youre in a meeting but also answering your email and maybe fixing a bug, then that meeting didnt cost anything (or as much). If meetings are cheap, then there will be more of them.
I want fewer, shorter meetings. I dont want to disguise their cost, I want them to be perceived as damned expensive and to be avoided unless absolutely necessary.
Sometimes, they are absolutely necessary. And I appreciate that a quick meeting can sometimes resolve an issue quickly. But if I have ten short meetings a day, lets not pretend that Im getting anything else productive accomplished.
I resolved to take notes at all the meetings I attend. Im not offering to take minutes, necessarily, but I am taking minutes of a sort. It keeps me focused on the meeting and not catching up on other things.
* **Better time management.** There are lots and lots of things that I need or want to do, both professionally and personally. Ive historically kept track off some of them in issue lists, some in saved email threads (in Emacs and [Gmail][4], for slightly different types of reminders), in my calendar, on “todo lists” of various sorts on my phone, and on little scraps of paper. And probably other places as well.
I resolved to keep them all in one place. Not because I think theres one place thats uniformly best or better, but because I hope to accomplish two things. First, by having them all in one place, I hope to be able to develop a better and more holistic view of where Im putting my energies. Second, because I want to develop a habitn. “A settled or regular tendency or practice, especially one that is hard to give up.” of recording, tracking, and preserving them.
* **Better accountability.** If you work in certain science or engineering disciplines, you will have developed the habit of keeping a [lab notebook][5]. Alas, I did not. But I resolved to do so.
Im not interested in the legal aspects that encourage bound pages or scribing only in permanent marker. What Im interested in is developing the habit of keeping a record. My goal is to have a place to jot down ideas and design sketches and the like. If I have sudden inspiration or if I think of an edge case that isnt in the test suite, I want my instinct to be to write it in my journal instead of scribbling it on a scrap of paper or promising myself that Ill remember it.
This confluence of resolutions led me quickly and more-or-less directly to [Org][6]. There is a large, active, and loyal community of Org users. Ive played with it in the past (I even [wrote about it][7], at least in passing, a couple of years ago) and I tinkered long enough to [integrate MarkLogic][8] into it. (Boy has that paid off in the last week or two!)
But I never used it.
I am now using it. I take minutes in it, I record all of my todo items in it, and I keep a journal in it. Im not sure theres much value in me attempting to wax eloquent about it or enumerate all its features, youll find plenty of either with a quick web search.
If you use Emacs, you should be using Org. If you dont use Emacs, Im confident you wouldnt be the first person who started because of Org. It does a lot. It takes a little time to learn your way around and remember the shortcuts, but I think its worth it. (And if you carry an [iOS][9] device in your pocket, I recommend [beorg][10] for recording items while youre on the go.)
Naturally, I worked out how to [get XML out of it][11]⊕“Worked out” sure is a funny way to spell “hacked together in elisp.”. And from there, how to turn it back into the markup my weblog expects (and do so at the push of a button in Emacs, of course). So this is the first posting written in Org. It wont be the last.
P.S. Happy birthday [little weblog][12].
--------------------------------------------------------------------------------
via: https://so.nwalsh.com/2019/03/01/emacs
作者:[Norman Walsh][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://so.nwalsh.com
[b]: https://github.com/lujun9972
[1]: https://en.wikipedia.org/wiki/Emacs
[2]: https://en.wikipedia.org/wiki/IntelliJ_IDEA
[3]: https://emacs-helm.github.io/helm/
[4]: https://en.wikipedia.org/wiki/Gmail
[5]: https://en.wikipedia.org/wiki/Lab_notebook
[6]: https://en.wikipedia.org/wiki/Org-mode
[7]: https://www.balisage.net/Proceedings/vol17/html/Walsh01/BalisageVol17-Walsh01.html
[8]: https://github.com/ndw/ob-ml-marklogic/
[9]: https://en.wikipedia.org/wiki/IOS
[10]: https://beorgapp.com/
[11]: https://github.com/ndw/org-to-xml
[12]: https://so.nwalsh.com/2017/03/01/helloWorld

View File

@ -1,5 +1,5 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )

View File

@ -1,11 +1,11 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (How To Parse And Pretty Print JSON With Linux Commandline Tools)
[#]: via: (https://www.ostechnix.com/how-to-parse-and-pretty-print-json-with-linux-commandline-tools/)
[#]: author: (EDITOR https://www.ostechnix.com/author/editor/)
[#]: collector: "lujun9972"
[#]: translator: "zhangxiangping "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
[#]: subject: "How To Parse And Pretty Print JSON With Linux Commandline Tools"
[#]: via: "https://www.ostechnix.com/how-to-parse-and-pretty-print-json-with-linux-commandline-tools/"
[#]: author: "EDITOR https://www.ostechnix.com/author/editor/"
How To Parse And Pretty Print JSON With Linux Commandline Tools
======

View File

@ -0,0 +1,50 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Blockchain 2.0: Blockchain In Real Estate [Part 4])
[#]: via: (https://www.ostechnix.com/blockchain-2-0-blockchain-in-real-estate/)
[#]: author: (EDITOR https://www.ostechnix.com/author/editor/)
Blockchain 2.0: Blockchain In Real Estate [Part 4]
======
![](https://www.ostechnix.com/wp-content/uploads/2019/03/Blockchain-In-Real-Estate-720x340.png)
### Blockchain 2.0: Smarter Real Estate
The [**previous article**][1] of this series explored the features of blockchain which will enable institutions to transform and interlace **traditional banking** and **financing systems** with it. This part will explore **Blockchain in real estate**. The real estate industry is ripe for a revolution. Its among the most actively traded most significant asset classes known to man. However, filled with regulatory hurdles and numerous possibilities of fraud and deceit, its also one of the toughest to participate in. The distributed ledger capabilities of the blockchain utilizing an appropriate consensus algorithm are touted as the way forward for the industry which is traditionally regarded as conservative in its attitude to change.
Real estate has always been a very conservative industry in terms of its myriad operations. Somewhat rightfully so as well. A major economic crisis such as the 2008 financial crisis or the great depression from the early half of the 20th century managed to destroy the industry and its participants. However, like most products of economic value, the real estate industry is resilient and this resilience is rooted in its conservative nature.
The global real estate market comprises an asset class worth **$228 trillion dollars** [1]. Give or take. Other investment assets such as stocks, bonds, and shares combined are only worth **$170 trillion**. Obviously, any and all transactions implemented in such an industry is naturally carefully planned and meticulously executed, for the most part. For the most part, because real estate is also notorious for numerous instances of fraud and devastating loses which ensue them. The industry because of the very conservative nature of its operations is also tough to navigate. Its heavily regulated with complex laws creating an intertwined web of nuances that are just too difficult for an average person to understand fully. This makes entry and participation near impossible for most people. If youve ever been involved in one such deal, youll know how heavy and long the paper trail was.
This hard reality is now set to change, albeit a slow and gradual transformation. The very reasons the industry has stuck to its hardy tested roots all this while can finally give way to its modern-day counterpart. The backbone of the real estate industry has always been its paper records. Land deeds, titles, agreements, rental insurance, proofs, and declarations etc., are just the tip of the iceberg here. If youve noticed the pattern here, this should be obvious, the distributed ledger technology that is blockchain, fits in perfectly with the needs here. Forget paper records, conventional database systems are also points of major failure. They can be modified by multiple participants, is not tamper proof or un-hackable, has a complicated set of ever-changing regulatory parameters making auditing and verifying data a nightmare. The blockchain perfectly solves all of these issues and more.
Starting with a trivial albeit an important example to show just how bad the current record management practices are in the real estate sector, consider the **Title Insurance business** [2], [3]. Title Insurance is used to hedge against the possibility of the lands titles and ownership records being inadmissible and hence unenforceable. An insurance product such as this is also referred to as an indemnity cover. It is by law required in many cases that properties have title insurance, especially when dealing with property that has changed hands multiple times over the years. Mortgage firms might insist on the same as well when they back real estate deals. The fact that a product of this kind has existed since the 1850s and that it does business worth at least **$1.5 trillion a year in the US alone** is a testament to the statement at the start. A revolution in terms of how these records are maintained is imperative to have in this situation and the blockchain provides a sustainable solution. Title fraud averages around $100k per case on average as per the **American Land Title Association** and 25% of all titles involved in transactions have an issue regarding their documents[4]. The blockchain allows for setting up an immutable permanent database that will track the property itself, recording each and every transaction or investment that has gone into it. Such a ledger system will make life easier for everyone involved in the real estate industry including one-time home buyers and make financial products such as Title Insurance basically irrelevant. Converting a physical asset such as real estate to a digital asset like this is unconventional and is extant only in theory at the moment. However, such a change is imminent sooner rather than later[5].
Among the areas in which blockchain will have the most impact within real estate is as highlighted above in maintaining a transparent and secure title management system for properties. A blockchain based record of the property can contain information about the property, its location, history of ownership, and any related public record of the same[6]. This will permit closing real estate deals fast and obliviates the need for 3rd party monitoring and oversight. Tasks such as real estate appraisal and tax calculations become matters of tangible objective parameters rather than subjective measures and guesses because of reliable historical data which is publicly verifiable. **UBITQUITY** is one such platform that offers customized blockchain-based solutions to enterprise customers. The platform allows customers to keep track of all property details, payment records, mortgage records and even allows running smart contracts thatll take care of taxation and leasing automatically[7].
This brings us to the second biggest opportunity and use case of blockchains in real estate. Since the sector is highly regulated by numerous 3rd parties apart from the counterparties involved in the trade, due-diligence and financial evaluations can be significantly time-consuming. These processes are predominantly carried out using offline channels and paperwork needs to travel for days before a final evaluation report comes out. This is especially true for corporate real estate deals and forms a bulk of the total billable hours charged by consultants. In case the transaction is backed by a mortgage, duplication of these processes is unavoidable. Once combined with digital identities for the people and institutions involved along with the property, the current inefficiencies can be avoided altogether and transactions can take place in a matter of seconds. The tenants, investors, institutions involved, consultants etc., could individually validate the data and arrive at a critical consensus thereby validating the property records for perpetuity[8]. This increases the accuracy of verification manifold. Real estate giant **RE/MAX** has recently announced a partnership with service provider **XYO Network Partners** for building a national database of real estate listings in Mexico. They hope to one day create one of the largest (as of yet) decentralized real estate title registry in the world[9].
However, another significant and arguably a very democratic change that the blockchain can bring about is with respect to investing in real estate. Unlike other investment asset classes where even small household investors can potentially participate, real estate often requires large hands-down payments to participate. Companies such as **ATLANT** and **BitOfProperty** tokenize the book value of a property and convert them into equivalents of a cryptocurrency. These tokens are then put for sale on their exchanges similar to how stocks and shares are traded. Any cash flow that the real estate property generates afterward is credited or debited to the token owners depending on their “share” in the property[4].
However, even with all of that said, Blockchain technology is still in very early stages of adoption in the real estate sector and current regulations are not exactly defined for it to be either[8]. Concepts such as distributed applications, distributed anonymous organizations, smart contracts etc., are unheard of in the legal domain in many countries. A complete overhaul of existing regulations and guidelines once all the stakeholders are well educated on the intricacies of the blockchain is the most pragmatic way forward. Again, itll be a slow and gradual change to go through, however a much-needed one nonetheless. The next article of the series will look at how **“Smart Contracts”** , such as those implemented by companies such as UBITQUITY and XYO are created and executed in the blockchain.
--------------------------------------------------------------------------------
via: https://www.ostechnix.com/blockchain-2-0-blockchain-in-real-estate/
作者:[EDITOR][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.ostechnix.com/author/editor/
[b]: https://github.com/lujun9972
[1]: https://www.ostechnix.com/blockchain-2-0-redefining-financial-services/

View File

@ -0,0 +1,342 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Five Commands To Use Calculator In Linux Command Line?)
[#]: via: (https://www.2daygeek.com/linux-command-line-calculator-bc-calc-qalc-gcalccmd/)
[#]: author: (Magesh Maruthamuthu https://www.2daygeek.com/author/magesh/)
Five Commands To Use Calculator In Linux Command Line?
======
As a Linux administrator you may use the command line calculator many times in a day for some purpose.
I had used this especially when LVM creation using the PE values.
There are many commands available for this purpose and im going to list most used commands in this article.
These command line calculators are allow us to perform all kind of actions such as scientific, financial, or even simple calculation.
Also, we can use these commands in shell scripts for complex math.
In this article, Im listing the top five command line calculator commands.
Those command line calculator commands are below.
* **`bc:`** An arbitrary precision calculator language
* **`calc:`** arbitrary precision calculator
* **`expr:`** evaluate expressions
* **`gcalccmd:`** gnome-calculator a desktop calculator
* **`qalc:`**
* **`Linux Shell:`**
### How To Perform Calculation In Linux Using bc Command?
bs stands for Basic Calculator. bc is a language that supports arbitrary precision numbers with interactive execution of statements. There are some similarities in the syntax to the C programming language.
A standard math library is available by command line option. If requested, the math library is defined before processing any files. bc starts by processing code from all the files listed on the command line in the order listed.
After all files have been processed, bc reads from the standard input. All code is executed as it is read.
By default bc command has installed in all the Linux system. If not, use the following procedure to install it.
For **`Fedora`** system, use **[DNF Command][1]** to install bc.
```
$ sudo dnf install bc
```
For **`Debian/Ubuntu`** systems, use **[APT-GET Command][2]** or **[APT Command][3]** to install bc.
```
$ sudo apt install bc
```
For **`Arch Linux`** based systems, use **[Pacman Command][4]** to install bc.
```
$ sudo pacman -S bc
```
For **`RHEL/CentOS`** systems, use **[YUM Command][5]** to install bc.
```
$ sudo yum install bc
```
For **`openSUSE Leap`** system, use **[Zypper Command][6]** to install bc.
```
$ sudo zypper install bc
```
### How To Use The bc Command To Perform Calculation In Linux?
We can use the bc command to perform all kind of calculation right from the terminal.
```
$ bc
bc 1.07.1
Copyright 1991-1994, 1997, 1998, 2000, 2004, 2006, 2008, 2012-2017 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
1+2
3
10-5
5
2*5
10
10/2
5
(2+4)*5-5
25
quit
```
Use `-l` flag to define the standard math library.
```
$ bc -l
bc 1.07.1
Copyright 1991-1994, 1997, 1998, 2000, 2004, 2006, 2008, 2012-2017 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
3/5
.60000000000000000000
quit
```
### How To Perform Calculation In Linux Using calc Command?
calc is an arbitrary precision calculator. Its a simple calculator that allow us to perform all kind of calculation in Linux command line.
For **`Fedora`** system, use **[DNF Command][1]** to install calc.
```
$ sudo dnf install calc
```
For **`Debian/Ubuntu`** systems, use **[APT-GET Command][2]** or **[APT Command][3]** to install calc.
```
$ sudo apt install calc
```
For **`Arch Linux`** based systems, use **[Pacman Command][4]** to install calc.
```
$ sudo pacman -S calc
```
For **`RHEL/CentOS`** systems, use **[YUM Command][5]** to install calc.
```
$ sudo yum install calc
```
For **`openSUSE Leap`** system, use **[Zypper Command][6]** to install calc.
```
$ sudo zypper install calc
```
### How To Use The calc Command To Perform Calculation In Linux?
We can use the calc command to perform all kind of calculation right from the terminal.
Intractive mode
```
$ calc
C-style arbitrary precision calculator (version 2.12.7.1)
Calc is open software. For license details type: help copyright
[Type "exit" to exit, or "help" for help.]
; 5+1
6
; 5-1
4
; 5*2
10
; 10/2
5
; quit
```
Non-Intractive mode
```
$ calc 3/5
0.6
```
### How To Perform Calculation In Linux Using expr Command?
Print the value of EXPRESSION to standard output. A blank line below separates increasing precedence groups. Its part of coreutils so, we no need to install it.
### How To Use The expr Command To Perform Calculation In Linux?
Use the following format for basic calculations.
For addition
```
$ expr 5 + 1
6
```
For subtraction
```
$ expr 5 - 1
4
```
For division.
```
$ expr 10 / 2
5
```
### How To Perform Calculation In Linux Using gcalccmd Command?
gnome-calculator is the official calculator of the GNOME desktop environment. gcalccmd is the console version of Gnome Calculator utility. By default it has installed in the GNOME desktop.
### How To Use The gcalccmd Command To Perform Calculation In Linux?
I have added few examples on this.
```
$ gcalccmd
> 5+1
6
> 5-1
4
> 5*2
10
> 10/2
5
> sqrt(16)
4
> 3/5
0.6
> quit
```
### How To Perform Calculation In Linux Using qalc Command?
Qalculate is a multi-purpose cross-platform desktop calculator. It is simple to use but provides power and versatility normally reserved for complicated math packages, as well as useful tools for everyday needs (such as currency conversion and percent calculation).
Features include a large library of customizable functions, unit calculations and conversion, symbolic calculations (including integrals and equations), arbitrary precision, uncertainty propagation, interval arithmetic, plotting, and a user-friendly interface (GTK+ and CLI).
For **`Fedora`** system, use **[DNF Command][1]** to install qalc.
```
$ sudo dnf install libqalculate
```
For **`Debian/Ubuntu`** systems, use **[APT-GET Command][2]** or **[APT Command][3]** to install qalc.
```
$ sudo apt install libqalculate
```
For **`Arch Linux`** based systems, use **[Pacman Command][4]** to install qalc.
```
$ sudo pacman -S libqalculate
```
For **`RHEL/CentOS`** systems, use **[YUM Command][5]** to install qalc.
```
$ sudo yum install libqalculate
```
For **`openSUSE Leap`** system, use **[Zypper Command][6]** to install qalc.
```
$ sudo zypper install libqalculate
```
### How To Use The qalc Command To Perform Calculation In Linux?
I have added few examples on this.
```
$ qalc
> 5+1
5 + 1 = 6
> ans*2
ans * 2 = 12
> ans-2
ans - 2 = 10
> 1 USD to INR
It has been 36 day(s) since the exchange rates last were updated.
Do you wish to update the exchange rates now? y
error: Failed to download exchange rates from coinbase.com: Resolving timed out after 15000 milliseconds.
1 * dollar = approx. INR 69.638581
> 10 USD to INR
10 * dollar = approx. INR 696.38581
> quit
```
### How To Perform Calculation In Linux Using Linux Shell Command?
We can use the shell commands such as echo, awk, etc to perform the calculation.
For Addition using echo command.
```
$ echo $((5+5))
10
```
--------------------------------------------------------------------------------
via: https://www.2daygeek.com/linux-command-line-calculator-bc-calc-qalc-gcalccmd/
作者:[Magesh Maruthamuthu][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.2daygeek.com/author/magesh/
[b]: https://github.com/lujun9972
[1]: https://www.2daygeek.com/dnf-command-examples-manage-packages-fedora-system/
[2]: https://www.2daygeek.com/apt-get-apt-cache-command-examples-manage-packages-debian-ubuntu-systems/
[3]: https://www.2daygeek.com/apt-command-examples-manage-packages-debian-ubuntu-systems/
[4]: https://www.2daygeek.com/pacman-command-examples-manage-packages-arch-linux-system/
[5]: https://www.2daygeek.com/yum-command-examples-manage-packages-rhel-centos-systems/
[6]: https://www.2daygeek.com/zypper-command-examples-manage-packages-opensuse-system/

View File

@ -0,0 +1,365 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (How To Set Up a Firewall with GUFW on Linux)
[#]: via: (https://itsfoss.com/set-up-firewall-gufw)
[#]: author: (Sergiu https://itsfoss.com/author/sergiu/)
How To Set Up a Firewall with GUFW on Linux
======
**UFW (Uncomplicated Firewall)** is a simple to use firewall utility with plenty of options for most users. It is an interface for the **iptables** , which is the classic (and harder to get comfortable with) way to set up rules for your network.
**Do you really need a firewall for desktop?**
![][1]
A **[firewall][2]** is a way to regulate the incoming and outgoing traffic on your network. A well-configured firewall is crucial for the security of servers.
But what about normal, desktop users? Do you need a firewall on your Linux system? Most likely you are connected to internet via a router linked to your internet service provider (ISP). Some routers already have built-in firewall. On top of that, your actual system is hidden behind NAT. In other words, you probably have a security layer when you are on your home network.
Now that you know you should be using a firewall on your system, lets see how you can easily install and configure a firewall on Ubuntu or any other Linux distribution.
### Setting Up A Firewall With GUFW
**[GUFW][3]** is a graphical utility for managing [Uncomplicated Firewall][4] ( **UFW** ). In this guide, Ill go over configuring a firewall using **GUFW** that suits your needs, going over the different modes and rules.
But first, lets see how to install GUFW.
#### Installing GUFW on Ubuntu and other Linux
GUFW is available in all major Linux distributions. I advise using your distributions package manager for installing GUFW.
If you are using Ubuntu, make sure you have the Universe Repository enabled. To do that, open up a terminal (default hotkey**:** CTRL+ALT+T) and enter:
```
sudo add-apt-repository universe
sudo apt update -y
```
Now you can install GUFW with this command:
```
sudo apt install gufw -y
```
Thats it! If you prefer not touching the terminal, you can install it from the Software Center as well.
Open Software Center and search for **gufw** and click on the search result.
![Search for gufw in software center][5]
Go ahead and click **Install**.
![Install GUFW from the Software Center][6]
To open **gufw** , go to your menu and search for it.
![Start GUFW][7]
This will open the firewall application and youll be greeted by a “ **Getting Started** ” section.
![GUFW Interface and Welcome Screen][8]
#### Turn on the firewall
The first thing to notice about this menu is the **Status** toggle. Pressing this button will turn on/off the firewall ( **default:** off), applying your preferences (policies and rules).
![Turn on the firewall][9]
If turned on, the shield icon turn from grey to colored. The colors, as noted later in this article, reflect your policies. This will also make the firewall **automatically start** on system startup.
**Note:** _**Home** will be turned **off** by default. The other profiles (see next section) will be turned **on.**_
#### Understanding GUFW and its profiles
As you can see in the menu, you can select different **profiles**. Each profile comes with different **default policies**. What this means is that they offer different behaviors for incoming and outgoing traffic.
The **default profiles** are:
* Home
* Public
* Office
You can select another profile by clicking on the current one ( **default: Home** ).
![][10]
Selecting one of them will modify the default behavior. Further down, you can change Incoming and Outgoing traffic preferences.
By default, both in **Home** and in **Office** , these policies are **Deny Incoming** and **Allow Outgoing**. This enables you to use services such as http/https without letting anything get in ( **e.g.** ssh).
For **Public** , they are **Reject Incoming** and **Allow Outgoing**. **Reject** , similar to **deny** , doesnt let services in, but also sends feedback to the user/service that tried accessing your machine (instead of simply dropping/hanging the connection).
Note
If you are an average desktop user, you can stick with the default profiles. Youll have to manually change the profiles if you change the network.
So if you are travelling, set the firewall on public profile and the from here forwards, firewall will be set in public mode on each reboot.
#### Configuring firewall rules and policies [for advanced users]
All profiles use the same rules, only the policies the rules build upon will differ. Changing the behavior of a policy ( **Incoming/Outgoing** ) will apply the changes to the selected profile.
Note that the policies can only be changed while the firewall is active (Status: ON).
Profiles can easily be added, deleted and renamed from the **Preferences** menu.
##### Preferences
In the top bar, click on **Edit**. Select **Preferences**.
![Open Preferences Menu in GUFW][11]
This will open up the **Preferences** menu.
![][12]
Lets go over the options you have here!
**Logging** means exactly what you would think: how much information does the firewall write down in the log files.
The options under **Gufw** are quite self-explanatory.
In the section under **Profiles** is where we can add, delete and rename profiles. Double-clicking on a profile will allow you to **rename** it. Pressing **Enter** will complete this process and pressing **Esc** will cancel the rename.
![][13]
To **add** a new profile, click on the **+** under the list of profiles. This will add a new profile. However, it wont notify you about it. Youll also have to scroll down the list to see the profile you created (using the mouse wheel or the scroll bar on the right side of the list).
**Note:** _The newly added profile will **Deny Incoming** and **Allow Outgoing** traffic._
![][14]
Clicking a profile highlight that profile. Pressing the **** button will **delete** the highlighted profile.
![][15]
**Note:** _You cant rename/remove the currently selected profile_.
You can now click on **Close**. Next, Ill go into setting up different **rules**.
##### Rules
Back to the main menu, somewhere in the middle of the screen you can select different tabs ( **Home, Rules, Report, Logs)**. We already covered the **Home** tab (thats the quick guide you see when you start the app).
![][16]
Go ahead and select **Rules**.
![][17]
This will be the bulk of your firewall configuration: networking rules. You need to understand the concepts UFW is based on. That is **allowing, denying, rejecting** and **limiting** traffic.
**Note:** _In UFW, the rules apply from top to bottom (the top rules take effect first and on top of them are added the following ones)._
**Allow, Deny, Reject, Limit:**These are the available policies for the rules youll add to your firewall.
Lets see exactly what each of them means:
* **Allow:** allows any entry traffic to a port
* **Deny:** denies any entry traffic to a port
* **Reject:** denies any entry traffic to a port and informs the requester about the rejection
* **Limit:** denies entry traffic if an IP address has attempted to initiate 6 or more connections in the last 30 seconds
##### Adding Rules
There are three ways to add rules in GUFW. Ill present all three methods in the following section.
**Note:** _After you added the rules, changing their order is a very tricky process and its easier to just delete them and add them in the right order._
But first, click on the **+** at the bottom of the **Rules** tab.
![][18]
This should open a pop-up menu ( **Add a Firewall Rule** ).
![][19]
At the top of this menu, you can see the three ways you can add rules. Ill guide you through each method i.e. **Preconfigured, Simple, Advanced**. Click to expand each section.
**Preconfigured Rules**
This is the most beginner-friendly way to add rules.
The first step is choosing a policy for the rule (from the ones detailed above).
![][20]
The next step is to choose the direction the rule will affect ( **Incoming, Outgoing, Both** ).
![][21]
The **Category** and **Subcategory** choices are plenty. These narrow down the **Applications** you can select
Choosing an **Application** will set up a set of ports based on what is needed for that particular application. This is especially useful for apps that might operate on multiple ports, or if you dont want to bother with manually creating rules for handwritten port numbers.
If you wish to further customize the rule, you can click on the **orange arrow icon**. This will copy the current settings (Application with its ports etc.) and take you to the **Advanced** rule menu. Ill cover that later in this article.
For this example, I picked an **Office Database** app: **MySQL**. Ill deny all incoming traffic to the ports used by this app.
To create the rule, click on **Add**.
![][22]
You can now **Close** the pop-up (if you dont want to add any other rules). You can see that the rule has been successfully added.
![][23]
The ports have been added by GUFW, and the rules have been automatically numbered. You may wonder why are there two new rules instead of just one; the answer is that UFW automatically adds both a standard **IP** rule and an **IPv6** rule.
**Simple Rules**
Although setting up preconfigured rules is nice, there is another easy way to add a rule. Click on the **+** icon again and go to the **Simple** tab.
![][24]
The options here are straight forward. Enter a name for your rule and select the policy and the direction. Ill add a rule for rejecting incoming SSH attempts.
![][25]
The **Protocols** you can choose are **TCP, UDP** or **Both**.
You must now enter the **Port** for which you want to manage the traffic. You can enter a **port number** (e.g. 22 for ssh), a **port range** with inclusive ends separated by a **:** ( **colon** ) (e.g. 81:89) or a **service name** (e.g. ssh). Ill use **ssh** and select **both TCP and UDP** for this example. As before, click on **Add** to completing the creation of your rule. You can click the **red arrow icon** to copy the settings to the **Advanced** rule creation menu.
![][26]
If you select **Close** , you can see that the new rule (along with the corresponding IPv6 rule) has been added.
![][27]
**Advanced Rules**
Ill now go into how to set up more advanced rules, to handle traffic from specific IP addresses and subnets and targeting different interfaces.
Lets open up the **Rules** menu again. Select the **Advanced** tab.
![][28]
By now, you should already be familiar with the basic options: **Name, Policy, Direction, Protocol, Port**. These are the same as before.
![][29]
**Note:** _You can choose both a receiving port and a requesting port._
What changes is that now you have additional options to further specialize our rules.
I mentioned before that rules are automatically numbered by GUFW. With **Advanced** rules you specify the position of your rule by entering a number in the **Insert** option.
**Note:** _Inputting **position 0** will add your rule after all existing rules._
**Interface** lets you select any network interface available on your machine. By doing so, the rule will only have effect on traffic to and from that specific interface.
**Log** changes exactly that: what will and what wont be logged.
You can also choose IPs for the requesting and for the receiving port/service ( **From** , **To** ).
All you have to do is specify an **IP address** (e.g. 192.168.0.102) or an entire **subnet** (e.g. 192.168.0.0/24 for IPv4 addresses ranging from 192.168.0.0 to 192.168.0.255).
In my example, Ill set up a rule to allow all incoming TCP SSH requests from systems on my subnet to a specific network interface of the machine Im currently running. Ill add the rule after all my standard IP rules, so that it takes effect on top of the other rules I have set up.
![][30]
**Close** the menu.
![][31]
The rule has been successfully added after the other standard IP rules.
##### Edit Rules
Clicking a rule in the rules list will highlight it. Now, if you click on the **little cog icon** at the bottom, you can **edit** the highlighted rule.
![][32]
This will open up a menu looking something like the **Advanced** menu I explained in the last section.
![][33]
**Note:** _Editing any options of a rule will move it to the end of your list._
You can now ether select on **Apply** to modify your rule and move it to the end of the list, or hit **Cancel**.
##### Delete Rules
After selecting (highlighting) a rule, you can also click on the **** icon.
![][34]
##### Reports
Select the **Report** tab. Here you can see services that are currently running (along with information about them, such as Protocol, Port, Address and Application name). From here, you can **Pause Listening Report (Pause Icon)** or **Create a rule from a highlighted service from the listening report (+ Icon)**.
![][35]
##### Logs
Select the **Logs** tab. Here is where youll have to check for any errors are suspicious rules. Ive tried creating some invalid rules to show you what these might look like when you dont know why you cant add a certain rule. In the bottom section, there are two icons. Clicking the **first icon copies the logs** to your clipboard and clicking the **second icon** **clears the log**.
![][36]
### Wrapping Up
Having a firewall that is properly configured can greatly contribute to your Ubuntu experience, making your machine safer to use and allowing you to have full control over incoming and outgoing traffic.
I have covered the different uses and modes of **GUFW** , going into how to set up different rules and configure a firewall to your needs. I hope that this guide has been helpful to you.
If you are a beginner, this should prove to be a comprehensive guide; even if you are more versed in the Linux world and maybe getting your feet wet into servers and networking, I hope you learned something new.
Let us know in the comments if this article helped you and why did you decide a firewall would improve your system!
--------------------------------------------------------------------------------
via: https://itsfoss.com/set-up-firewall-gufw
作者:[Sergiu][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/sergiu/
[b]: https://github.com/lujun9972
[1]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/firewall-linux.png?resize=800%2C450&ssl=1
[2]: https://en.wikipedia.org/wiki/Firewall_(computing)
[3]: http://gufw.org/
[4]: https://en.wikipedia.org/wiki/Uncomplicated_Firewall
[5]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/ubuntu_software_gufw-1.jpg?ssl=1
[6]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/ubuntu_software_install_gufw.jpg?ssl=1
[7]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/show_applications_gufw.jpg?ssl=1
[8]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw.jpg?ssl=1
[9]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_toggle_status.jpg?ssl=1
[10]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_select_profile-1.jpg?ssl=1
[11]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_open_preferences.jpg?ssl=1
[12]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_preferences.png?fit=800%2C585&ssl=1
[13]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_rename_profile.png?fit=800%2C551&ssl=1
[14]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_profile.png?ssl=1
[15]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_delete_profile.png?ssl=1
[16]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_home_tab.png?ssl=1
[17]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_rules_tab.png?ssl=1
[18]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_rule.png?ssl=1
[19]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_rules_menu.png?ssl=1
[20]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_preconfigured_rule_policy.png?ssl=1
[21]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_preconfigured_rule_direction.png?ssl=1
[22]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_preconfigured_add_rule.png?ssl=1
[23]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_preconfigured_rule_added.png?ssl=1
[24]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_simple_rules_menu.png?ssl=1
[25]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_simple_rule_name_policy_direction.png?ssl=1
[26]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_simple_rule.png?ssl=1
[27]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_simple_rule_added.png?ssl=1
[28]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_advanced_rules_menu.png?ssl=1
[29]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_advanced_rule_basic_options.png?ssl=1
[30]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_add_advanced_rule.png?ssl=1
[31]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_advanced_rule_added.png?ssl=1
[32]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_edit_highlighted_rule.png?ssl=1
[33]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_edit_rule_menu.png?ssl=1
[34]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_delete_rule.png?ssl=1
[35]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_report_tab.png?ssl=1
[36]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/03/gufw_log_tab-1.png?ssl=1
[37]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/03/firewall-linux.png?fit=800%2C450&ssl=1

View File

@ -0,0 +1,107 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (How to set up a homelab from hardware to firewall)
[#]: via: (https://opensource.com/article/19/3/home-lab)
[#]: author: (Michael Zamot (Red Hat) https://opensource.com/users/mzamot)
How to set up a homelab from hardware to firewall
======
Take a look at hardware and software options for building your own homelab.
![][1]
Do you want to create a homelab? Maybe you want to experiment with different technologies, create development environments, or have your own private cloud. There are many reasons to have a homelab, and this guide aims to make it easier to get started.
There are three categories to consider when planning a home lab: hardware, software, and maintenance. We'll look at the first two categories here and save maintaining your computer lab for a future article.
### Hardware
When thinking about your hardware needs, first consider how you plan to use your lab as well as your budget, noise, space, and power usage.
If buying new hardware is too expensive, search local universities, ads, and websites like eBay or Craigslist for recycled servers. They are usually inexpensive, and server-grade hardware is built to last many years. You'll need three types of hardware: a virtualization server, storage, and a router/firewall.
#### Virtualization servers
A virtualization server allows you to run several virtual machines that share the physical box's resources while maximizing and isolating resources. If you break one virtual machine, you won't have to rebuild the entire server, just the virtual one. If you want to do a test or try something without the risk of breaking your entire system, just spin up a new virtual machine and you're ready to go.
The two most important factors to consider in a virtualization server are the number and speed of its CPU cores and its memory. If there are not enough resources to share among all the virtual machines, they'll be overallocated and try to steal each other's CPU cycles and memory.
So, consider a CPU platform with multiple cores. You want to ensure the CPU supports virtualization instructions (VT-x for Intel and AMD-V for AMD). Examples of good consumer-grade processors that can handle virtualization are Intel i5 or i7 and AMD Ryzen. If you are considering server-grade hardware, the Xeon class for Intel and EPYC for AMD are good options. Memory can be expensive, especially the latest DDR4 SDRAM. When estimating memory requirements, factor at least 2GB for the host operating system's memory consumption.
If your electricity bill or noise is a concern, solutions like Intel's NUC devices provide a small form factor, low power usage, and reduced noise, but at the expense of expandability.
#### Network-attached storage (NAS)
If you want a machine loaded with hard drives to store all your personal data, movies, pictures, etc. and provide storage for the virtualization server, network-attached storage (NAS) is what you want.
In most cases, you won't need a powerful CPU; in fact, many commercial NAS solutions use low-powered ARM CPUs. A motherboard that supports multiple SATA disks is a must. If your motherboard doesn't have enough ports, use a host bus adapter (HBA) SAS controller to add extras.
Network performance is critical for a NAS, so select a gigabit network interface (or better).
Memory requirements will differ based on your filesystem. ZFS is one of the most popular filesystems for NAS, and you'll need more memory to use features such as caching or deduplication. Error-correcting code (ECC) memory is your best bet to protect data from corruption (but make sure your motherboard supports it before you buy). Last, but not least, don't forget an uninterruptible power supply (UPS), because losing power can cause data corruption.
#### Firewall and router
Have you ever realized that a cheap router/firewall is usually the main thing protecting your home network from the exterior world? These routers rarely receive timely security updates, if they receive any at all. Scared now? Well, [you should be][2]!
You usually don't need a powerful CPU or a great deal of memory to build your own router/firewall, unless you are handling a huge throughput or want to do CPU-intensive tasks, like a VPN server or traffic filtering. In such cases, you'll need a multicore CPU with AES-NI support.
You may want to get at least two 1-gigabit or better Ethernet network interface cards (NICs), also, not needed, but recommended, a managed switch to connect your DIY-router to create VLANs to further isolate and secure your network.
![Home computer lab PfSense][4]
### Software
After you've selected your virtualization server, NAS, and firewall/router, the next step is exploring the different operating systems and software to maximize their benefits. While you could use a regular Linux distribution like CentOS, Debian, or Ubuntu, they usually take more time to configure and administer than the following options.
#### Virtualization software
**[KVM][5]** (Kernel-based Virtual Machine) lets you turn Linux into a hypervisor so you can run multiple virtual machines in the same box. The best thing is that KVM is part of Linux, and it is the go-to option for many enterprises and home users. If you are comfortable, you can install **[libvirt][6]** and **[virt-manager][7]** to manage your virtualization platform.
**[Proxmox VE][8]** is a robust, enterprise-grade solution and a full open source virtualization and container platform. It is based on Debian and uses KVM as its hypervisor and LXC for containers. Proxmox offers a powerful web interface, an API, and can scale out to many clustered nodes, which is helpful because you'll never know when you'll run out of capacity in your lab.
**[oVirt][9] (RHV)** is another enterprise-grade solution that uses KVM as the hypervisor. Just because it's enterprise doesn't mean you can't use it at home. oVirt offers a powerful web interface and an API and can handle hundreds of nodes (if you are running that many servers, I don't want to be your neighbor!). The potential problem with oVirt for a home lab is that it requires a minimum set of nodes: You'll need one external storage, such as a NAS, and at least two additional virtualization nodes (you can run it just on one, but you'll run into problems in maintenance of your environment).
#### NAS software
**[FreeNAS][10]** is the most popular open source NAS distribution, and it's based on the rock-solid FreeBSD operating system. One of its most robust features is its use of the ZFS filesystem, which provides data-integrity checking, snapshots, replication, and multiple levels of redundancy (mirroring, striped mirrors, and striping). On top of that, everything is managed from the powerful and easy-to-use web interface. Before installing FreeNAS, check its hardware support, as it is not as wide as Linux-based distributions.
Another popular alternative is the Linux-based **[OpenMediaVault][11]**. One of its main features is its modularity, with plugins that extend and add features. Among its included features are a web-based administration interface; protocols like CIFS, SFTP, NFS, iSCSI; and volume management, including software RAID, quotas, access control lists (ACLs), and share management. Because it is Linux-based, it has extensive hardware support.
#### Firewall/router software
**[pfSense][12]** is an open source, enterprise-grade FreeBSD-based router and firewall distribution. It can be installed directly on a server or even inside a virtual machine (to manage your virtual or physical networks and save space). It has many features and can be expanded using packages. It is managed entirely using the web interface, although it also has command-line access. It has all the features you would expect from a router and firewall, like DHCP and DNS, as well as more advanced features, such as intrusion detection (IDS) and intrusion prevention (IPS) systems. You can create multiple networks listening on different interfaces or using VLANs, and you can create a secure VPN server with a few clicks. pfSense uses pf, a stateful packet filter that was developed for the OpenBSD operating system using a syntax similar to IPFilter. Many companies and organizations use pfSense.
* * *
With all this information in mind, it's time for you to get your hands dirty and start building your lab. In a future article, I will get into the third category of running a home lab: using automation to deploy and maintain it.
--------------------------------------------------------------------------------
via: https://opensource.com/article/19/3/home-lab
作者:[Michael Zamot (Red Hat)][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/mzamot
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/computer_keyboard_laptop_development_code_woman.png?itok=vbYz6jjb
[2]: https://opensource.com/article/18/5/how-insecure-your-router
[3]: /file/427426
[4]: https://opensource.com/sites/default/files/uploads/pfsense2.png (Home computer lab PfSense)
[5]: https://www.linux-kvm.org/page/Main_Page
[6]: https://libvirt.org/
[7]: https://virt-manager.org/
[8]: https://www.proxmox.com/en/proxmox-ve
[9]: https://ovirt.org/
[10]: https://freenas.org/
[11]: https://www.openmediavault.org/
[12]: https://www.pfsense.org/

View File

@ -0,0 +1,58 @@
[#]: collector: (lujun9972)
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Get started with CryptPad, an open source collaborative document editor)
[#]: via: (https://opensource.com/article/19/1/productivity-tool-cryptpad)
[#]: author: (Kevin Sonney https://opensource.com/users/ksonney (Kevin Sonney))
开始使用 CryptPad一个开源的协作文档编辑器
======
使用 CryptPad 安全地共享你的笔记、文档、看板等,这是我们在开源工具系列中的第 5 个工具,它将使你在 2019 年更高效。
![](https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/web_browser_desktop_devlopment_design_system_computer.jpg?itok=pfqRrJgh)
每年年初似乎都有疯狂的冲动,想方设法提高工作效率。新年的决议,开始一年的权利,当然,“与旧的,与新的”的态度都有助于实现这一目标。通常的一轮建议严重偏向封闭源和专有软件。它不一定是这样。
这是我挑选出的 19 个新的(或者对你而言新的)开源工具中的第 5 个工具来帮助你在 2019 年更有效率。
### CryptPad
我们已经介绍过 [Joplin][1],它能很好地保存自己的笔记,但是,你可能已经注意到,它没有任何共享或协作功能。
[CryptPad][2] 是一个安全、可共享的笔记应用和文档编辑器,它能够安全地协作编辑。与 Joplin 不同,它是一个 NodeJS 应用,这意味着你可以在桌面或其他服务器上运行它,并使用任何现代 Web 浏览器访问。它开箱即用它支持富文本、Markdown、投票、白板看板和 PPT。
![](https://opensource.com/sites/default/files/uploads/cryptpad-1.png)
它支持不同的文档类型且功能齐全。它的富文本编辑器涵盖了你所期望的所有基础功能,并允许你将文件导出为 HTML。它的 Markdown 的编辑能与 Joplin 相提并论,它的看板虽然不像 [Wekan][3] 那样功能齐全,但也做得不错。其他支持的文档类型和编辑器也很不错,并且有你希望在类似应用中看到的功能,尽管投票功能显得有些粗糙。
![](https://opensource.com/sites/default/files/uploads/cryptpad-2.png)
然而CryptPad 的真正强大之处在于它的共享和协作功能。共享文档只需在“共享”选项中获取可共享 URLCryptPad 支持使用 iframe 标签嵌入其他网站的文档。可以在“编辑”或“查看”模式下使用密码和会过期的链接共享文档。内置聊天能够让编辑者相互交谈(请注意,具有浏览权限的人也可以看到聊天但无法发表评论)。
![](https://opensource.com/sites/default/files/pictures/cryptpad-3.png)
所有文件都使用用户密码加密存储。服务器管理员无法读取文档,这也意味着如果你忘记或丢失了密码,文件将无法恢复。因此,请确保将密码保存在安全的地方,例如放在[密码保险箱][4]中。
![](https://opensource.com/sites/default/files/uploads/cryptpad-4.png)
当它在本地运行时CryptPad 是一个用于创建和编辑文档的强大应用。当在服务器上运行时,它成为了用于多用户文档创建和编辑的出色协作平台。在我的笔记本电脑上安装它不到五分钟,并且开箱即用。开发者还加入了在 Docker 中运行 CryptPad 的说明,并且还有一个社区维护用于方便部署的 Ansible 角色。CryptPad 不支持任何第三方身份验证因此用户必须创建自己的帐户。如果你不想运行自己的服务器CryptPad 还有一个社区支持的托管版本。
--------------------------------------------------------------------------------
via: https://opensource.com/article/19/1/productivity-tool-cryptpad
作者:[Kevin Sonney][a]
选题:[lujun9972][b]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/ksonney (Kevin Sonney)
[b]: https://github.com/lujun9972
[1]: https://opensource.com/article/19/1/productivity-tool-joplin
[2]: https://cryptpad.fr/index.html
[3]: https://opensource.com/article/19/1/productivity-tool-wekan
[4]: https://opensource.com/article/18/4/3-password-managers-linux-command-line