Month: November 2021

All the ‘tips of the day’ LibreOffice

On this page, I have collected all the “Tips of the Day” that LibreOffice displays once a day when the program starts.

A few notes:

  • the lines are taken from the latest version of the program and will be updated as new versions of LibreOffice are released
  • in some tips the text or link is missing – I checked the source code files – there the text is the same
  • some numbers are missing – apparently, this is due to the fact that “Tips of the Day” is constantly updated. For example, in the previous version of the program there were more than 300, and in the last at the time of writing, a little more than 200

If you have your own interesting tips on using LibreOffice, then share them in the comments!

# Tips
Tip # 1 LibreOffice offers a variety of user interface options to make you feel at home
Tip # 2 Need to allow changes to parts of a read-only document in Writer? Insert frames or sections that can authorize changes. https://help.libreoffice.org/latest/en-US/text/swriter/guide/section_edit.html
Tip # 3 To print the notes of your slides go to File ▸ Print ▸ Impress tab and select Notes under Document ▸ Type.
Tip # 4 To start temporarily with a fresh user profile, or to restore a non-working LibreOffice, use Help ▸ Restart in Safe Mode. https://help.libreoffice.org/latest/en-US/text/shared/01/profile_safe_mode.html
Tip # 5 Writing a book? LibreOffice master document lets you manage large documents as a container for individual LibreOffice Writer files.
Tip # 6 You can create editable Hybrid PDFs with LibreOffice. https://wiki.documentfoundation.org/Documentation/HowTo/CreateAHybridPDF
Tip # 7 Explore the ten different functions in the status bar (at the bottom of the document window). Place the cursor over each field for an explanation. If not visible, use View ▸ Status Bar.
Tip # 8 Want to sum a cell through several sheets? Refer to the range of sheets e.g. =SUM(Sheet1.A1:Sheet3.A1).
Tip # 9 You can create fillable form documents (even PDFs) with LibreOffice. https://www.techrepublic.com/article/how-to-create-interactive-pdfs-with-libreoffice
Tip # 10 Cannot see all the text in a cell? Expand the input line in the formula bar and you can scroll.
Tip # 11 Optimize your table layout with Table ▸ Size ▸ Distribute Rows / Columns Evenly.
Tip # 12 Find all expressions in brackets per Edit ▸ Find and Replace ▸ Find ▸ \([^)]+\) (check “Regular expressions”)
Tip # 13 Select a different icon set from Tools ▸ Options ▸ LibreOffice ▸ View ▸ User Interface ▸ Icon style.
Tip # 14 You can display a number as a fraction (0.125 = 1/8): Format ▸ Cells, Number ▸ Fraction.
Tip # 15 To remove a hyperlink but keep its text, right-click on the hyperlink, and use “Remove Hyperlink”.
Tip # 16 To remove several hyperlinks at once, select the text with the hyperlinks, then right-click and use “Remove Hyperlink”.
Tip # 17 To zoom a selection to fit the entire window in Draw, use the / (divide key) on the number pad.
Tip # 18 Click a column field (row) PivotTable and press F12 to group data. Choices adapt to content: Date (month, quarter, year), number (classes)
Tip # 19 You can restart the slide show after a pause specified at Slide Show ▸ Slide Show Settings ▸ Loop and repeat.
Tip # 20 To distribute some text in multi-columns select the text and apply Format ▸ Columns.
Tip # 21 Use View ▸ Value Highlighting to display cell contents in colors: Text/black, Formulas/green, Numbers/blue, Protected cells/grey background. https://help.libreoffice.org/latest/en-US/text/scalc/01/03080000.html
Tip # 22 You can create different master pages in a presentation template: View ▸ Master Slide and Slide ▸ New Master (or per toolbar or right click in slide pane).
Tip # 23 Want to sort a pivot table? Click on drop-list’s arrow in the row/col header and select sort method: ascending, descending, or custom.
Tip # 24 Display photos or images with different shapes in Writer. Insert and select shape, then Insert ▸ Image. To adjust image, right-click on selected shape and choose Area.
Tip # 25 Use Page/Slide ▸ Properties ▸ “Fit object to paper format” in Draw/Impress to resize the objects so that they fit on your chosen paper format.
Tip # 26 Fit the entire page in a Draw window, use * on the number pad.
Tip # 27 In a Draw page, use “-” to zoom out; “+” to zoom in.
Tip # 28 Want to show the contents of another document within your document? Use Insert ▸ Section and select Link. https://help.libreoffice.org/latest/en-US/text/swriter/guide/section_insert.html#par_id3153404
Tip # 29 To automatically number table rows in Writer, select the relevant column, then apply a List Style. https://help.libreoffice.org/latest/en-US/text/swriter/01/05130004.html
Tip # 30 LibreOffice allows you to use assistive tools, such as external screen readers, Braille devices or speech recognition input devices. https://www.libreoffice.org/get-help/accessibility/
Tip # 31 Want to sort a series in LibreOffice Calc such as A1, A2, A3, A11, A15, not in alphabetical order but on the number? Enable natural sort in the Options tab. https://help.libreoffice.org/latest/en-US/text/scalc/01/12030200.html
Tip # 32 You can change the default function in the status bar: right click on the area.
Tip # 33 Want to add many of the same shapes in Draw/Impress? Double-click a tool in the drawing toolbar to use it for repeated tasks.
Tip # 34 CTRL+Shift+F9 recalculates all formulas in all spreadsheets.
Tip # 35 Want to keep a part of an editable document as read-only? Insert ▸ Section. Add text to the section, then right-click “Edit Section” and check “Protect”.
Tip # 36 Use the Backspace key instead of Delete in Calc. You can choose what to delete.
Tip # 37 Best way to fix bad-looking MS Word table cells via Table ▸ Size ▸ Optimal Row Height / Column Width.
Tip # 38 To repeat a table heading when a table spans over a page, use Table ▸ Table Properties ▸ Text Flow ▸ Repeat heading.
Tip # 39 To quickly insert or delete rows, select the desired number of rows (or columns) and press CTRL+ to add or CTRL- to delete.
Tip # 40 To repeat rows/columns on every pages use Format ▸ Print Ranges ▸ Edit.
Tip # 41 Insert images and photos into shapes in Draw and Impress. Right-click on a shape, choose Area ▸ Image ▸ Add/Import, and use Options to adjust appearance.
Tip # 42 Need to insert the date in a spreadsheet cell? Type CTRL+; or Shift+CTRL+; to insert the time.
Tip # 43 Insert your metadata in your document with Insert ▸ Fields ▸ More Fields… ▸ Document or DocInformation.
Tip # 44 Get help from the community via the Ask portal. https://ask.libreoffice.org/
Tip # 45 Use Shift+Space to select the current row and CTRL+Space to select the current column.
Tip # 46 You can move an object to another layer by holding it until its edges flash, then drag it to the tab of the layer you want to move it to.
Tip # 47 Data ▸ Validity allows you to create drop-down lists where the user selects a value instead of typing. https://help.libreoffice.org/latest/en-US/text/scalc/guide/validity.html
Tip # 48 Hold down CTRL and turn the mouse wheel to change the zoom factor.
Tip # 49 LibreOffice has great extensions to increase your productivity—check them out. https://extensions.libreoffice.org/
Tip # 50 Want to count words for just one particular paragraph style? Use Edit ▸ Find and Replace, click Paragraph Styles, select the style in Find, and click Find All. Read the result in the status bar.
Tip # 51 Generate fully customized PDF documents with the exact format, image compression, comments, access rights, password, etc., via File ▸ Export as PDF.
Tip # 52 Writer includes LibreLogo: simple Logo-like programming environment with turtle vector graphics, DTP and graphic design. https://help.libreoffice.org/latest/en-US/text/swriter/librelogo/LibreLogo.html
Tip # 53 Construct your own 2D shapes in Draw. Select two or more objects, and explore possibilities with Shape ▸ Combine, Shape ▸ Merge, Shape ▸ Subtract, and Shape ▸ Intersect. https://help.libreoffice.org/latest/en-US/text/sdraw/guide/combine_etc.html
Tip # 54 Do you plan to change your computer and want to recover your customizations? See: https://wiki.documentfoundation.org/UserProfile
Tip # 55 You can toggle between the field names and the actual value with View ▸ Fields Names (or CTRL+F9).
Tip # 56 Show or hide comments in Writer by clicking the comment toggle button in the ruler.
Tip # 57 To enable macro recording, check Tools ▸ Options ▸ LibreOffice ▸ Advanced ▸ Enable macro recording.
Tip # 58 Want to insert a placeholder for an image in a Writer template? Use Insert ▸ Fields ▸ More fields, click Functions tab, choose PlaceHolder for Type and Image for Format.
Tip # 59 LibreOffice supports four macro security levels (from low to very high) and trusted sources. https://help.libreoffice.org/latest/en-US/text/shared/optionen/01030300.html
Tip # 60 Did you know that you can attach comments to portions of text? Just use the shortcut CTRL+ALT+C.
Tip # 61 Need to move one or more paragraphs? No need to cut and paste: Use the keyboard shortcut CTRL+ALT+Arrow (Up/Down)
Tip # 62 Change the basic fonts for the predefined template or current document per Tools ▸ Options ▸ LibreOffice Writer ▸ Basic Fonts. https://help.libreoffice.org/latest/en-US/text/shared/optionen/01040300.html
Tip # 63 Want to find words containing more than 10 characters? Edit ▸ Find and Replace ▸ Search ▸ [a-z]{10,} ▸ Other Options ▸ check Regular expressions.
Tip # 64 Open a CSV file as a new sheet in the current spreadsheet via Sheet ▸ Sheet from file.
Tip # 65 Typing in bold, italics, or underlined in Writer you can continue with the default attributes using just the shortcut CTRL+Shift+X (remove direct character formats).
Tip # 66 Use CTRL+ALT+Shift+V to paste the contents of the clipboard as unformatted text.
Tip # 67 Customize footnote appearance with Tools ▸ Footnotes and Endnotes…
Tip # 68 With Slide Show ▸ Custom Slide Show, reorder and pick slides to fit a slideshow to the needs of your viewers.
Tip # 69 Want to change spell checking for some part of the text? Click in the language zone of the status bar or better, apply a style.
Tip # 70 Writer can insert a blank page between two odd (even) pages that follow. Check “Print automatically inserted blank pages” in the print dialog’s LibreOffice Writer tab.
Tip # 71 You do not want to print all columns? Hide or group the ones you do not need.
Tip # 72 To modify an AutoPlay presentation, open it and after it starts, right click and select Edit in the context menu.
Tip # 73 Need to precisely position? ALT+arrow Keys move objects (shapes, pictures, formulas) by one pixel.
Tip # 74 Embedded help is available by pressing F1, if you have installed it. Otherwise check online at: https://help.libreoffice.org/
Tip # 75 Right-click in the status bar in LibreOffice Calc and select “Selection count” to display the number of selected cells.
Tip # 76 Want to have two or more columns for just a part of a LibreOffice Writer page? Insert ▸ Section, set with Columns tab, and place text in that section.
Tip # 77 Use Data ▸ Statistics for sampling, descriptive statistics, analysis of variance, correlation, and much more in LibreOffice Calc.
Tip # 78 You can copy from one sheet to another without the clipboard. Select the area to copy, CTRL+click the target sheet’s tab and use Sheet ▸ Fill Cells ▸ Fill Sheets.
Tip # 79 You can change the look of LibreOffice via Tools ▸ Options ▸ View ▸ User Interface.
Tip # 80 In LibreOffice Impress, use Insert ▸ Media ▸ Photo Album to create a slideshow from a series of pictures with the “Photo Album” feature.
Tip # 81 You can show formulas instead of results with View ▸ Show Formula (or Tools ▸ Options ▸ LibreOffice Calc ▸ View ▸ Display ▸ Formulas).
Tip # 82 LibreOffice is developed by a friendly community, made up of hundreds of contributors around the world. Join us with your skills beyond coding. https://www.libreoffice.org/community/get-involved/
Tip # 83 Left-handed? Enable Tools ▸ Options ▸ Language Settings ▸ Languages ▸ Asian and check Tools ▸ Options ▸ LibreOffice Writer ▸ View ▸ Ruler ▸ Right-aligned, which displays the scrollbar to the left.
Tip # 84 Want your chapter titles to always begin a page? Edit Heading1 (paragraph style) ▸ Text Flow ▸ Breaks and check Insert ▸ Page ▸ Before.
Tip # 85 Date/time value is just a number of days since a chosen day zero; in the number, integer part represents date, and fractional part is time (elapsed part of a day), with 0.5 representing noon.
Tip # 86 Shift+CTRL+Del deletes from cursor to the end of the current sentence.
Tip # 87 Use column or row labels in formulas. For example, if you have two columns, “Time” and “KM”, use =Time/KM to get minutes per kilometer.
Tip # 88 Annoyed by the “marching ants” around cells in Calc? Press escape to stop them; the copied content will remain available for pasting.
Tip # 89 Want to become a LibreOffice Ambassador? There are certifications for developers, admins, and trainers. https://www.documentfoundation.org/certification/program/
Tip # 90 Mix portrait and landscape orientations in a Calc spreadsheet by applying different page styles on sheets.
Tip # 91 Click on the special character icon in the toolbar to get quick access to favorite and recent characters to insert.
Tip # 92 Choose “Hierarchical View” in the Styles sidebar to see the relation between styles.
Tip # 93 You can use styles to make the tables in your document consistent. Choose one from the predefined per Styles (F11) or via Table ▸ AutoFormat.
Tip # 94 Configure use of the CTRL key to open hyperlinks? Tools ▸ Options ▸ LibreOffice ▸ Security ▸ Options ▸ “CTRL+click required to open hyperlinks”.
Tip # 95 You would like to view the calculation of individual elements of a formula, select the respective elements and press F9.
Tip # 96 You can protect cells with Format ▸ Cells ▸ Protection. To prevent insert, delete, rename, move/copy of sheets use Tools ▸ Protect Sheet. https://help.libreoffice.org/latest/en-US/text/scalc/guide/cell_protect.html
Tip # 97 Write along a curve? Draw the line, double click, type the text, Format ▸ Text Box and Shape ▸ Fontwork.
Tip # 98 Want to display only the highest values in a spreadsheet? Select menu Data ▸ AutoFilter, click the drop-down arrow, and choose “Top10”.
Tip # 99 To remove the page number from your table of contents go to Insert ▸ Table of Contents (or right-click and Edit the previously inserted index). In the Entries tab delete the page number (#) from Structure line.
Tip # 100 With the Navigator you can select & move up/down headings and the text below the heading, in the Navigator and in the document.
Tip # 101 To quickly get a math object in Writer type your formula, mark it, and use Insert ▸ Object ▸ Formula to convert the text.
Tip # 102 With LibreOffice it is very easy to install a new dictionary: they are supplied as extensions. https://extensions.libreoffice.org/?q=&Tags[]=50
Tip # 103 LibreOffice has a portable version which gives you mobility. Even without administrator rights on your computer you can install LibreOffice Portable to your hard drive too. https://www.libreoffice.org/download/portable-versions/
Tip # 104 Writer lets you number your footnotes per page, chapter, document: Tools ▸ Footnotes and Endnotes ▸ Footnotes tab ▸ Counting.
Tip # 105 Your Writer document does not reopen with the text cursor at the same editing position it was when you saved it? Add First or Last name in Tools ▸ Options ▸ LibreOffice ▸ User Data ▸ First/last name.
Tip # 106 Citation management? Use a 3rd party extension. https://wiki.documentfoundation.org/Referencing_Systems_in_LibreOffice
Tip # 107 Want to insert a value in the same place on several sheets? Select the sheets: hold down CTRL key and click their tabs before entering.
Tip # 108 Want to hide some text in a document? Select the text. Insert ▸ Section, and select “Hide”. https://help.libreoffice.org/latest/en-US/text/swriter/guide/hidden_text.html#hd_id3148675
Tip # 109 You can customize the middle mouse button per Tools ▸ Options ▸ LibreOffice ▸ View ▸ Middle Mouse button.
Tip # 110 Want to print two portrait pages on a landscape one (reducing A4 to A5)? File ▸ Print and select 2 at “Pages per sheet”.
Tip # 111 For quick access to your document bookmarks, right-click on the page number of the status bar (lower-left corner of document window).
Tip # 112 Select an object in the document background via the Select tool in the Drawing toolbar to surround the object to select.
Tip # 113 Define texts that you often use as AutoText. You will be able to insert them by their name, shortcut or toolbar in any Writer document. https://help.libreoffice.org/latest/en-US/text/swriter/guide/autotext.html
Tip # 114 Play music throughout a slideshow by assigning the sound to the first slide transition without clicking the “Apply to All Slides” button.
Tip # 115 LibreOffice Calc does not calculate from left to right but respects the order Parentheses – Exponents – Multiplication – Division – Addition – Subtraction.
Tip # 116 Get LibreOffice documentation and free user guide books at: https://documentation.libreoffice.org/
Tip # 117 Want to remove all <> at once and keep the text inside? Edit ▸ Find and Replace: Search = [<>], Replace = blank and check “Regular expressions” under Other options. https://help.libreoffice.org/latest/en-US/text/shared/01/02100001.html
Tip # 118 Need to present a report written with Writer? File ▸ Send ▸ Outline to Presentation automatically creates a slideshow from the outline.
Tip # 119 Want to manage the presentation of hyperlinks in a spreadsheet? Insert them with the HYPERLINK function. https://help.libreoffice.org/latest/en-US/text/scalc/01/04060109.html
Tip # 120 Uncheck Tools ▸ Options ▸ LibreOffice Calc ▸ View ▸ Zoom: “Synchronize sheets” so that each sheet in Calc has its own zoom factor.
Tip # 121 You can set a color for each tab: right-click the tab or use Sheet ▸ Sheet Tab Color.
Tip # 122 Trace cells used in a formula, precedents (Shift+F9) or dependents (Shift+F5) (or use Tools ▸ Detective). For each hit you go one more step in the chain. https://help.libreoffice.org/latest/en-US/text/scalc/01/06030000.html
Tip # 123 Insert and number your formulas in one step: type fn then F3. An AutoText is inserted with formula and number aligned in a table.
Tip # 124 You can create an illustration index from object names, not only from captions. https://help.libreoffice.org/latest/en-US/text/shared/01/05190000.html
Tip # 125 Use your Android or iPhone to remotely control your Impress presentation. https://help.libreoffice.org/latest/en-US/text/simpress/guide/impress_remote.html
Tip # 126 Want to know how many days there are in the current month? Use the DAYSINMONTH(TODAY()) function.
Tip # 127 Your numbers are displayed as ### in your spreadsheet? The column is too narrow to display all digits.
Tip # 128 Enable massive parallel calculations of formula cells via Tools ▸ Options ▸ OpenCL. https://help.libreoffice.org/latest/en-US/text/shared/optionen/opencl.html
Tip # 129 Use the Connector tool from the Drawing toolbar in Draw/Impress to create nice flow charts and optionally copy/paste the object into Writer.
Tip # 130 Your donations support our worldwide community. https://www.libreoffice.org/donate/
Tip # 131 You want to add x months to a date? Use =EDATE(date;months)https://help.libreoffice.org/latest/en-US/text/scalc/01/func_edate.html
Tip # 132 To select a contiguous range of cells containing data and bounded by empty row and columns use CTRL+* (numeric key pad).
Tip # 133 Your date acceptance pattern is inappropriate? Use Tools ▸ Options ▸ Language Settings ▸ Language ▸ Date acceptance patterns to tweak the pattern.
Tip # 134 Want to export formulas to CSV? File ▸ Save As ▸ Type:Text CSV, check “Edit filter settings”, and check “Save cell formulas” in the next dialog.
Tip # 135 The presenter console is a great feature when working with LibreOffice Impress. Have you checked it out? https://help.libreoffice.org/latest/en-US/text/simpress/guide/presenter_console.html
Tip # 136 To delete multiple comments, select cells with comments and use Sheet ▸ Cell Comments ▸ Delete Comment.
Tip # 137 Easily convert your documents to PDF with one click by clicking on the PDF icon in the toolbar.
Tip # 138 Want to select a large range of cells without scrolling? Type the range reference (e.g. A1:A1000) in the name box then Enter.
Tip # 139 Want to know the valid command line parameters? Start soffice with --help or -h or -? https://help.libreoffice.org/latest/en-US/text/shared/guide/start_parameters.html
Tip # 140 Fit your sheet or print ranges to a page with Format ▸ Page ▸ Sheet Tab ▸ Scaling Mode.
Tip # 141 Need to include a list item without a bullet or number? Use “Insert Unnumbered Entry” in the Bullets and Numbering toolbar.
Tip # 142 You can rotate cells table orientation with Table ▸ Properties… ▸ Text Flow ▸ Text orientation.
Tip # 143 In LibreOffice Draw to change the 0/0 point of the rulers, drag the intersection of the two rulers in the top left corner into the workspace.
Tip # 144 Move a column in Calc between two others in one step? Click the header then a cell in the column, keep mouse button and move to the target with ALT key.
Tip # 145 Automatically mark alphabetical index entries using a concordance file. https://help.libreoffice.org/latest/en-US/text/swriter/guide/indices_index.html
Tip # 146 Use Format ▸ Align (or the context menu) for precise positioning of objects in Draw/Impress: it centers on the page if one object is selected or works on the group respectively.
Tip # 147 Do not use tabs to space items on a Writer document. Depending on what you are trying to do, a borderless table can be a better choice.
Tip # 148 No need to scroll through the list at Tools ▸ Customize ▸ Keyboard to find a shortcut: just type it.
Tip # 149 LibreOffice can automatically add a numbered caption when you insert objects. See Tools ▸ Options ▸ LibreOffice Writer ▸ AutoCaption. https://help.libreoffice.org/latest/en-US/text/shared/optionen/01041100.html
Tip # 150 With LibreOffice you can use your Google Mail account to do a mail merge. Fill in Tools ▸ Options ▸ LibreOffice Writer ▸ Mail Merge Email. https://help.libreoffice.org/latest/en-US/text/swriter/guide/form_letters_main.html
Tip # 151 Keep column headers of a sheet visible when scrolling lines via View ▸ Freeze Cells ▸ Freeze First Row.
Tip # 152 You want to start working with Basic macros? Take a look at the examples under Tools ▸ Macros ▸ Edit Macros.
Tip # 153 Apply Heading paragraph styles in Writer with shortcut keys: CTRL+1 applies Heading 1, CTRL+2 applies Heading 2, etc.
Tip # 154 Do not get lost in large documents. Use the Navigator (F5) to find your way through the content.
Tip # 155 Edit ▸ Find and Replace lets you insert special characters directly: right click in input fields or press Shift+CTRL+S.
Tip # 156 Need custom contents for metadata properties? File ▸ Properties ▸ Custom Properties tab lets you create what you want.
Tip # 157 Want to see, but not print, an object in Draw? Draw it on a layer for which the “Printable” flag is not set (right click on the tab and “Modify Layer”).
Tip # 158 To insert the current date in your document, use Insert ▸ Field ▸ Date.
Tip # 159 Got many images in your Writer document? Speed up the display by disabling View ▸ Images and charts.
Tip # 160 Use Sheet ▸ Fill Cells ▸ Random Number to generate a random series based on various distributions. https://help.libreoffice.org/latest/ru/text/scalc/01/02140700.html
Tip # 161 Rename your slides in Impress to help you define “Go to page” interactions and to have a summary more explicit than Slide1, Slide2…
Tip # 162 Chapter numbering dialog lets you set text to be displayed before the chapter number. For example, type “Chapter ” to display “Chapter 1”
Tip # 163 Transpose a Writer table? Copy and paste in Calc, transpose with copy/paste special then copy/paste special ▸ Formatted text in Writer.
Tip # 164 To get the “Vertical Text” tool in the Drawing toolbar, check Tools ▸ Options ▸ Language Settings ▸ Languages ▸ Default languages ▸ Asian (and make the button visible with right-click).
Tip # 165 To quickly zoom in on range selection, right click on the zoom part of the status bar and choose Optimal.
Tip # 166 You can sign existing PDF files and also verify those signatures. https://help.libreoffice.org/latest/en-US/text/shared/guide/digital_signatures.html
Tip # 167 Often create one document from another? Consider using a template.
Tip # 168 Use Format ▸ Conditional Formatting ▸ Manage in Calc to find out which cells have been defined with conditional formatting. https://help.libreoffice.org/latest/en-US/text/scalc/01/05120000.html
Tip # 169 Tools ▸ Detective ▸ Mark Invalid Data highlights all cells in the sheet that contain values outside the validation rules. https://help.libreoffice.org/latest/en-US/text/scalc/01/06030800.html
Tip # 170 Use font embedding for greater interoperability with other office suites at File ▸ Properties ▸ Font.
Tip # 171 To convert a formula into static values you do not need to copy/paste; use Data ▸ Calculate ▸ Formula to Value.
Tip # 172 You can reformat all comments in a document by clicking the down arrow in a comment and choose “Format all Comments”.
Tip # 173 Want the same layout for the screen display and printing? Check Tools ▸ Options ▸ LibreOffice Calc ▸ General ▸ Use printer metrics for text formatting.
Tip # 174 Writer helps you to make backups: with File ▸ Save a Copy you create a new document continuing to work on the original.
Tip # 175 When you have created a Style based on another, you can enter a percentage value or a point value (e.g. 110% or −2pt or +5pt).
Tip # 176 To copy a comment without losing the content of the target cell you should use Paste Special and uncheck everything except “Comments” in dialog. Use Operations “Add” to not override existing content.
Tip # 177 Batch convert your MS Office documents to OpenDocument format by the Document Converter wizard in menu File ▸ Wizards ▸ Document converter.
Tip # 178 When editing a cell in place, you can right click and Insert fields: Date, Sheet name, Document title, etc.
Tip # 179 Need to move a Writer table? Table ▸ Select ▸ Table and Insert ▸ Frame ▸ Frame and move where you want.
Tip # 180 With Tools ▸ AutoText ▸ AutoText ▸ Import you can select a Word document or a template containing the AutoText entries that you want to import.
Tip # 181 Do not insert manual breaks to separate two paragraphs. Rather change Indents & Spacing ▸ Spacing ▸ Below paragraph at the style/paragraph properties.
Tip # 182 Keep the zeros before a number by using the “leading zeroes” cell format option or format the cell as text before entering the number.
Tip # 183 Want to return to default after applying a list style? Click Bullets or Numbering On/Off tool on the Formatting toolbar.
Tip # 184 Delete all of your printing areas in one step: select all sheets, then Format ▸ Print Ranges ▸ Clear.
Tip # 185 Add background images to spreadsheets via Insert ▸ Image or drag a background from the Gallery, then Format ▸ Arrange ▸ To Background.
Tip # 186 Having trouble pasting text from PDF files or webpages into documents? Try to paste as unformatted text (CTRL+ALT+Shift+V).
Tip # 187 In Calc use TRIMMEAN() to return the mean of a data set excluding the highest and lowest values. https://help.libreoffice.org/latest/en-US/text/scalc/01/04060182.html?DbPAR=CALC#bm_id3152966
Tip # 188 The 4th optional parameter of VLOOKUP Calc function indicates whether the first column of data is sorted. If not, enter FALSE or zero.
Tip # 189 Toolbars are contextual—they open depending on the context. If you do not want that, uncheck them from View ▸ Toolbars.
Tip # 190 You can create a master document from the current Writer document by using File ▸ Send ▸ Create Master Document.
Tip # 191 Want to center cells on a printed page in Calc? Format ▸ Page, Page ▸ Layout settings ▸ Table alignment.
Tip # 192 Frames can be linked so that the text can flow from one to the other as in desktop publishing. https://help.libreoffice.org/latest/en-US/text/swriter/guide/text_frame.html
Tip # 193 You can create a chart based on a Writer table by clicking in the table and choosing Insert ▸ Chart.
Tip # 194 Select options in Tools ▸ Options ▸ LibreOffice Writer ▸ Formatting Aids ▸ Display to specify which non-printing characters are displayed.
Tip # 195 Want to jump to a particular page by its number? Click the left-most statusbar entry or use Edit ▸ Go To Page… or press CTRL+G.
Tip # 196 LibreOffice supports over 150 languages. https://wiki.documentfoundation.org/Language_support_of_LibreOffice
Tip # 197 Uncheck Slide Show ▸ Settings ▸ Presentation always on top if you need another program displays its window to the front of your presentation.
Tip # 198 Want to find the words in bold in a Writer document? Edit ▸ Find and Replace ▸ Other options ▸ Attributes ▸ Font weight. https://help.libreoffice.org/latest/en-US/text/swriter/guide/finding.html
Tip # 199 You can sort paragraphs or table rows alphabetically or numerically per Tools ▸ Sort. https://help.libreoffice.org/latest/en-US/text/swriter/01/06100000.html
Tip # 200 To insert a paragraph before (after) a section, press ALT+Enter at the beginning (end) of the section.
Tip # 201 LibreOffice has a template center to create good looking documents—check it out. https://extensions.libreoffice.org/?q=&Tags[]=118
Tip # 202 Calculate loan repayments with Calc: eg. PMT(2%/12;36;2500) interest rate per payment period 2%/12, 36 months, loan amount 2500. https://help.libreoffice.org/latest/en-US/text/scalc/01/04060119.html?DbPAR=CALC#bm_id3149577
Tip # 203 Cannot find what you want with the VLOOKUP function in Calc? With INDEX and MATCH you can do anything! https://help.libreoffice.org/latest/en-US/text/scalc/01/04060109.html
Tip # 204 Want to show hidden column A? Click a cell in column B, press the left mouse button, move the mouse to the left, release. Then switch it on via Format ▸ Columns ▸ Show.
Tip # 205 To change the number of a page in Writer, go to the properties of the first paragraph and at the Text Flow tab check Break ▸ Insert and enter the number.
Tip # 206 Run LibreOffice in any browser via rollApp. https://www.rollapp.com/app/lowriter
Tip # 207 Strange error code in Calc, Err: followed by a number? This page gives the explanation: https://help.libreoffice.org/latest/en-US/text/scalc/05/02140000.html
Tip # 208 Include a paragraph that is not a title in the table of contents by changing Outline & Numbering in the paragraph settings to an outline level.
Tip # 209 Apart from table of contents, LibreOffice can create Alphabetical, Illustrations, Tables, Objects, Bibliography, User-Defined indexes. https://help.libreoffice.org/latest/en-US/text/swriter/guide/indices_toc.html
Tip # 210 Unable to modify or delete a custom cell style? Check all sheets, none should be protected.
Tip # 211 You need to fill a series? Select the cell range and Sheet ▸ Fill Cells ▸ Fill Series and choose between Linear, Growth, Date and AutoFill. https://help.libreoffice.org/latest/en-US/text/scalc/guide/calc_series.html
Tip # 212 Want to know if a cell is referred in formulas of other cells? Tools ▸ Detective ▸ Trace Dependents (Shift+F5).
Tip # 213 In the replace input field of auto correct options you can use the wildcards .*
Tip # 214 Want to duplicate the above line? Press CTRL+D or use Sheet ▸ Fill Cells ▸ Fill Down.
Tip # 215 To search in several spreadsheets, select them before you start the search.
Tip # 216 Drag & drop cells from Calc into the normal view of a slide creates a table; into the outline view, each cell creates a line in the outline.
Tip # 217 LibreOffice helps you not to enter two or more spaces in Writer. Check Tools ▸ AutoCorrect ▸ AutoCorrect Options ▸ Options ▸ Ignore double spaces.
Tip # 218 Want the cursor to go into the cell to the right, after entering a value in Calc? Use the Tab key instead of Enter.
Tip # 219 To display the scrollbar to the left, enable Tools ▸ Options ▸ Language Settings ▸ Languages ▸ Complex text and check Sheet ▸ Right-To-Left.
Tip # 220 Drag a formatted object to the Styles and Formatting window. A dialog box opens, just enter the name of the new style.
Tip # 221 New versions of LibreOffice provide new features, bug fixes, and security patches. Keep your software updated!
Tip # 222 Developing new XSLT and XML filters? https://fridrich.blogspot.com/2013/08/extending-swiss-army-knife-overview.html
Tip # 223 Press Shift+F1 to see any available extended tooltips in dialog boxes, when "Extended tips" is not enabled in Tools ▸ Options ▸ LibreOffice ▸ General. https://help.libreoffice.org/latest/en-US/text/shared/05/00000120.html

 

Where is the Normal.dotm analog for LibreOffice located

In the office suite MS Office there is such a concept as a template, for example, for Word this file is called Normal.dotm. In this template, you can customize styles, enter text, and make formatting settings.

The saved template can replace the Normal.dotm file and then all newly created documents will have the properties made in the template.

Alternatively, you can create multiple .dotm files with different names and different settings and use them all as templates.

LibreOffice also has template support, but there is no exact equivalent of Normal.dotm from MS Office. Nevertheless, LibreOffice even surpasses MS Office in terms of the functions of working with templates.

You can also use templates, and instead of searching and replacing the Normal.dotm file, you can make all the settings in the graphical interface.

You can create any number of templates and choose any of them as the default.

Start by opening a blank document. Make the formatting settings you want, enter the text that should be contained in all new documents (for example, division into chapters, inserting a table of contents, page numbers, choosing a default text language, paragraph style, etc.).

When your template is ready, go to File → Template → Save as Template. Come up with a name for your template, choose a template category.

You can also immediately enable the “Set as default template” option.

When everything is ready, click the “Save” button.

Or later you can go to File → Template → Manage Templates, select the template you want to use as default, right-click on it and select “Set as Default”.

The default template will have an icon with a green checkmark.

To find out the path where your templates are stored, go to Tools → Options → LibreOffice → Paths.

On Linux, custom templates are stored in ~/.config/libreoffice/4/user/template/.

You can choose a different template to use as the default at any time. To do this, go to File → Templates → Manage Templates and select the desired template.

There you can also restore the original template, for this click the menu button in the form of three horizontal stripes and click “Reset Default Template”.

In the same menu, you can create and delete categories of templates, which will allow you to organize work with a large number of templates used as templates for various documents.

How to determine the type and speed of a USB port

How to determine the version and speed of the USB port?

It would seem that to say which version and speed of the USB connector on a computer is a trivial task. As it was before? The black connector is USB2 and the blue connector is USB3. Right? This information has long been outdated, in modern motherboards and laptops, blue has been abandoned as a sign of a fast USB socket.

What USB versions are there

You may already know notation such as

  • USB 4
  • USB 3.0 and USB 3.1 Gen 1
  • USB 3.1 and USB 3.1 Gen 2
  • USB 3.2 and Gen 2×2

All this became so complicated and incomprehensible that it was all considered obsolete and SuperSpeed USB with numbers was invented.

What does the labeling of USB ports mean

Surely there should be a hint about the version and speed of the USB ports next to the connectors.

Let's take a look at the following photo of the ports on my laptop:

First, all three of these ports are USB ports, even the small one! The small one is USB-C / USB Type C.

Second, what do these letters “SS” and the number mean?

The port without the letters “SS” is old USB 2.0. The small port with “SS” and number 10 is SuperSpeed USB 10 Gbps, formerly called USB 3.1 Gen 2.

Okay, we've figured out two out of three ports, what about the third port? It is clear that this is some version of SuperSpeed, but which one?

How to determine in Linux which port my computer has: USB3, USB3.0, USB3.1, USB3.2, or USB4

To check the USB version run the following command:

sudo lsusb -v | grep -i bcdusb

The conclusion is not very informative, we can only say with confidence that the system has USB ports 3.1 and 2.0 and that two devices are connected to USB 3.1, and the rest are connected to USB 2.0. Don't be surprised at the number of devices – some of them are internal devices (like a webcam) and are connected to a USB hub inside the case.

To figure out which devices use USB 3.* and what their speed is, you need to delve into the properties of the system hardware.

Let's start with the command

lsusb

As you can see in the screenshot, this computer has root hubs 3.0 and 2.0:

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

USB host controllers are PCI devices, so you can see them with lspci:

lspci | grep USB

Find “xHCI” which is USB3.

The following command will also show the available xhci controllers or hubs. The operating speed is shown at the end of each line. USB3 speed starts from 5000M.

Let's compare the output of the two commands:

lsusb -t | grep xhci
lsusb | grep hub

As you can see, the 2.0 root hub has a speed of 480M, and the 3.0 root hub has a speed of 10000M.

To determine which USB port the flash drive is connected to and its speed, connect the device you are interested in and run

lsusb -t

Find the phrase “Mass Storage” – these are disks and flash drives. The parent of this node corresponds to the USB port where you connected your flash drive. The last figure is speed.

How USB Versions and Speed Compare

In the screenshot above, we could see the speed of 10000M, but which version of USB is it exactly?

Look at the following data:

  • 12M = 12MBit/s = USB1
  • 480M = 480MBit/s = USB2
  • 5000M = 5000MBit/s = USB3.0, also known as USB3.1 gen. 1
  • 10000M = 10000MBit/s = USB 3.1, also known as USB 3.1 Gen 2
  • 20000M = 20000MBit/s = USB 3.2, also known as USB 3.2 Gen 2×2; or it could be USB4 Gen 2×2 or USB4 Gen 3×1
  • 40000M = 40000MBit/s = USB4 Gen 3×2

In fact, the names like USB 3.* are considered obsolete since only the connection speed really matters. Currently, the following designations are considered “relevant”:

  • SuperSpeed USB 5 Gbps
  • SuperSpeed USB 10 Gbps
  • SuperSpeed USB 20 Gbps

lsusb.py script to display USB devices in an understandable way

The lsusb.py script conveniently displays information about USB hubs and devices connected to them.

To display information, just run on the command line:

lsusb.py

You may get an error that the lsusb.py command was not found. The lsusb.py script comes with the usbutils package, which contains another lsusb program we already use. For some reason, in some distributions the usbutils package is distributed without the lsusb.py script. To install it run the following commands:

curl https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usbutils.git/plain/lsusb.py.in > lsusb.py
chmod +x lsusb.py
sudo mv lsusb.py /usr/bin/lsusb.py

Lines starting with usb1, usb2, etc. are USB hubs.

Lines that start with 1-1, 1-3, 2-2, and so on are USB devices.

In addition to the manufacturer and device identifiers, each line in square brackets contains information about version, speed, and maximum power consumption, for example

  • USB 3.10
  • 5000 Mbps
  • 304mA

Device names are shown in parentheses.

UsbView – viewing a tree of USB devices in a graphical interface

You can find out the speed of USB connectors and devices with a program such as UsbView, which provides very detailed technical information.

USBView is a small GTK application that shows what a USB bus device tree looks like. It shows a graphical representation of the devices that are currently connected, showing the topology of the USB bus. It also displays information about each individual device on the bus.

Installing UsbView on Debian, Kali Linux, Linux Mint, Ubuntu and their derivatives:

sudo apt install usbview

Installing UsbView on Arch Linux, Manjaro, BlackArch and their derivatives:

sudo pacman -S usbview

During installation, the program will inform you that for it to work, you need to run the command

mount -t debugfs none /sys/kernel/debug

or add the line to the /etc/fstab file

none /sys/kernel/debug debugfs defaults 0 0

Instead, you can get by by running the program with superuser rights:

sudo usbview

The screenshot shows that the computer has 2 xHCI host controllers, one of them is version 3.10:

There are two devices connected to the controller version 3.10, one of the devices version 3.00 (note the line “USB Version: 3.00”).

And the other device is version 3.10:

Error “remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead” (SOLVED)

The article “How to make and submit changes to source code on GitHub” shows you how to update files on GitHub after you have edited their local copies on your computer. The commands shown in the article are still valid, but due to changes on GitHub, now instead of a password, you need to use a token that you need to get on GitHub itself.

When trying to use a password for authentication, you will encounter an error:

remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead.
remote: Please see https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/ for more information.
fatal: Authentication failed for 'https://github.com/Mi-Al/OpenVPNassistent/'

The essence of the error is that since August 13, 2021, support for password authentication has been removed and now you need to use a token.

There is also a link to read the details: https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/

From that link, you will need to go to another page, where they will still explain how to get a token: https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal -access-token

You can check out these pages. But the gist is pretty simple, go to https://github.com/settings/tokens page and click on the “Generate new token” button.

Enter “Note”, the actual name, for the token.

Set the token expiration time.

It is highly recommended not to make perpetual tokens, but even if your perpetual token has been stolen, you can revoke it at any time, that is, invalidate it.

Select the scope of the token. For the “git push” command, you need to select “repo”, as stated in the description, this is “Full control of private repositories”.

Please note that the token will only be shown once – don't forget to copy it!

If you forgot to copy or lost it, it doesn't matter, you can always re-generate a token or create a new one.

Use the token in the same way as you used the password. That is, when prompted for a password when submitting changes to GitHub, enter the token, not the password.

How to make and submit changes to source code on GitHub

GitHub is an awesome collaborative software development tool. There is a lot of documentation on working with git: in the program's help and on the Internet.

Being very flexible and with many commands and options, git can be confusing when you first get to know it. The git options and commands should be studied carefully, but this post is a dirty and short guide that shows you step by step how to make changes to a program hosted on GitHub and how to submit your changes to the author.

Before sending your changes to the code to the author of the program, it is strongly recommended that you familiarize yourself with his wishes. They can be associated with both programming style (specifics of naming variables, for example) and formatting features (using the tab key or four spaces, for example). Even if the author did not write their wishes, it is highly recommended to follow the style of the code you are editing.

Source code edit permission on GitHub

The procedure for changing the source code on GitHub differs depending on whether you have the permission to change the source code of a repository or not.

You can directly edit a repository on GitHub in the following cases:

  • you are the owner of the repository
  • you are granted permissions to edit a specific repository by its owner

In this case, the editing procedure is as follows:

  • you clone the source code to your local computer
  • make changes to the source code
  • push changes to the repository

If you do not have permission to edit the repository, but want to suggest a change to the source code, then you need to Fork the original repository.

Next, you go through three familiar stages for your fork:

  • you clone the source code to your local computer
  • make changes to the source code
  • push changes to the repository

After that, you submit changes to the original repository, this is called “Pull request”.

How to edit source code on GitHub

I'll show you part of a real workflow on real code here.

Situation: in the airgeddon program in the EvilTwin branch, I need to make changes to some lines. I start by cloning the code to my local drive:

git clone https://github.com/v1s1t0r1sh3r3/airgeddon.git -b EvilTwin

Note that I am using the -b switch, followed by the name of the EvilTwin branch. By default, the newest branch is cloned (the branch in which the most recent changes were made). Since the default name is master, this is usually the branch that is cloned.

The names of branches and features of the workflow can be different for each project – and they are discussed within the team or available in the form of public rules.

The source code can be edited in your favorite editor or IDE. After completing the edits, on the command line, go to the directory with the program and execute there:

git status

Information about the status (file changed) and tips on what to do next are displayed:

Add the file(s) in which the changes were made:

git add airgeddon.sh

And again we look at the status:

git status

We need to write a comment on what we did with the code:

git commit -m "Updating Russian translation (minor fixes)"

We get approximately the following information:

[EvilTwin 39b8960] Updating Russian translation (minor fixes)
 1 file changed, 8 insertions(+), 8 deletions(-)

If you're curious, you can see the status again:

git status

The information received and the hint indicate that everything is ready to send our changes to GitHub. To do this, I execute the command (EvilTwin in this case is the name of the branch to which I am committing):

git push origin EvilTwin

You will be asked for your username (e-mail) and password on GitHub and the following information will be displayed:

Подсчет объектов: 3, готово.
Delta compression using up to 3 threads.
Сжатие объектов: 100% (3/3), готово.
Запись объектов: 100% (3/3), 420 bytes | 0 bytes/s, готово.
Total 3 (delta 2), reused 0 (delta 0)
remote: Resolving deltas: 100% (2/2), completed with 2 local objects.
To https://github.com/v1s1t0r1sh3r3/airgeddon.git
   04d1fb4..39b8960  EvilTwin -> EvilTwin

PLEASE NOTE: Since August 13, 2021, support for password authentication has been removed and now you need to use a token. For details, see Error “remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead” (SOLVED).

Finally, you can check the status again:

git status

Wine is missing from the context menu on Ubuntu (SOLVED)

To run Windows applications on Linux, it is usually enough to double-click on them. But it may be that the .exe file will be opened by the archive manager or another application (usually the archive manager).

If you try to select the “Open With Other Application” item in the context menu, then Wine will not be there. Even worse, it is impossible to add a custom command, that is, it is impossible to launch an .exe program with a double click or through the context menu.

First, make sure Wine is installed on your system. To do this, run the command

which wine

If the output contains the path to the executable file, for example, /usr/bin/wine, then this means that Wine is installed.

If nothing is shown in the output, it means that you first need to install the Wine package.

This can be done with the following set of commands:

sudo dpkg --add-architecture i386
sudo apt update
sudo apt install wine winbind

Windows applications can be launched from the command line using a command similar to the following:

wine /PATH/TO/APPLICATIONS.exe

But this is not very convenient, so let's look at how to add Wine to the context menu in Ubuntu.

On Ubuntu (GNOME 3) Wine is missing from the context menu and it is not possible to add a custom command. To fix, do the following:

sudo ln -s /usr/share/doc/wine/examples/wine.desktop /usr/share/applications/

If you encounter an error that the wine.desktop file is missing, then find it with the following command and edit the above command:

locate wine.desktop

Right-click on the .exe file and select the item called “Open With Other Application”.

Then select “View All Application”.

Click on “Wine Windows Program Loader” and then click on the “Select” button.

How to manage VPN Settings in GNOME 3

A popular example of a Linux distribution using GNOME 3 is Ubuntu.

How to add OpenVPN connection settings to GNOME 3

To add an OpenVPN connection, click on the network connection icon and expand the connections section.

Select “Wired Settings”:

You will find yourself in the OS settings. On the “Network” tab, you can add a new VPN connection or manage existing ones. Click the plus sign (+) to add a new one.

You can enter the data manually, or import the OpenVPN connection settings from the .ovpn file.

With manual configuration, you do not need to change anything in the “IPv4” and “IPv6” tabs. Some of the settings are located on the “Identity” tab, to access other settings, click the “Advanced” button:

How to connect to OpenVPN on GNOME 3

You can enable OpenVPN connection by clicking on the network connections button, then selecting the desired VPN connection.

You can also go to Network Settings and enable the selected OpenVPN connection there.

How to change OpenVPN connection settings in GNOME 3

To edit VPN connections, click on the network connections button, then expand the VPN list and select “VPN Settings”.

Select the connection you want to change and press the gear.

How to remove OpenVPN connection in GNOME 3

To remove an OpenVPN connection, go to its settings, as shown just above, and click the “Remove VPN” button.

How to manage VPN Settings in Xfce

Popular distributions with Xfce include Kali Linux and Xubuntu.

In Xfce, networks are managed in the “Network Connections” window.

How to add OpenVPN connection settings to Xfce

There are two ways to add a new OpenVPN connection:

1) Right-click on the network connection icon and select “Edit Connections”:

In the Network Connections, click the plus sign (+).

2) Or left-click on the network connection icon and select “VPN Connections”→ “Add a VPN Connection”.

Select your preferred VPN connection type.

To import a VPN connection from a file, select “Import a saved VPN configuration”.

Click the “Create” button and specify the settings file.

With manual configuration, you do not need to change anything on the “General”, “Proxy”, “IPv4 Settings”, and “IPv6 Settings” tabs. Some of the settings are located on the “VPN” tab, to access other settings, click the “Advanced” button.

How to connect to OpenVPN in Xfce

To connect to OpenVPN, left-click on the network connection icon and select “VPN Connections” and then select the desired connection.

If the connection is successful, a check mark will appear next to the VPN connection name.

How to change or remove OpenVPN connection settings in Xfce

To add, change and remove VPN connections, go to Network Connections, for this, right-click on the network connection icon and select “Edit Connections”.

How to manage VPN Settings in Cinnamon

The Cinnamon desktop environment is primarily characteristic of Linux Mint.

Network Connections and Network Settings in Cinnamon

When you click on the network connection icon (its appearance depends on whether you are using a wired or wireless connection), two options will be available to manage networks:

  • Network Settings – featured by Cinnamon (therefore, it is present only in this desktop environment)
  • Network Connections – featured by NetworkManager (hence, it is present in any distribution with NetworkManager)

In general, these settings allow you to do the same things: add, edit and remove network connections.

Network Settings contains a list of Wi-Fi networks available for connection, as well as a list of OpenVPN settings, proxies, wired connections. In Network Settings, you can activate a particular network connection.

Network Connections does not show Wi-Fi networks available for connection, but it stores the settings of the networks to which the computer has ever connected.

Managing OpenVPN Connections in Network Settings

To remove an OpenVPN connection, select it and click the minus sign (-).

The connection will be dropped without confirmation.

Click the plus sign (+) to add an OpenVPN connection.

You will be presented with 2 options:

  • OpenVPN (compatible with the OpenVPN server) – you will need to enter the settings manually and specify the certificate files
  • Import from file – import settings from an .ovpn file

With manual configuration, you don't need to change anything in the “IPv4” and “IPv6” tabs. Some of the settings are located on the “Identity” tab, to access other settings, click the “Advanced” button:

To edit an OpenVPN connection, select it and click the gear icon.

Some of the settings are located on the “Identity” tab.

To access other settings, click the “Advanced” button.

Managing OpenVPN Connections in Network Connections

To remove an OpenVPN connection, select it and click the minus sign (-).

Click the plus sign (+) to add an OpenVPN connection.

In the drop-down list, you will have many options available, 2 of them are related to OpenVPN:

  • OpenVPN – you will need to enter the settings manually and specify the certificate files
  • Import a saved VPN configuration

With manual configuration, you do not need to change anything on the “General”, “Proxy”, “IPv4 Settings”, and “IPv6 Settings” tabs. Some of the settings are located on the “VPN” tab, to access other settings, click the “Advanced” button.

To edit an OpenVPN connection, select it and click the gear icon.

Connecting to OpenVPN server

You can add multiple OpenVPN connections and enable any of them depending on your needs. You can enable them as in the main NetworkManager panel – click on the selected connection:

You can also enable VPN connections in Network Settings, to do this, select the desired VPN connection and click the switch:

Simultaneous use of multiple OpenVPNs on one server

You can simultaneously use several OpenVPN processes on the same server, while they will work on different ports and provide separate virtual private networks that do not overlap with each other.

Multiple instances of OpenVPN are provided out of the box, but additional configuration is required.

1. OpenVPN services must use different ports

All OpenVPN services must use a free port. Remember that the same UDP and TCP port numbers are different ports, that is, you can use the same port number in two instances of OpenVPN, provided that one of them is a UDP port and the other is a TCP port.

If two OpenVPN services use the same port, then the OpenVPN instance that is started first will work without error, and the second instance will not start due to the error “TCP/UDP: Socket bind failed on local address [AF_INET][undef]:…: Address already in use (errno=98)”, for example:

2021-11-02 09:26:50 us=736094 TCP/UDP: Socket bind failed on local address [AF_INET][undef]:53: Address already in use (errno=98)
2021-11-02 09:26:50 us=736216 Exiting due to fatal error

2. Range of addresses of the virtual private network

By default, a range of IP addresses for a virtual private network is specified in the server configuration file, for example:

server 10.8.0.0 255.255.255.0

Additional instances of the OpenVPN service must use different ranges. For example, for the second service, you can specify the following range:

server 10.8.1.0 255.255.255.0

For the third service, you can specify the following range of IP addresses, and so on:

server 10.8.2.0 255.255.255.0

3. Traffic routing for all virtual private networks

The section “Enable traffic routing on the OpenVPN server” shows how to enable NAT for VPN traffic so that clients can make connections to the Internet. The example in the above section shows how to configure routing for traffic from the 10.8.1.0/24 subnet. Since additional instances of the OpenVPN service use different subnets (for example, 10.8.1.0/24), in order for the clients of these virtual networks to access the Internet, you must configure routing for each of these networks.

An example of the original contents of the /root/bin/vpn_route.sh file:

#!/bin/sh

# specify the name of the interface, otherwise the script will try to select it automatically
#DEV='eth0'
DEV='ens3'
PRIVATE=10.8.0.0/24
 
if [ -z "$DEV" ]; then
	DEV="$(ip route | grep default | head -n 1 | awk '{print $5}')"
fi
# Turn forwarding packets on from the tunnel interface
# they got to the external interface
sysctl net.ipv4.ip_forward=1
# Make sure iptables do not block redirected traffic:
iptables -I FORWARD -j ACCEPT
# Network Address Translation (NAT) for packets coming from the tunnel
# When forwarding is enabled, packets are forwarded by default.
# with the original address unchanged, that is, in our case 10.8.0.*
# such packages are either deleted at the ISP gateway, or even if they are
# go to the destination, the answer never finds a way back.
# These private addresses are not routed to the Internet.
#
# The solution is Network Address Translation (NAT) of outgoing traffic,
# i.e. replace private 10.8.0.* address with the public IP address of the VPN server.
# This will allow responses to reach the VPN server,
# and there they will be sent back to the tunnel.
iptables -t nat -I POSTROUTING -s $PRIVATE -o $DEV -j MASQUERADE

The file /root/bin/vpn_route.sh which has added NAT for subnets 10.8.1.0/24, 10.8.2.0/24, and 10.8.3.0/24:

#!/bin/sh
 
DEV='ens3'
PRIVATE=10.8.0.0/24
 
if [ -z "$DEV" ]; then
	DEV="$(ip route | grep default | head -n 1 | awk '{print $5}')"
fi

sysctl net.ipv4.ip_forward=1

iptables -I FORWARD -j ACCEPT

iptables -t nat -I POSTROUTING -s $PRIVATE -o $DEV -j MASQUERADE

iptables -t nat -I POSTROUTING -s 10.8.1.0/24 -o $DEV -j MASQUERADE

iptables -t nat -I POSTROUTING -s 10.8.2.0/24 -o $DEV -j MASQUERADE

To check the NAT settings, run the command

iptables -L -t nat

4. Configuring local static addresses

If you used the section “How to make static IPs for OpenVPN clients” and added entries like “ifconfig-push 10.8.0.10 255.255.255.0” to the file “/etc/openvpn/ccd/client1”, then you need to use different client names for the second and subsequent OpenVPN networks as they use different VPN IP ranges.

5. Starting and adding the second and subsequent OpenVPN services to startup

Note that with systemctl you can use a command like

openvpn-server@<configuration>.service

where <configuration> is a configuration file located in the /etc/openvpn/server/ folder, but without the .conf extension

For example, the second configuration file for the second instance of the OpenVPN service is placed in the /etc/openvpn/server/server-tcp.conf file, then the program for starting the service is as follows:

sudo systemctl start openvpn-server@server-tcp.service

Checking the status of the service with the server-tcp.conf configuration file:

systemctl status openvpn-server@server-tcp.service

View OpenVPN service errors with server-tcp.conf config file:

journalctl -xeu openvpn-server@server-tcp.service

Add service to startup:

sudo systemctl enable openvpn-server@server-tcp.service

See also:

Loading...
X