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

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

dar: command not found

by admin

dar is a full featured backup tool, aimed for disks (floppy, CD-R(W), DVD-R(W), zip, jazz, hard-disks, usb keys, etc.). The dar (“disk archiver”) command is intended to replace tar by offering more backup and archiving functionality. It is especially useful at creating full, differential, and incremental backups.

If you encounter the below error while running the dar command:

dar: command not found

you may try installing the below package as per your choice of distribution:

OS Distribution Command
OS X brew install dar
Debian apt-get install dar
Ubuntu apt-get install dar
Kali Linux apt-get install dar
Fedora dnf install dar
Raspbian apt-get install dar

dar Command Examples

1. The following command creates a full backup of the mydata directory and outputs a backup file named full.bak:

# dar -R mydata -c full.bak

2. To create a differential backup (diff1.bak), you can reference the full backup using the -A option:

# dar -R mydata -c diff1.bak -A full.bak

3. You can then create more differential backups as needed by referencing the full backup with the -A option. However, to perform incremental backups instead, you need to reference the previous incremental backup, like so:

# dar -R mydata -c incr1.bak -A full.bak
# dar -R mydata -c incr2.bak -A incr1.bak

4. The -x (extract) option is used to recover a backup. If you performed differential backups, you need to first extract the full backup, then the latest differential backup:

# dar -x full.bak
# dar -x diff1.bak -w

5. The -w option automatically overwrites changes to files; otherwise, you will be prompted to confirm. To recover an incremental backup, you need to first extract the full backup, then each incremental backup, in order:

# dar -x full.bak
# dar -x incr1.bak -w
# dar -x incr2.bak -w

Filed Under: Linux

Some more articles you might also be interested in …

  1. halt Command Examples in Linux
  2. mycli: command not found
  3. How To Configure Restricted Bash Shell in Linux
  4. EMC PowerPath Powermt Commands (Cheat Sheet)
  5. Detect rootkits & malware on Linux Servers using rkhunter
  6. znew Command Examples in Linux
  7. cockpit-ws Command Examples in Linux
  8. RHEL 7 – RHCSA Notes – input / output redirection
  9. How to use strace and ltrace commands in Linux
  10. CentOS / RHEL : How to find free space in a Volume Group in LVM

You May Also Like

Primary Sidebar

Recent Posts

  • powertop Command Examples in Linux
  • powertop: command not found
  • powerstat: command not found
  • powerstat Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright