Linux Storage Management and SSH
21 Questions
0 Views

Linux Storage Management and SSH

Created by
@AchievableCharacterization

Podcast Beta

Play an AI-generated podcast conversation about this lesson

Questions and Answers

Which command is primarily used for copying files between different systems securely?

  • rsync
  • mv
  • scp (correct)
  • dd
  • What is the function of the 'stat' command in relation to file metadata?

  • To copy files between directories
  • To display detailed information about a file (correct)
  • To change file ownership
  • To compress files
  • Which command could be used to create a new directory?

  • mkdir (correct)
  • rmdir
  • cp
  • mv
  • What is the primary purpose of using 'gzip' in file management?

    <p>Compressing files to save space</p> Signup and view all the answers

    Which command is used to display the current working directory in a shell?

    <p>pwd</p> Signup and view all the answers

    Which command is used to create a new logical volume in LVM?

    <p>lvcreate</p> Signup and view all the answers

    What is one of the primary functions of the 'df' command in Linux?

    <p>Monitor disk usage</p> Signup and view all the answers

    What is the purpose of the '/etc/fstab' file?

    <p>To define how disk partitions are mounted</p> Signup and view all the answers

    Which command would you use to view the current status of RAID arrays in Linux?

    <p>/proc/mdstat</p> Signup and view all the answers

    Which tool is specifically used for managing XFS filesystems?

    <p>XFS tools</p> Signup and view all the answers

    What does the command 'lvextend' do in the context of Logical Volume Manager?

    <p>Increase the size of an existing logical volume</p> Signup and view all the answers

    Which mechanism is used in Linux to encrypt filesystem partitions?

    <p>Linux Unified Key Setup (LUKS)</p> Signup and view all the answers

    What does the 'blkid' command display?

    <p>Block device information</p> Signup and view all the answers

    Which of the following files is used for SSH server configuration?

    <p>/etc/ssh/sshd_config</p> Signup and view all the answers

    What is the purpose of the Set User ID (SUID) permission in Linux?

    <p>To allow a file to run with the privileges of the file owner</p> Signup and view all the answers

    Which command is used to change the file permissions in Linux?

    <p>chmod</p> Signup and view all the answers

    Which of the following is a command for managing AppArmor profiles?

    <p>aa-status</p> Signup and view all the answers

    What does the sticky bit do when set on a directory?

    <p>Prevents file deletion by users who do not own the files</p> Signup and view all the answers

    What is a primary function of the ssh-keygen command?

    <p>To generate SSH key pairs for authentication</p> Signup and view all the answers

    Which option best describes the role of SELinux in system security?

    <p>Enforces mandatory access controls based on defined policies</p> Signup and view all the answers

    Which command is used to enable enforcement of SELinux policies?

    <p>setenforce</p> Signup and view all the answers

    Study Notes

    Storage Management

    • Disk partitioning: Commands include fdisk, parted, and partprobe.
    • Monitoring storage space and disk usage: Utilize commands like df and du.
    • Inspecting RAID implementations: Employ mdadm, /proc/mdstat to examine RAID arrays.
    • Storage Area Networks (SAN) and Network-Attached Storage (NAS): Leverage multipathd for SAN/NAS management.
    • Mounting local and remote devices: Use systemd.mount, /etc/fstab, mount for device mounting.
    • Creating and modifying volumes using Logical Volume Manager (LVM): Commands include pvs, vgs, lvs, lvchange, lvcreate, vgcreate, lvresize, pvcreate, and vgextend.
    • Linux Unified Key Setup (LUKS): Securely manage encrypted partitions.
    • External devices: Identify and manage external storage with commands like lsscsi, lsblk, blkid, fcstat.
    • Filesystem management: Utilize tools for XFS, Ext4, and Btrfs filesystems.

    SSH (Secure Shell)

    • Configuration files: Modify settings in /etc/ssh/sshd_config, /etc/ssh/ssh_config, ~/.ssh/known_hosts, ~/.ssh/authorized_keys, and ~/.ssh/config.
    • Commands: Utilize ssh-keygen, ssh-copy-id, and ssh-add for key management.
    • Tunneling: Enable X11 forwarding, port forwarding, and dynamic forwarding for secure remote connections.

    Remote Access and Execution

    • Executing commands as another user: Utilize commands like sudo, visudo, su -, and pkexec for privileged access.

    File Permissions and Access Control

    • Access control list (ACL): Implement fine-grained control over file permissions.
    • Set user ID (SUID) and Set group ID (SGID): Grant specific permissions to users and groups.
    • Sticky bit: Control file deletion within a directory.
    • Security-enhanced Linux (SELinux): A robust security framework with context permissions, labels, system booleans, and policy types for enforcing strict access controls.
    • AppArmor: A security module that limits application permissions.
    • Command-line utilities: Use chown, umask, chmod, getfacl, setfacl, ls, setenforce, getenforce, chattr, lsattr, chgrp, setsebool, getsebool, chcon, restorecon, semanage, and audit2allow to manage permissions and security settings.

    Scripting and Automation

    • File editing: Use commands like sed, awk, printf, nano, and vi(m) for text manipulation and editing.
    • File metadata: Retrieve file information using stat and file.
    • File and directory operations: Commands like mv, cp, mkdir, rmdir, ls, pwd, rm, cd, tree, cat, and touch are essential for managing files and directories.
    • Soft and hard links: Create different types of links for files.
    • Copying files between systems: Utilize rsync, scp, and nc for file transfer.
    • File compression, archiving, and backup: Employ tools like gzip, bzip2, xz, cpio, dd, zip, tar for efficient file handling.

    Studying That Suits You

    Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

    Quiz Team

    Related Documents

    Description

    Test your knowledge on Linux storage management practices and SSH. This quiz covers disk partitioning commands, RAID implementations, Logical Volume Manager (LVM), and secure remote access with SSH. Hone your skills in managing file systems and external storage devices.

    More Like This

    Linux File Systems Overview
    242 questions
    Disk Management Basics
    40 questions
    Linux Storage and Networking Quiz
    12 questions
    Use Quizgecko on...
    Browser
    Browser