# Mount, backup, umount

**URL:** https://forum.duplicati.com/t/mount-backup-umount/17980
**Category:** Support
**Created:** [May 23, 2024, 1:29pm UTC](https://forum.duplicati.com/t/mount-backup-umount/17980 "2024-05-23T13:29:15Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![spayk](https://forum.duplicati.com/user_avatar/forum.duplicati.com/spayk/32/4915_2.png) [@spayk](https://forum.duplicati.com/u/spayk)
#### Post date: [May 23, 2024, 1:29pm UTC](https://forum.duplicati.com/t/mount-backup-umount/17980/1 "2024-05-23T13:29:16Z")

</div>

Hello,  
I do have a question regarding a solution to duplicati. Was reading a manual, but haven’t found it. So my question is as follows:

1. is it possible in duplicati before making a backup to mount via script a network drive from windows, then do a backup and make an umount in script?  
So what I would like to achieve is:  
I have windows server machine with shared network drive in my LAN network. And have a duplicati in my linux server. So I would like to achieve: Run duplicati \> automatically run a script with mounting network drive → make backup in duplicati → then umount it via script from duplicati.

---

<div class="post-metadata">

### Author: ![Jojo-1000](https://forum.duplicati.com/user_avatar/forum.duplicati.com/jojo-1000/32/8262_2.png) [@Jojo-1000](https://forum.duplicati.com/u/Jojo-1000)
#### Post date: [May 23, 2024, 1:58pm UTC](https://forum.duplicati.com/t/mount-backup-umount/17980/2 "2024-05-23T13:58:18Z")

</div>

Hi, there is this manual here which explains how the scripts work:

> **[Example Scripts - Duplicati 2 User's Manual](https://docs.duplicati.com/en/latest/appendix-g-example-scripts/)**
>
> Documentation for Duplicati 2

You want to use the run-script-before and run-script-after options.

Some tips with scripts:

- You want to check the operation type, so it only runs for backup. Otherwise every time you try to restore, it will run.
- You can use the same script file for both if you check the event name (before/after).

I assume you know the command to mount, otherwise you can search for other posts on this forum for that.

There are sometimes problems reported when using a network drive as the backup source, but you will need to see how well it works for your setup.
