call_end

    • Li chevron_right

      Simplifying Docker Installation on Linux

      pubsub.slavino.sk / linuxyournal • 10 October, 2023 edit • 1 minute

    Simplifying Docker Installation on Linux

    In the boundless ocean of software development, containerization has emerged as the trusty vessel for developers, ensuring smooth sailing even in turbulent waters of system discrepancies and compatibility woes. Among the fleet of containerization tools, Docker shines bright as the beacon of reliability and ease. Docker facilitates wrapping up a piece of software in a complete filesystem that contains everything it needs to run: code, runtime, system tools, system libraries – anything that can be installed on a server. This guarantees that the software will always run the same, regardless of its environment. This article unfurls the sails to guide you through the calmest route to installing Docker on your Linux machine, ensuring a swift, hassle-free voyage into the realms of containerization.

    Preparing for Installation

    System Requirements

    Before embarking on this voyage, ensure that your vessel – in this case, your Linux machine – is sea-worthy and ready to harness the winds of Docker.

    1. Check Your Linux Distribution and Version : Docker supports Ubuntu, Debian, Fedora, CentOS, and many more. Ensure you're running a supported version of your Linux distribution.

    2. Hardware Prerequisites : Although Docker is quite lightweight, ensuring your system meets the minimum hardware requirements is prudent. A system with a 64-bit architecture, and at least 2GB RAM is recommended.

    Updating System Packages

    Embarking on the high seas with an outdated map is a recipe for disaster. Likewise, before installing Docker, updating your system's package database ensures a smoother sail.

    1. Run the following command to update the list of available packages:

    sudo apt-get update

    Installation Method: Using the Repository

    Sailing through the calm waters is always advisable. Installing Docker from the official repository is akin to such a peaceful voyage.

    Setting Up the Docker Repository
    1. Update the apt package index :

    sudo apt-get update

    1. Install packages to allow apt to use a repository over HTTPS :

    sudo apt-get install apt-transport-https ca-certificates curl gnupg lsb-release

    1. Add Docker’s official GPG key :

    curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg


    Značky: #Linux

    • Li chevron_right

      Data Safety and Efficiency with Rdiff-backup

      pubsub.slavino.sk / linuxyournal • 4 October, 2023 edit

    Data Safety and Efficiency with Rdiff-backup

    For more than a decade, Rdiff-backup has been our preferred choice for developing Minarca Data Backup software, an efficient data backup process management solution tailored for system administrators. Integrated into Minarca, Rdiff-backup offers a range of advantages that make it an optimal, robust, and easily accessible solution for managing data backups. In this article, we delve into the technical aspects that set Rdiff-backup apart, making it a go-to choice for data backup requirements.

    Reverse Incremental Backup Process

    Rdiff-backup employs a reverse incremental backup process, a unique approach that sets it apart from conventional methods. Unlike standard incremental backups that build upon previous backups, Rdiff- backup focuses on the difference between the latest backup and the preceding one. This method brings forth several advantages that contribute to its efficiency and reliability:


    Značky: #Linux

    • Li chevron_right

      Mastering User and Permission Management: Fortifying Your Linux Bastion

      pubsub.slavino.sk / linuxyournal • 3 October, 2023 edit

    Mastering User and Permission Management: Fortifying Your Linux Bastion
    Introduction

    In the vast landscape of operating systems, Linux stands as a bastion of flexibility and security. Central to its robust security model is the meticulous management of user accounts and permissions. This article delves into the intricacies of managing user accounts and permissions in Linux, illuminating the pathway towards securing your system against unauthorized access and potential misuse.

    Understanding Users and Groups

    At the heart of Linux’s security model are users and groups. A user is an account that has access to the system, potentially with varying levels of permissions. Groups are collections of users, facilitating the administration of common permissions among multiple users.

    1. User and Group Identifiers (UID & GID): Each user and group in a Linux system is uniquely identified by a user ID (UID) and group ID (GID) respectively. These identifiers are crucial for the system to manage permissions and resources.
    Creating and Managing User Accounts

    Creating, modifying, and deleting user accounts are routine tasks for system administrators.


    Značky: #Linux

    • wifi_tethering open_in_new

      This post is public

      www.linuxjournal.com /content/mastering-user-and-permission-management-fortifying-your-linux-bastion

    • Li chevron_right

      The 5 Best Tools to Create a Bootable USB From an ISO in Linux

      pubsub.slavino.sk / linuxyournal • 28 September, 2023 edit • 2 minutes

    The 5 Best Tools to Create a Bootable USB From an ISO in Linux
    Introduction

    Creating a bootable USB drive is a cornerstone skill for anyone interested in exploring different operating systems or working in system administration. A bootable USB drive allows a user to boot into a different operating system, independent of the primary OS installed on the machine. This is particularly useful for system recovery, testing new OS builds, or installing a new system altogether. Linux, known for its robustness and versatility, offers a plethora of tools for creating bootable USB drives from ISO files, which are exact copies of disk data. This guide aims to delve into the top five tools available on Linux for crafting bootable USB drives from ISO files.

    Understanding ISO Files

    ISO files are disk image files that encapsulate the file system and the data content of a disk. They serve as exact digital replicas of optical disk data, whether it be a CD, DVD, or Blu-ray disk. The importance of ISO files in creating bootable USB drives cannot be overstated. They act as the source blueprint from which the bootable drive is created, ensuring that the resulting USB drive is an exact copy of the original disk data, necessary for correct operating system functionality and booting.

    Top 5 Tools for Creating a Bootable USB in Linux

    UNetbootin

    UNetbootin (Universal Netboot Installer) is a free and open-source tool that has been around for many years. It is widely recognized for its ease of use and support for a variety of operating systems.

    Upon launching UNetbootin, you're presented with the option to either download a distribution or use a pre-downloaded ISO file. Select the ISO file, choose the USB drive you want to write to, and click on the 'OK' button to start the creation process.

    Rufus

    Rufus is known for its speed and reliability. Though originally designed for Windows, it also operates on Linux. It's a small utility that packs a punch, offering a range of system file types to cater to different OS requirements.

    Open Rufus, select the ISO file under the 'Boot selection' section, choose the USB drive under 'Device', set the desired system parameters under 'Partition scheme' and 'File system', and hit 'Start'.

    Etcher (BalenaEtcher)

    Etcher provides a clean and straightforward interface, eliminating the hassle often associated with creating bootable USB drives. Its three-step process is simple and intuitive.

    Launch Etcher, click 'Flash from file' to select your ISO file, choose your USB drive under 'Select target', and click 'Flash!' to begin the process.

    dd (Disk Dump)

    dd is a powerful disk copying tool that operates on a command-line interface. It's native to Unix-like systems and is revered for its flexibility and advanced features.


    Značky: #Linux

    • Li chevron_right

      Core Knowledge That Modern Linux Kernel Developer Should Have

      pubsub.slavino.sk / linuxyournal • 27 September, 2023 edit • 1 minute

    Core Knowledge That Modern Linux Kernel Developer Should Have
    Languages

    The Linux Kernel is written in C programming language, so C is the most important language for the Linux Kernel developer. Initially, the kernel was written in GNU C (now it is also possible to build it using LLVM) which extends standard C with some additional keywords and attributes. I would recommend learning some modern C version like C11 and additionally learning GNU extensions to be able to read kernel code effectively. Small, architecture-specific parts of the kernel and some highly optimized parts of several drivers are written in assembly language. This is the second language of choice. There are 3 main architectures nowadays: x86, ARM, and RISC-V. What assembly language to choose depends on your hardware platform.

    You definitely should look at Rust which is gaining popularity in the Linux Kernel community as a more safer and reliable alternativeto C.

    Linux is a highly configurable system and its configurability is based on the kernel build system, KBuild. Each developer should know the basics of KBuild and Make to be able to successfully extend/modify the kernel code. Last, but not least is shell scripting. It is hard to imagine Kernel development without command-line usage and a developer inevitably has to write some shell scripts to support their job by automating repetitive tasks.

    Software environment

    The Linux Kernel development is inextricably linked to the Git source control system. It is not possible to imagine nowadays the kernel development workflow without it. So, Git knowledge is a requirement.

    Unless kernel developers run their kernel on specific/customized hardware - emulation is the best developer's friend. The most popular platform for this is Qemu/KVM. A typical workflow looks like this: a developer introduces some changes to the kernel or a driver, builds it, copies it under a virtual environment, and tests it there. If all is OK, then the developer tests these changes on real hardware, but if something goes wrong, then the kernel under the virtual machine crashes.  In this case, it is quite easy to just shut down VM, fix the error and repeat the development/debug cycle. If we didn't have virtualization we would restart the real machine on each kernel crash and development time would increase in order of magnitude.


    Značky: #Linux

    • Li chevron_right

      Linux Networking: A Simplified Guide to IP Addresses and Routing

      pubsub.slavino.sk / linuxyournal • 21 September, 2023 edit • 1 minute

    Linux Networking: A Simplified Guide to IP Addresses and Routing
    Introduction

    Every Linux enthusiast or administrator, at some point, encounters the need to configure or troubleshoot network settings. While the process can appear intimidating, with the right knowledge and tools, mastering Linux networking can be both enlightening and empowering. In this guide, we'll explore the essentials of configuring IP addresses and routing on Linux systems.

    Understanding Basic Networking Concepts

    What is an IP address?

    Every device connected to a network has a unique identifier known as an IP address. This serves as its 'address' in the vast interconnected world of the Internet.

    • IPv4 vs. IPv6 : While IPv4 is still prevalent, its successor, IPv6, offers a larger address space and improved features. IPv4 addresses look like 192.168.1.1 , whereas IPv6 addresses resemble 1200:0000:AB00:1234:0000:2552:7777:1313 .

    • Public vs. Private IPs : Public IPs are globally unique and directly reachable over the Internet. Private IPs are reserved for internal network use and are not routable on the public Internet.

    Subnet Masks and Gateways

    A subnet mask determines which portion of an IP address is the network and which is the host. The gateway, typically a router, connects local networks to external networks.

    Routing

    At its core, routing is the mechanism that determines how data should travel from its source to its destination across interconnected networks.

    Network Configuration Tools in Linux

    Linux offers both traditional tools like ifconfig and route and modern ones like ip , nmcli , and nmtui . The choice of tool often depends on the specific distribution and the administrator's preference.

    NetworkManager and systemd-networkd have also modernized network management, providing both CLI and GUI tools for configuration.

    Configuring IP Addresses in Linux

    1. Using the ip command :

      • Display Current Configuration : ip addr show
      • Assign a Static IP : ip addr add 192.168.1.10/24 dev eth0
      • Remove an IP Address : ip addr del 192.168.1.10/24 dev eth0
    2. Using nmcli for NetworkManager :


    Značky: #Linux

    • Li chevron_right

      New 'Mirrored' Network Mode Introduced in Windows Subsystem for Linux

      pubsub.slavino.sk / linuxyournal • 20 September, 2023 edit • 1 minute

    Microsoft's Windows Subsystem for Linux (WSL) continues to evolve with the release of WSL 2 version 0.0.2. This update introduces a set of opt-in preview features designed to enhance performance and compatibility.

    Key additions include "Automatic memory reclaim" which dynamically optimizes WSL's memory footprint, and "Sparse VHD" to shrink the size of the virtual hard disk file. These improvements aim to streamline resource usage.

    Additionally, a new "mirrored networking mode" brings expanded networking capabilities like IPv6 and multicast support. Microsoft claims this will improve VPN and LAN connectivity from both the Windows host and Linux guest.

    Complementing this is a new "DNS Tunneling" feature that changes how DNS queries are resolved to avoid compatibility issues with certain network setups. According to Microsoft, this should reduce problems connecting to the internet or local network resources within WSL.

    Advanced firewall configuration options are also now available through Hyper-V integration. The new "autoProxy" feature ensures WSL seamlessly utilizes the Windows system proxy configuration.

    Microsoft states these features are currently rolling out to Windows Insiders running Windows 11 22H2 Build 22621.2359 or later. They remain opt-in previews to allow testing before final integration into WSL.

    By expanding WSL 2 with compelling new capabilities in areas like resource efficiency, networking, and security, Microsoft aims to make Linux on Windows more performant and compatible. This evolutionary approach based on user feedback highlights Microsoft's commitment to WSL as a key part of the Windows ecosystem.


    Značky: #Linux

    • Li chevron_right

      SFTP Port Forwarding: Enabling Suppressed Functionality

      pubsub.slavino.sk / linuxyournal • 22 February, 2023 edit • 1 minute

    SFTP Port Forwarding: Enabling Suppressed Functionality

    Introduction

    The SSH protocol enables three major classes of remote server activities: a) command execution (including a login shell), b) network forwarding and manipulation, and c) file transfer.

    The OpenSSH maintainers have determined that sftp and scp have no legitimate use for port forwarding (via the -L and -R options). A flag to explicitly disable these features is unconditionally passed to the child SSH executable during file transfers with these utilities.

    There may be users with a legitimate need for these features. An obvious subset are penetration testers tasked to verify that this capability is explicitly disabled on public SFTP servers.

    Below are two techniques to enable these suppressed features, by either modifying strings in the sftp binary itself, or by redirection through shells that are able to easily edit the command line. Depending upon the capabilities of the platform, either technique might be required to achieve this goal.

    Suppression Details

    To begin, it is important to locate running processes of interest. The shell function below will reveal PIDs that match a shell pattern (and note this is not a regex). This runs under Debian dash (and most other common shells) and relies on BSD options to ps :

    pps () { local a= b= c= IFS=$'\r'; ps ax | while read -r a
        do [ "$b" ] || c=1; for b; do case "$a" in *"$b"*) c=1;;
            esac; done; [ "$c" ] && printf '%s\n' "$a" && c=; done; }

    A conventional SFTP session is launched, in order to examine the processes associated with it:

    $ id
    uid=1001(aturing) gid=1001(aturing) groups=1001(aturing)...
    
    $ sftp aturing@sftp.victimandum.comaturing@sftp.victimandum.com's password:
    Connected to sftp.victimandum.com.
    sftp>

    We assume above that the local UNIX user has an account on the remote SFTP server of the same username.

    Once the session is running, a local process search for the username reveals the child SSH process that is spawned by SFTP:


    Značky: #Linux