I’m still using this 30-year-old Linux backup tool, and you should too


Creating backups of my files has always been a hassle for me, and I’ve lost a lot of data on multiple occasions because of it. Turns out it’s because I was working hard instead of smart. Instead of copy-pasting folders between my PC and external drive, I could just use a tool that sends over only the file changes. It takes seconds to back up files with this approach and I can do it by running a single command.

What is rsync, and who is it for?

Remote Sync or rsync is a free and open-source program that has been around since 1996, and it’s now a standard for Linux systems. It is a command-line tool designed for copying files and directories between two points.

Basically, it lets you copy files or directories between two locations incrementally. Unlike copy utilities like cp, it doesn’t copy the entirety of the file every time. It can compare changes between a file in two places and only transfer the changes, significantly cutting down on bandwidth and transfer times.

rsync copy a directory to directory

Since it takes this incremental approach, rsync is essentially syncing files and directories between two locations. It runs checksums to verify that no file contents were lost or corrupted in transit. The two points don’t even have to be local because rsync has networking features too, allowing it to transfer data over the encrypted SSH network protocol.

The function of rsync sounds simple on paper, but that’s what makes it incredibly powerful. System admins keep it in their toolkit to back up and mirror servers. Devs and organizations use it to deploy code or mirror large software repos.

Rsync running to a network device.

For regular users like us, rsync is the perfect way to back up personal files and media. If you keep a backup external drive, you don’t have to copy entire directories or files every time you create a backup. You can run a single command and watch rsync transfer only the modified or new files to the external drive.

What can you do with rsync

In addition to incremental backups, you can use rsync to create perfect replicas of directories after you’ve made changes in the source. With a single command, rsync can erase any files that are present in the target directory but not in the source directory.

It’ll preserve permissions, ownership, timestamps, and symbolic links when mirroring those directories. Copying and pasting files with GUI file managers can change their metadata (date created or permissions), but rsync creates perfect copies, metadata and all.

A screenshot of the man page for the rsync utility.

For larger file transfers, rsync is the better option because it can compress data during transfer, and it can resume failed or interrupted transfers. File managers also don’t work well when there is a huge number of small files involved, but that doesn’t affect rsync. With rsync, you don’t lose any speed or waste time re-copying data.

You can also use it to transfer data over an SSH tunnel while using the safe features available for local transfers.

To recap: rsync is perfect for creating smart, incremental backups. It can create perfect mirrors of files and folders, metadata included. It’s faster than a graphical file manager. It can resume file transfers if they’re interrupted. It also supports the same features for network transfers.

The rsync basics

You can install rsync from the official repos of your package manager. For Debian or Ubuntu systems, run the following command to install rsync.

sudo apt install rsync

Arch users can install it using pacman.

sudo pacman -S rsync

For Fedora and its derivatives, try this command.

sudo dnf install rsync

To use rsync, you need to know the basic structure of its commands. You start by invoking the rsync program, then you add a flag or a combination of them to select which options should be toggled on, and finally you give it the directory paths of the source and destination.

rsync [options] [source] [destination]

There are a lot of options available in rsync, but you don’t need to know all of them to work with it. These are my go-to flags.

  1. Archive (-a) is for mirroring directories while perfectly preserving permissions, symbolic links, and metadata.
  2. Verbose (-v) gives you a log of files being transferred in real time.
  3. Compress (-z) compresses the files during transfer to make the transfer faster.
  4. Progress or partial (-p) makes sure you can resume the file transfer if interrupted.
  5. Dry run (-n) simulates what changes will be made and what the destination will look like before you commit to the changes. It’s good for making sure you aren’t accidentally overwriting or erasing any important files.

Let’s try moving a folder using rsync. I am trying to move this folder labeled “Apple” in my Downloads to my “OS” folder in a different drive.

rsync -avp /home/jellyjam/Downloads/Apple /mnt/7f1e8ebb-93ac-48eb-8138-42380cce3253/OS
Using rsync to copy a folder from PC to an external drive, creating an incremental backup.

The “-avp” flags trigger the archive, verbose, and progress options. Then I just added the paths of my source and destination folders.

If I had included a trailing “https://www.howtogeek.com/” at the end of either path, rsync would just copy the file contents inside the folder to the destination folder. Leaving the path without a slash at the end makes sure it copies the folder itself, not just its contents.


You can use rsync to clone your entire home directory to an external drive just like I did, creating a perfect backup. From time to time, you can run the same command to update the backup with modified or new files. Updating backups with rsync barely takes a fraction of the time it would take to copy everything.



Source link

Leave a Reply

Subscribe to Our Newsletter

Get our latest articles delivered straight to your inbox. No spam, we promise.

Recent Reviews


Spotify aims to provide a consistent listening experience that uses minimal data. As a result, your audio quality might be less than ideal, especially if you’re using a pair of high-fidelity headphones or high-end speakers. Here’s how to fix that.

Switch audio streaming quality to Very High or Lossless

The default audio streaming quality in both the mobile and desktop Spotify apps is set to Automatic, which usually keeps the audio quality at Normal, which is only 96 Kbps. Even though Spotify uses the Ogg Vorbis codec, which is superior to MP3, OGG files exhibit slight (but noticeable) digital noise, poor bass detail, dull treble, and a narrow soundstage at 96 Kbps.

Even worse, Spotify is aggressive about adjusting the automatic bitrate. Even though 4G is more than fast enough to stream high-quality OGG files, even with a weak signal, Spotify may still drop the quality to Low, which has a bitrate of just 24 Kb/s. You will notice such a sharp drop in quality, even on a pair of bottom-of-the-barrel headphones.

To rectify this, open the Spotify app, tap your user image, open “Settings and privacy,” and tap the “Media Quality” menu. Once there, set Wi-Fi streaming quality and cellular streaming quality to “Very high” or “Lossless.”

I recommend setting cellular streaming quality to Very high and reserving Lossless for Wi-Fi, since lossless streaming is very data-intensive. One hour of streaming lossless files can take up to 1GB of data, as well as a good chunk of your phone’s storage, because Spotify caches files you’re frequently streaming. Besides, you’ll struggle to notice the difference unless you’re listening to music on a wired pair of high-end headphones or speakers; wireless connection just doesn’t have the bandwidth needed to convey the full fidelity of Spotify lossless audio.

You might opt for High quality if you have a capped data plan, but I recommend doing so only if you stream hours upon hours’ worth of music every single day over a cellular network. For instance, I burn through about 8 GB of data per month on average while streaming about two hours of very high-quality music over a cellular network each day.

Illustration of a headphone with various music icons around.


How Audio Compression Works and Why It Can Affect Your Music Quality

Feeling the squeeze when listening to your favorite song?

Set audio download quality to Very high or Lossless

If you tend to download songs and albums for offline listening, you should also set the audio download quality to “Very high” or “Lossless.” This setting is located just under the audio streaming quality section.

The audio download quality menu in Spotify's mobile app.

If you’ve got enough free storage on your phone, opt for the latter, but if you’d rather save storage space, set it to Very high. You’ll hardly hear the difference, but lossless files are about five times larger than the 320 Kb/s OGG files Spotify offers at its Very high quality setting, and they can quickly fill up your phone’s storage.

Adjust video streaming quality at your discretion

The last section of the Media quality menu is Video streaming quality. This sets the quality of video podcasts and music videos available for certain songs. Since I care about neither, I set it to “Very high” on Wi-Fi and “Normal” on cellular, but you should tweak the two options at your discretion because songs sound notably better at higher video streaming quality levels.

If you often watch videos over cellular and have unlimited data, feel free to toggle video quality to very high.

Make sure Data Saver mode is disabled

Even if your audio quality is set to Very high or Lossless, Spotify will switch to low-quality streaming if the app’s Data saver mode is enabled. This option is located in the Data saving and offline menu. Open the menu, then set it to “Always off,” or choose “Automatic” to have Spotify’s Data Saver mode kick in alongside your phone’s Data Saver mode.

You can also enable volume normalization and play around with the built-in equalizer

Spotify logo in the center of the screen with an equalizer in front. Credit: Lucas Gouveia / How-To Geek

Last but not least, there are two additional features you can play with to improve your listening experience. The first is volume normalization, which sets the same loudness for every track you’re listening to. This can be handy because different albums are mastered at different loudness levels, with newer music usually being louder.

Since I’m an album-oriented listener, I keep the option disabled. I can just play an album and set the audio volume accordingly, and I don’t really mind louder songs when listening to playlists, artists, or song radios.

But if you can’t stand one song being quiet and the next rattling the windows, visit the Playback menu, enable “Volume normalization,” and set it to “Quiet” or “Normal.” The “Loud” option can digitally compress files, and neither Spotify nor I recommend using it. This also happens with “Quiet” and “Normal,” since both adjust the decibel level of the master recording for each song, but the compression level is much lower and extremely hard to notice.

Before I end this, I should also mention that you can access the equalizer directly from the Spotify app, where you can fine-tune your music listening experience or pick one of the available equalizer presets. If your phone has a built-in equalizer, Spotify will open it; if it doesn’t, you can use Spotify’s. On my phone (a Samsung Galaxy S21 FE), I can only use One UI’s built-in equalizer.

To open the equalizer, open “Playback,” then hit the “Equalizer” button. Now you can equalize your audio to your heart’s content.


Adjusting just a few settings can have a drastic impact on your Spotify listening experience. If you aren’t satisfied with Spotify’s sound quality, make sure to adjust the audio before jumping ship. You should also check the sound quality settings from time to time, as Spotify can reset them during app updates.​​​​​​​

Three phones with a Spotify screen and the logo in the center.


These 8 Spotify Features Are My Favorite Hidden Gems

Look for these now.



Source link