Sharing files on Linux

Learn how to send and receive files securely and easily over Meshnet on Linux.

This guide provides the information you need to start sharing files over Meshnet on Linux.

Before you begin

Make sure that the device you want to share files with meets the following criteria:

  • The NordVPN app is running, and the Meshnet feature is enabled in the app.

  • The device is connected to your Meshnet.

Note

You can add devices to your Meshnet in two ways, depending on device ownership:

Send files

You can initiate a file transfer from the NordVPN app by completing these steps:

  1. Open Terminal.

  2. Enter the nordvpn meshnet peer list command and copy the Nord name or Meshnet IP address of the device you want to share your files with.

  3. Type the nordvpn fileshare send command, followed by your peer device’s Nord name or Meshnet IP address and the path to the file you want to transfer, as shown:

    nordvpn fileshare send <peer> </path/to/your/file>

    You can use the absolute and the relative file paths for the files you want to send. Example

  4. To add additional files to the transfer, append the path of the new file to the already entered command. You can drag files from the file explorer to the terminal to paste their path. Example

Tip

To find your peer's Nord name faster, start typing the name and press Tab. The system will auto-complete the name with a match from online devices.

Note

You can only send files to the devices that have the file sharing permission enabled for your device. For more information, see File sharing permissions.

The file transfer begins when the recipient accepts your download request on their device. For details, consult the appropriate guides:

Viewing outgoing transfer history

To display the history of transfers sent from your device, along with their ID, size, status, and other relevant details, use the following command:

nordvpn fileshare list --outgoing

The transfers in the list are arranged in chronological order, with the oldest transfers appearing first.

Receive shared files

Note

Make sure that Meshnet is enabled on your device to receive the file transfer request from the sender.

You can use the NordVPN notifications or the command line to receive files shared from another linked device.

  1. Open Terminal.

  2. Ensure that you have enabled the NordVPN notifications by running this command:

    nordvpn set notify on

  3. Have your Meshnet peer send the files.

  4. Upon receiving the file transfer notification, select Accept within it to start the download of the transferred files.

Once a download is complete, if you have NordVPN notifications enabled, you will receive a notification about each individual downloaded file.

You can find the files shared with you by checking the system's Downloads folder.

If you want to download only specific files from the transfer, provide the names of the files you choose to accept.

nordvpn fileshare accept <id> <file1> <file2>...​

Example

Tip

To display the list of files in a particular transfer directory, enter the nordvpn fileshare list command followed by the transfer ID:

nordvpn fileshare list <id>

Accepting transfers automatically

You can enable automatic transfer acceptance from a specific peer. To do this, run the following command, replacing <device> with the peer’s Nord name or Meshnet IP:

nordvpn meshnet peer auto-accept enable <device>

To learn more, see the Changing permissions section of the "File sharing permissions" page.

Setting the download location

By default, the downloaded files are saved in the $HOME/Downloaddirectory. However, if you want to specify a different location on your system, use the --path command option followed by the desired location and the transfer ID:

nordvpn fileshare accept --path </path/to/directory> <id>

Run a transfer process in the background

If you want to run a transfer process in the background, use the --background option.

  • When sending a file transfer, enter:

    nordvpn fileshare send --background <peer> </path/to/your/file>

    Example

  • When accepting a file transfer, type:

    nordvpn fileshare accept --background <id>

Manage transfers

Canceling file transfers

If you need to cancel a transfer while it is still in progress, there are two ways to do it:

  • Use the Ctrl + C keyboard shortcut to terminate a file transfer when it's running in the foreground and you are using the same terminal session.

  • Use the cancel command to stop transfers that are being performed in the background. This command allows you to cancel the whole transfer or a specific file within the transfer.

    • To cancel a file transfer, enter the following command, replacing <id> with the ID of the transfer you want to cancel.

      nordvpn fileshare cancel <id>

      Example

    • To cancel a specific file in a transfer, provide the file's name following the transfer ID, as shown:

      nordvpn fileshare cancel <id> <file>
Clearing your transfer history

You can remove entries from your file sharing history by using the clear command.

  • To completely remove all of your transfer history, run the following command:

    nordvpn fileshare clear all

  • To clear transfer records older than a specific date, use the command below with the selected time interval in SystemD time span syntax:

    nordvpn fileshare clear <time_interval>

    Example This command will remove history entries that are older than one day and 12 hours.

    nordvpn fileshare clear 1d 12h

Display a help message

You can access command information using the --help option. For example, to view helpful information about the fileshare command, type:

nordvpn fileshare --help

See also

Last updated

© 2024 Nord Security. All Rights Reserved.