• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

udisksctl Command Examples in Linux

by Deepika

udisksctl is a command-line utility that allows users to interact with the udisksd daemon process. The udisksd daemon is a system daemon that provides a standardized interface for interacting with storage devices on Linux systems. The daemon allows users to mount, unmount, and manage storage devices such as USB drives, hard drives, and network storage devices.

udisksctl is a powerful tool that can be used to manage storage devices from the command line. Some of the tasks that can be performed using udisksctl include:

  • Mounting and Unmounting Storage Devices: udisksctl can be used to mount and unmount storage devices. For example, to mount a USB drive, users can run the command “udisksctl mount -b /dev/sdb1”. Similarly, to unmount a mounted device, users can run the command “udisksctl unmount -b /dev/sdb1”.
  • Querying Device Information: udisksctl can be used to query information about storage devices. For example, users can run the command “udisksctl info -b /dev/sdb1” to retrieve information about a particular storage device.
  • Creating and Managing Partitions: udisksctl can be used to create and manage partitions on storage devices. For example, users can create a new partition on a storage device using the command “udisksctl create-partition -s 500M /dev/sdb”.
  • Power Management: udisksctl can be used to manage the power settings of storage devices. For example, users can set the power management settings of a device using the command “udisksctl power-off -b /dev/sdb”.

udisksctl Command Examples

1. Show high-level information about disk drives and block devices:

# udisksctl status

2. Show detailed information about a device:

# udisksctl info --block-device /dev/sdX

3. Show detailed information about a device partition:

# udisksctl info --block-device /dev/sdXN

4. Mount a device partition and prints the mount point:

# udisksctl mount --block-device /dev/sdXN

5. Unmount a device partition:

# udisksctl unmount --block-device /dev/sdXN

6. Monitor the daemon for events:

# udisksctl monitor

Summary

In summary, udisksctl is a command-line program that provides a powerful interface for managing storage devices on Linux systems. It is a valuable tool for system administrators and power users who need to manage storage devices from the command line. With udisksctl, users can easily mount and unmount devices, query device information, manage partitions, and set power management settings.

Filed Under: Linux

Some more articles you might also be interested in …

  1. Linux OS service ‘portmap’
  2. hostname Command Examples in Linux
  3. sfill: command not found
  4. rpmspec Command Examples in Linux
  5. Honeypot Tutorials – Modes and Working of Honeypot
  6. e4defrag Command Examples in Linux
  7. chgrp: command not found
  8. Linux OS Service ‘sshd’
  9. How to Setup SSH keys for “passwordless” ssh login in Linux
  10. findfs: command not found

You May Also Like

Primary Sidebar

Recent Posts

  • Vanilla OS 2 Released: A New Era for Linux Enthusiasts
  • mk Command Examples
  • mixxx Command Examples
  • mix Command Examples

© 2025 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright